linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Gertjan van Wingerde <gwingerde@gmail.com>
To: Stanislaw Gruszka <sgruszka@redhat.com>
Cc: Larry Finger <Larry.Finger@lwfinger.net>,
	Justin Piszcz <jpiszcz@lucidpixels.com>,
	Ivo van Doorn <IvDoorn@gmail.com>,
	linux-kernel@vger.kernel.org, linux-wireless@vger.kernel.org,
	Alan Piszcz <ap@solarrain.com>,
	"users@rt2x00.serialmonkey.com" <users@rt2x00.serialmonkey.com>
Subject: Re: [PATCH] rt2x00: rt2800: fix zeroing skb structure
Date: Sat, 30 Jul 2011 15:41:32 +0200	[thread overview]
Message-ID: <4E340A0C.5040604@gmail.com> (raw)
In-Reply-To: <20110730113255.GB2847@redhat.com>

On 07/30/11 13:32, Stanislaw Gruszka wrote:
> We should clear skb->data not skb itself. Bug was introduced by:
> commit 0b8004aa12d13ec750d102ba4082a95f0107c649 "rt2x00: Properly
> reserve room for descriptors in skbs".
> 
> Cc: stable@kernel.org # 2.6.36+
> Signed-off-by: Stanislaw Gruszka <sgruszka@redhat.com>

Ouch. Good catch. Let me go find a brown paper bag now :-(

Not sure if this is the source of Justin's problems, though.

Acked-by: Gertjan van Wingerde <gwingerde@gmail.com>

> ---
>  drivers/net/wireless/rt2x00/rt2800lib.c |    3 +--
>  1 files changed, 1 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/net/wireless/rt2x00/rt2800lib.c b/drivers/net/wireless/rt2x00/rt2800lib.c
> index 75d2c6c..f94d669 100644
> --- a/drivers/net/wireless/rt2x00/rt2800lib.c
> +++ b/drivers/net/wireless/rt2x00/rt2800lib.c
> @@ -703,8 +703,7 @@ void rt2800_write_beacon(struct queue_entry *entry, struct txentry_desc *txdesc)
>  	/*
>  	 * Add space for the TXWI in front of the skb.
>  	 */
> -	skb_push(entry->skb, TXWI_DESC_SIZE);
> -	memset(entry->skb, 0, TXWI_DESC_SIZE);
> +	memset(skb_push(entry->skb, TXWI_DESC_SIZE), 0, TXWI_DESC_SIZE);
>  
>  	/*
>  	 * Register descriptor details in skb frame descriptor.


-- 
---
Gertjan

  parent reply	other threads:[~2011-07-30 13:47 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-07-27 23:33 3.0: rt2800usb(Kernel PANIC) vs. rt2780sta(GOOD/2.6.38) Justin Piszcz
2011-07-28  5:34 ` Andreas Hartmann
2011-07-28 16:18 ` Larry Finger
2011-07-30 11:30   ` Stanislaw Gruszka
2011-07-30 11:32     ` [PATCH] rt2x00: rt2800: fix zeroing skb structure Stanislaw Gruszka
2011-07-30 11:39       ` Justin Piszcz
2011-07-30 14:20         ` Justin Piszcz
2011-07-30 14:32           ` Justin Piszcz
2011-07-30 15:05             ` Andreas Hartmann
2011-07-30 17:07               ` Justin Piszcz
2011-07-30 17:10                 ` Justin Piszcz
2011-07-31  3:41                   ` Adam Cozzette
2011-07-31 10:09                     ` Justin Piszcz
2011-07-30 18:07                 ` Larry Finger
2011-08-03 16:00                 ` Stanislaw Gruszka
2011-08-03 17:31                   ` Justin Piszcz
2011-08-03 17:44                     ` Justin Piszcz
2011-08-03 18:32                       ` Justin Piszcz
2011-08-03 18:33                       ` Stanislaw Gruszka
2011-08-03 18:35                         ` Justin Piszcz
2011-08-03 18:42                           ` Justin Piszcz
2011-08-03 18:49                             ` Justin Piszcz
2011-08-04  8:03                         ` Justin Piszcz
2011-08-04 12:43                           ` Stanislaw Gruszka
2011-08-05 16:13                           ` [rt2x00-users] " Aleksandar Milivojevic
2011-07-30 13:41       ` Gertjan van Wingerde [this message]
2011-07-30 14:02       ` Ivo Van Doorn

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=4E340A0C.5040604@gmail.com \
    --to=gwingerde@gmail.com \
    --cc=IvDoorn@gmail.com \
    --cc=Larry.Finger@lwfinger.net \
    --cc=ap@solarrain.com \
    --cc=jpiszcz@lucidpixels.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=sgruszka@redhat.com \
    --cc=users@rt2x00.serialmonkey.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).