[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#520468: Incorporate fixes for WUSB54GS support from 2.6.33



On Thu, 2010-06-24 at 02:51 +0100, Luís Picciochi Oliveira wrote:
> On Thu, Jun 24, 2010 at 2:27 AM, Ben Hutchings <ben@decadent.org.uk> wrote:
> > Please can you confirm or correct the following summary of your results
> > so far:
> >
> > Debian 2.6.32-15: fails to pass traffic
> 
> Correct.
> 
> > Debian 2.6.32-15 with patch reverted: good
> I had no crashes since Monday (June 21st). So, apparently yes.
> It used to take a while to crash: minutes to hours. But so far it hasn't failed.
> 
> > Debian 2.6.34-1~experimental.2: fails to pass traffic
> > Debian 2.6.34-1~experimental.2 with patch reverted: driver crashes!
> 
> The driver crashes as soon as I plug the adapter with both versions.
> Now that I compare them, the crash logs with and without the patch
> seem to be exactly the same crash.
> 
> I just rebooted to test with a vanilla 2.6.34 kernel from kernel.org:
> it also crashes with the same error. I'm attaching the log from that
> kernel.

I think the attached patch will fix this.  Please test it.

Ben.

-- 
Ben Hutchings
Once a job is fouled up, anything done to improve it makes it worse.
From 97b812bf3f4abd5d554f38bc67a8d7fd6ab97d6d Mon Sep 17 00:00:00 2001
From: Ben Hutchings <ben@decadent.org.uk>
Date: Tue, 29 Jun 2010 02:15:48 +0100
Subject: [PATCH] usbnet: Set parent device early for netdev_printk()

netdev_printk() follows the net_device's parent device pointer, so
we must set that earlier than we previously did.
---
 drivers/net/usb/usbnet.c |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/drivers/net/usb/usbnet.c b/drivers/net/usb/usbnet.c
index a95c73d..81c76ad 100644
--- a/drivers/net/usb/usbnet.c
+++ b/drivers/net/usb/usbnet.c
@@ -1293,6 +1293,9 @@ usbnet_probe (struct usb_interface *udev, const struct usb_device_id *prod)
 		goto out;
 	}
 
+	/* netdev_printk() needs this so do it as early as possible */
+	SET_NETDEV_DEV(net, &udev->dev);
+
 	dev = netdev_priv(net);
 	dev->udev = xdev;
 	dev->intf = udev;
@@ -1377,8 +1380,6 @@ usbnet_probe (struct usb_interface *udev, const struct usb_device_id *prod)
 		dev->rx_urb_size = dev->hard_mtu;
 	dev->maxpacket = usb_maxpacket (dev->udev, dev->out, 1);
 
-	SET_NETDEV_DEV(net, &udev->dev);
-
 	if ((dev->driver_info->flags & FLAG_WLAN) != 0)
 		SET_NETDEV_DEVTYPE(net, &wlan_type);
 	if ((dev->driver_info->flags & FLAG_WWAN) != 0)
-- 
1.7.1

Attachment: signature.asc
Description: This is a digitally signed message part


Reply to: