Skip to contentSkip to conversation

Patch "ARM: cpuidle: Fix error return code" has been added to the 4.8-stable tree

PATCH [email protected] 1 participant 1 message Oct 14, 2016

Subsystems (2)
lore
Share & tools
lore

[email protected]

author maintainer Applied
#0 lore raw

This is a note to let you know that I've just added the patch titled

ARM: cpuidle: Fix error return code

to the 4.8-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
arm-cpuidle-fix-error-return-code.patch
and it can be found in the queue-4.8 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree, please let <[email protected]> know about it.

Quoted 1 line

From af48d7bc3756a0cd882d65bff14ab39746ba57fe Mon Sep 17 00:00:00 2001

From: Christophe Jaillet <[email protected]>
Date: Thu, 11 Aug 2016 15:02:30 +0200
Subject: ARM: cpuidle: Fix error return code

From: Christophe Jaillet <[email protected]>

commit af48d7bc3756a0cd882d65bff14ab39746ba57fe upstream.

We know that 'ret = 0' because it has been tested a few lines above. So, if 'kzalloc' fails, 0 will be returned instead of an error code. Return -ENOMEM instead.

Fixes a0d46a3dfdc3 ("ARM: cpuidle: Register per cpuidle device")
---
 drivers/cpuidle/cpuidle-arm.c |    1 +
 1 file changed, 1 insertion(+)
drivers/cpuidle/cpuidle-arm.c +1 -0
@@ -121,6 +121,7 @@ static int __init arm_idle_init(void)
 		dev = kzalloc(sizeof(*dev), GFP_KERNEL);
 		if (!dev) {
 			pr_err("Failed to allocate cpuidle device\n");
+			ret = -ENOMEM;
 			goto out_fail;
 		}
 		dev->cpu = cpu;

Patches currently in stable-queue which might be from [email protected] are

queue-4.8/arm-cpuidle-fix-error-return-code.patch