aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/usb/rndis_host.c
diff options
context:
space:
mode:
authorGeorge Nassar <george.nassar@gmail.com>2009-10-14 19:27:41 -0400
committerGreg Kroah-Hartman <gregkh@suse.de>2009-10-30 17:57:33 -0400
commit40ac7b62d8c132c73a709bd83858b3419f38ec23 (patch)
tree61541d1a0e73877fc0b70611cafac6b3b229ca42 /drivers/net/usb/rndis_host.c
parent2e2ec952350f25242f2e0539db16b1e46f9eb01b (diff)
USB: rndis_host: debug info clobbered before it is logged
The MTU throttle-down if a RNDIS device doesn't support a particular packet size is being incorrectly logged. The attempted packet size is being clobbered before it gets logged. First patch; please inform if I'm doing this incorrectly. Diff'd against latest official source as per the FAQ; forward port to current git version is straightforward. Signed-off-by: George Nassar <george.nassar@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/net/usb/rndis_host.c')
-rw-r--r--drivers/net/usb/rndis_host.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/net/usb/rndis_host.c b/drivers/net/usb/rndis_host.c
index 0caa8008c51c..f56dec6119c3 100644
--- a/drivers/net/usb/rndis_host.c
+++ b/drivers/net/usb/rndis_host.c
@@ -362,12 +362,12 @@ generic_rndis_bind(struct usbnet *dev, struct usb_interface *intf, int flags)
362 retval = -EINVAL; 362 retval = -EINVAL;
363 goto halt_fail_and_release; 363 goto halt_fail_and_release;
364 } 364 }
365 dev->hard_mtu = tmp;
366 net->mtu = dev->hard_mtu - net->hard_header_len;
367 dev_warn(&intf->dev, 365 dev_warn(&intf->dev,
368 "dev can't take %u byte packets (max %u), " 366 "dev can't take %u byte packets (max %u), "
369 "adjusting MTU to %u\n", 367 "adjusting MTU to %u\n",
370 dev->hard_mtu, tmp, net->mtu); 368 dev->hard_mtu, tmp, tmp - net->hard_header_len);
369 dev->hard_mtu = tmp;
370 net->mtu = dev->hard_mtu - net->hard_header_len;
371 } 371 }
372 372
373 /* REVISIT: peripheral "alignment" request is ignored ... */ 373 /* REVISIT: peripheral "alignment" request is ignored ... */