public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Greg KH <greg@kroah.com>
To: Alan Stern <stern@rowland.harvard.edu>
Cc: Greg KH <gregkh@suse.de>, Oliver Neukum <oneukum@suse.de>,
	"Theodore Ts'o" <tytso@mit.edu>,
	Zwane Mwaikambo <zwane@arm.linux.org.uk>,
	torvalds@linux-foundation.org,
	Justin Forbes <jmforbes@linuxtx.org>,
	Kernel development list <linux-kernel@vger.kernel.org>,
	Chris Wedgwood <reviews@ml.cw.f00f.org>,
	Domenico Andreoli <cavokz@gmail.com>,
	Randy Dunlap <rdunlap@xenotime.net>,
	Michael Krufky <mkrufky@linuxtv.org>,
	Chuck Ebbert <cebbert@redhat.com>, Dave Jones <davej@redhat.com>,
	Andrew Morton <akpm@linux-foundation.org>,
	Chuck Wolber <chuckw@quantumlinux.com>,
	stable@kernel.org, alan@lxorguk.ukuu.org.uk,
	USB development list <linux-usb-devel@lists.sourceforge.net>
Subject: Re: [stable] [patch 25/28] USB: cdc-acm: fix sysfs attribute registration bug
Date: Fri, 24 Aug 2007 08:49:06 -0700	[thread overview]
Message-ID: <20070824154906.GA19239@kroah.com> (raw)
In-Reply-To: <Pine.LNX.4.44L0.0708240956570.3862-100000@iolanthe.rowland.org>

On Fri, Aug 24, 2007 at 09:59:49AM -0400, Alan Stern wrote:
> On Thu, 23 Aug 2007, Greg KH wrote:
> 
> > -stable review patch.  If anyone has any objections, please let us know.
> > 
> > ------------------
> > 
> > From: Alan Stern <stern@rowland.harvard.edu>
> > 
> > This patch (as950) fixes a bug in the cdc-acm driver.  It doesn't keep
> > track of which interface (control or data) the sysfs attributes get
> > registered for, and as a result, during disconnect it will sometimes
> > attempt to remove the attributes from the wrong interface.  The
> > left-over attributes can cause a crash later on, particularly if the driver
> > module has been unloaded.
> > 
> > Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
> > Acked-by: Oliver Neukum <oneukum@suse.de>
> > Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
> > 
> > ---
> >  drivers/usb/class/cdc-acm.c |    4 ++++
> >  1 file changed, 4 insertions(+)
> > 
> > --- a/drivers/usb/class/cdc-acm.c
> > +++ b/drivers/usb/class/cdc-acm.c
> > @@ -900,6 +900,10 @@ next_desc:
> >  			return -ENODEV;
> >  		}
> >  	}
> > +
> > +	/* Accept probe requests only for the control interface */
> > +	if (intf != control_interface)
> > +		return -ENODEV;
> >  	
> >  	if (data_interface_num != call_interface_num)
> >  		dev_dbg(&intf->dev,"Seperate call control interface. That is not fully supported.");
> > 
> 
> Odd.  This doesn't include the entire patch; the second hunk is
> missing.  It should go on to say:
> 
> @@ -1109,10 +1113,12 @@ static void acm_disconnect(struct usb_interface *intf)
>  		return;
>  	}
>  	if (acm->country_codes){
> -		device_remove_file(&intf->dev, &dev_attr_wCountryCodes);
> -		device_remove_file(&intf->dev, &dev_attr_iCountryCodeRelDate);
> +		device_remove_file(&acm->control->dev,
> +				&dev_attr_wCountryCodes);
> +		device_remove_file(&acm->control->dev,
> +				&dev_attr_iCountryCodeRelDate);
>  	}
> -	device_remove_file(&intf->dev, &dev_attr_bmCapabilities);
> +	device_remove_file(&acm->control->dev, &dev_attr_bmCapabilities);


I thought so too, untill you look at the 2.6.22.5 release, which already
has that change in it for some reason.

So that part of the patch drops out, it turns out you just reverted
things back to the way things used to be here :)

thanks,

greg k-h

  reply	other threads:[~2007-08-24 15:52 UTC|newest]

Thread overview: 39+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20070823220656.101239233@mini.kroah.org>
2007-08-23 22:18 ` [patch 00/28] 2.6.22-stable review cycle again Greg KH
2007-08-23 22:25   ` [patch 01/28] ocfs2: Fix bad source start calculation during kernel writes Greg KH
2007-08-23 22:25   ` [patch 02/28] NET: Share correct feature code between bridging and bonding Greg KH
2007-08-23 22:26   ` [patch 03/28] sky2: dont clear phy power bits Greg KH
2007-08-23 22:26   ` [patch 04/28] uml: fix previous request size limit fix Greg KH
2007-08-23 22:26   ` [patch 05/28] i386: fix lazy mode vmalloc synchronization for paravirt Greg KH
2007-08-23 22:26   ` [patch 06/28] signalfd: fix interaction with posix-timers Greg KH
2007-08-23 22:26   ` [patch 07/28] signalfd: make it group-wide, fix posix-timers scheduling Greg KH
2007-08-23 22:26   ` [patch 08/28] DCCP: Fix DCCP GFP_KERNEL allocation in atomic context Greg KH
2007-08-23 22:26   ` [patch 09/28] IPV6: Fix kernel panic while send SCTP data with IP fragments Greg KH
2007-08-23 22:26   ` [patch 10/28] IPv6: Invalid semicolon after if statement Greg KH
2007-08-23 22:26   ` [patch 11/28] Fix soft-fp underflow handling Greg KH
2007-08-23 22:26   ` [patch 12/28] Netfilter: Missing Kbuild entry for netfilter Greg KH
2007-08-23 22:26   ` [patch 13/28] SNAP: Fix SNAP protocol header accesses Greg KH
2007-08-23 22:27   ` [patch 14/28] NET: Fix missing rcu unlock in __sock_create() Greg KH
2007-08-23 22:27   ` [patch 15/28] SPARC64: Fix sparc64 task stack traces Greg KH
2007-08-23 22:27   ` [patch 16/28] SPARC64: Fix sparc64 PCI config accesses on sun4u Greg KH
2007-08-23 22:27   ` [patch 18/28] TCP: Fix TCP rate-halving on bidirectional flows Greg KH
2007-08-23 22:27   ` [patch 19/28] TCP: Fix TCP handling of SACK in " Greg KH
2007-08-23 22:27   ` [patch 20/28] PPP: Fix PPP buffer sizing Greg KH
2007-08-23 22:27   ` [patch 21/28] PCI: lets kill the PCI hidden behind bridge message Greg KH
2007-08-23 22:27   ` [patch 22/28] PCI: disable MSI on RS690 Greg KH
2007-08-23 22:27   ` [patch 23/28] PCI: disable MSI on RD580 Greg KH
2007-08-23 22:27   ` [patch 24/28] PCI: disable MSI on RX790 Greg KH
2007-08-23 22:27   ` [patch 25/28] USB: cdc-acm: fix sysfs attribute registration bug Greg KH
2007-08-24 13:59     ` Alan Stern
2007-08-24 15:49       ` Greg KH [this message]
2007-08-24 17:59         ` [stable] " Alan Stern
2007-08-24 18:04           ` Greg KH
2007-08-29 18:48             ` Chuck Ebbert
2007-08-29 23:33             ` Chuck Ebbert
2007-08-31  5:10               ` Greg KH
2007-08-23 22:27   ` [patch 26/28] USB: allow retry on descriptor fetch errors Greg KH
2007-08-23 22:27   ` [patch 27/28] USB: fix DoS in pwc USB video driver Greg KH
2007-08-23 22:28   ` [patch 28/28] usb: add PRODUCT, TYPE to usb-interface events Greg KH
2007-08-23 22:29   ` [patch 17/28] TCP: Do not autobind ports for TCP sockets Greg KH
2007-08-23 22:32   ` [patch 00/28] 2.6.22-stable review cycle again Greg KH
2007-08-29 19:43   ` Thomas Backlund
2007-08-29 20:03     ` Willy Tarreau

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=20070824154906.GA19239@kroah.com \
    --to=greg@kroah.com \
    --cc=akpm@linux-foundation.org \
    --cc=alan@lxorguk.ukuu.org.uk \
    --cc=cavokz@gmail.com \
    --cc=cebbert@redhat.com \
    --cc=chuckw@quantumlinux.com \
    --cc=davej@redhat.com \
    --cc=gregkh@suse.de \
    --cc=jmforbes@linuxtx.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-usb-devel@lists.sourceforge.net \
    --cc=mkrufky@linuxtv.org \
    --cc=oneukum@suse.de \
    --cc=rdunlap@xenotime.net \
    --cc=reviews@ml.cw.f00f.org \
    --cc=stable@kernel.org \
    --cc=stern@rowland.harvard.edu \
    --cc=torvalds@linux-foundation.org \
    --cc=tytso@mit.edu \
    --cc=zwane@arm.linux.org.uk \
    /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