From: Anna-Maria Gleixner Date: Fri, 11 Mar 2016 09:10:23 +0000 (+0100) Subject: net: mvneta: Add missing hotplug notifier transition X-Git-Tag: v4.9.8~2476^2~48 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=0df83e7a6b58674683677f572e4e2361b2a69eea;p=platform%2Fkernel%2Flinux-rpi3.git net: mvneta: Add missing hotplug notifier transition The mvneta_percpu_notifier() hotplug callback lacks handling of the CPU_DOWN_FAILED case. That means, if CPU_DOWN_PREPARE failes, the driver is not well configured on the CPU. Add handling for CPU_DOWN_FAILED[_FROZEN] hotplug notifier transition to setup the driver. Cc: Thomas Petazzoni Cc: netdev@vger.kernel.org Signed-off-by: Anna-Maria Gleixner Signed-off-by: David S. Miller --- diff --git a/drivers/net/ethernet/marvell/mvneta.c b/drivers/net/ethernet/marvell/mvneta.c index 3d8e7d3..be92668 100644 --- a/drivers/net/ethernet/marvell/mvneta.c +++ b/drivers/net/ethernet/marvell/mvneta.c @@ -3328,6 +3328,8 @@ static int mvneta_percpu_notifier(struct notifier_block *nfb, switch (action) { case CPU_ONLINE: case CPU_ONLINE_FROZEN: + case CPU_DOWN_FAILED: + case CPU_DOWN_FAILED_FROZEN: spin_lock(&pp->lock); /* Configuring the driver for a new CPU while the * driver is stopping is racy, so just avoid it.