All of lore.kernel.org
 help / color / mirror / Atom feed
From: Michael Buesch <mb@bu3sch.de>
To: Pavel Roskin <proski@gnu.org>
Cc: netdev@vger.kernel.org
Subject: Re: [PATCH] bcm43xx_d80211: Fix major memory corruption bug
Date: Tue, 23 Jan 2007 11:06:52 +0100	[thread overview]
Message-ID: <200701231106.52788.mb@bu3sch.de> (raw)
In-Reply-To: <20070121052740.7299.29574.stgit@dv.roinet.com>

On Sunday 21 January 2007 06:27, Pavel Roskin wrote:
> Set phy->lo_control to NULL whenever it's freed.  Failure to do so leads
> to zeroing a block of memory that uses to hold *phy->lo_control, which
> caused random crashes down the road.
> 
> Signed-off-by: Pavel Roskin <proski@gnu.org>

Applied, thanks.

> ---
> 
>  drivers/net/wireless/d80211/bcm43xx/bcm43xx_main.c |    2 ++
>  1 files changed, 2 insertions(+), 0 deletions(-)
> 
> diff --git a/drivers/net/wireless/d80211/bcm43xx/bcm43xx_main.c b/drivers/net/wireless/d80211/bcm43xx/bcm43xx_main.c
> index 3064322..62d4dc9 100644
> --- a/drivers/net/wireless/d80211/bcm43xx/bcm43xx_main.c
> +++ b/drivers/net/wireless/d80211/bcm43xx/bcm43xx_main.c
> @@ -3048,6 +3048,7 @@ static void bcm43xx_wireless_core_exit(struct bcm43xx_wldev *dev)
>  	if (phy->dyn_tssi_tbl)
>  		kfree(phy->tssi2dbm);
>  	kfree(phy->lo_control);
> +	phy->lo_control = NULL;
>  	ssb_chipco_set_clockmode(chipco, SSB_CLKMODE_SLOW);
>  	bcm43xx_vstack_free(&dev->genstack);
>  	bcm43xx_set_status(dev, BCM43xx_STAT_UNINIT);
> @@ -3179,6 +3180,7 @@ err_kfree_tssitbl:
>  		kfree(phy->tssi2dbm);
>  err_kfree_lo_control:
>  	kfree(phy->lo_control);
> +	phy->lo_control = NULL;
>  err_slowclock:
>  	ssb_chipco_set_clockmode(chipco, SSB_CLKMODE_SLOW);
>  	bcm43xx_set_status(dev, BCM43xx_STAT_UNINIT);
> 
> 
> 

-- 
Greetings Michael.

      parent reply	other threads:[~2007-01-23 10:08 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-01-21  5:27 [PATCH] bcm43xx_d80211: Fix major memory corruption bug Pavel Roskin
2007-01-22 18:21 ` Michael Buesch
2007-01-23 10:06 ` Michael Buesch [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200701231106.52788.mb@bu3sch.de \
    --to=mb@bu3sch.de \
    --cc=netdev@vger.kernel.org \
    --cc=proski@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.