From: Luis R. Rodriguez Date: Fri, 10 Oct 2008 19:26:24 +0000 (-0700) Subject: ath9k: Fix return code when ath9k_hw_setpower() fails on reset X-Git-Tag: upstream/snapshot3+hdmi~22513^2~3 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=d2a3b222cf976bc44bb9aed13f7b17feea28f633;p=platform%2Fadaptation%2Frenesas_rcar%2Frenesas_kernel.git ath9k: Fix return code when ath9k_hw_setpower() fails on reset We were not reporting a status code back ath9k_hw_setpower() failed during reset so lets correct this. Reported-by: Jiri Slaby Signed-off-by: Luis R. Rodriguez Signed-off-by: David S. Miller --- diff --git a/drivers/net/wireless/ath9k/hw.c b/drivers/net/wireless/ath9k/hw.c index 372ae61..98bc25c 100644 --- a/drivers/net/wireless/ath9k/hw.c +++ b/drivers/net/wireless/ath9k/hw.c @@ -5892,8 +5892,10 @@ bool ath9k_hw_reset(struct ath_hal *ah, goto bad; } - if (!ath9k_hw_setpower(ah, ATH9K_PM_AWAKE)) - return false; + if (!ath9k_hw_setpower(ah, ATH9K_PM_AWAKE)) { + ecode = -EIO; + goto bad; + } if (curchan) ath9k_hw_getnf(ah, curchan);