Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756161AbYGVXSq (ORCPT ); Tue, 22 Jul 2008 19:18:46 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1754700AbYGVXRh (ORCPT ); Tue, 22 Jul 2008 19:17:37 -0400 Received: from cantor.suse.de ([195.135.220.2]:52705 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754552AbYGVXRg (ORCPT ); Tue, 22 Jul 2008 19:17:36 -0400 Date: Tue, 22 Jul 2008 16:14:14 -0700 From: Greg KH To: linux-kernel@vger.kernel.org, stable@kernel.org Cc: Justin Forbes , Zwane Mwaikambo , "Theodore Ts'o" , Randy Dunlap , Dave Jones , Chuck Wolber , Chris Wedgwood , Michael Krufky , Chuck Ebbert , Domenico Andreoli , Willy Tarreau , Rodrigo Rubira Branco , Jake Edge , torvalds@linux-foundation.org, akpm@linux-foundation.org, alan@lxorguk.ukuu.org.uk, linux-wireless@vger.kernel.org, John Linville , bcm43xx-dev@lists.berlios.de, Michael Buesch Subject: [patch 03/47] b43: Fix possible MMIO access while device is down Message-ID: <20080722231414.GD8282@suse.de> References: <20080722230208.148102983@mini.kroah.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline; filename="b43-fix-possible-mmio-access-while-device-is-down.patch" In-Reply-To: <20080722231342.GA8282@suse.de> User-Agent: Mutt/1.5.16 (2007-06-09) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1244 Lines: 39 2.6.25-stable review patch. If anyone has any objections, please let us know. ------------------ From: Michael Buesch This fixes a possible MMIO access while the device is still down from a suspend cycle. MMIO accesses with the device powered down may cause crashes on certain devices. Upstream commit is 33598cf261e393f2b3349cb55509e358014bfd1f Signed-off-by: Michael Buesch Signed-off-by: Greg Kroah-Hartman --- drivers/net/wireless/b43/leds.c | 3 +++ 1 file changed, 3 insertions(+) --- a/drivers/net/wireless/b43/leds.c +++ b/drivers/net/wireless/b43/leds.c @@ -72,6 +72,9 @@ static void b43_led_brightness_set(struc struct b43_wldev *dev = led->dev; bool radio_enabled; + if (unlikely(b43_status(dev) < B43_STAT_INITIALIZED)) + return; + /* Checking the radio-enabled status here is slightly racy, * but we want to avoid the locking overhead and we don't care * whether the LED has the wrong state for a second. */ -- -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/