Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 17 Jan 2010 18:30:37 +0000 (UTC)
From:      Andrew Thompson <thompsa@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org
Subject:   svn commit: r202509 - stable/8/sys/dev/usb
Message-ID:  <201001171830.o0HIUbxY009454@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: thompsa
Date: Sun Jan 17 18:30:37 2010
New Revision: 202509
URL: http://svn.freebsd.org/changeset/base/202509

Log:
  MFC r201680
  
   scratch_size was incorrectly passed as language ID when retrieving the language
   ID table, this broke string retrieval on some devices.
  
  Submitted by:	Hans Petter Selasky
  Reported by:	Renato Botelho

Modified:
  stable/8/sys/dev/usb/usb_device.c
Directory Properties:
  stable/8/sys/   (props changed)
  stable/8/sys/amd64/include/xen/   (props changed)
  stable/8/sys/cddl/contrib/opensolaris/   (props changed)
  stable/8/sys/contrib/dev/acpica/   (props changed)
  stable/8/sys/contrib/pf/   (props changed)
  stable/8/sys/dev/xen/xenpci/   (props changed)

Modified: stable/8/sys/dev/usb/usb_device.c
==============================================================================
--- stable/8/sys/dev/usb/usb_device.c	Sun Jan 17 18:29:30 2010	(r202508)
+++ stable/8/sys/dev/usb/usb_device.c	Sun Jan 17 18:30:37 2010	(r202509)
@@ -1691,8 +1691,7 @@ usb_alloc_device(device_t parent_dev, st
 	    udev->ddesc.iSerialNumber) {
 		/* read out the language ID string */
 		err = usbd_req_get_string_desc(udev, NULL,
-		    (char *)scratch_ptr, 4, scratch_size,
-		    USB_LANGUAGE_TABLE);
+		    (char *)scratch_ptr, 4, 0, USB_LANGUAGE_TABLE);
 	} else {
 		err = USB_ERR_INVAL;
 	}



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201001171830.o0HIUbxY009454>