Revision: 14226
http://edk2.svn.sourceforge.net/edk2/?rev=14226&view=rev
Author: erictian
Date: 2013-03-29 06:53:57 +0000 (Fri, 29 Mar 2013)
Log Message:
-----------
MdeMdeModulePkg/Usb: Fixed two usb issues
1.Fix the bug in interface parser logic for usb camera device. Reserve device
address if the device doesn?\226?\128?\153t get disconnected.
2.Some usb 1.1 devices require the context evaluation immediately with actual
max packet size after detecting the device max packet size.
Signed-off-by: Feng Tian <[email protected]>
Reviewed-by: Elvin Li <[email protected]>
Modified Paths:
--------------
trunk/edk2/MdeModulePkg/Bus/Pci/XhciDxe/Xhci.c
trunk/edk2/MdeModulePkg/Bus/Usb/UsbBusDxe/UsbDesc.c
trunk/edk2/MdeModulePkg/Bus/Usb/UsbBusDxe/UsbEnumer.c
Modified: trunk/edk2/MdeModulePkg/Bus/Pci/XhciDxe/Xhci.c
===================================================================
--- trunk/edk2/MdeModulePkg/Bus/Pci/XhciDxe/Xhci.c 2013-03-29 03:14:30 UTC
(rev 14225)
+++ trunk/edk2/MdeModulePkg/Bus/Pci/XhciDxe/Xhci.c 2013-03-29 06:53:57 UTC
(rev 14226)
@@ -1,7 +1,7 @@
/** @file
The XHCI controller driver.
-Copyright (c) 2011 - 2012, Intel Corporation. All rights reserved.<BR>
+Copyright (c) 2011 - 2013, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD
License
which accompanies this distribution. The full text of the license may be
found at
@@ -916,7 +916,7 @@
((Request->RequestType == USB_REQUEST_TYPE (EfiUsbDataIn,
USB_REQ_TYPE_STANDARD, USB_TARGET_DEVICE)) ||
((Request->RequestType == USB_REQUEST_TYPE (EfiUsbDataIn,
USB_REQ_TYPE_CLASS, USB_TARGET_DEVICE))))) {
DescriptorType = (UINT8)(Request->Value >> 8);
- if ((DescriptorType == USB_DESC_TYPE_DEVICE) && (*DataLength == sizeof
(EFI_USB_DEVICE_DESCRIPTOR))) {
+ if ((DescriptorType == USB_DESC_TYPE_DEVICE) && ((*DataLength == sizeof
(EFI_USB_DEVICE_DESCRIPTOR)) || ((DeviceSpeed == EFI_USB_SPEED_FULL) &&
(*DataLength == 8)))) {
ASSERT (Data != NULL);
//
// Store a copy of device scriptor as hub device need this info to
configure endpoint.
Modified: trunk/edk2/MdeModulePkg/Bus/Usb/UsbBusDxe/UsbDesc.c
===================================================================
--- trunk/edk2/MdeModulePkg/Bus/Usb/UsbBusDxe/UsbDesc.c 2013-03-29 03:14:30 UTC
(rev 14225)
+++ trunk/edk2/MdeModulePkg/Bus/Usb/UsbBusDxe/UsbDesc.c 2013-03-29 06:53:57 UTC
(rev 14226)
@@ -2,7 +2,7 @@
Manage Usb Descriptor List
-Copyright (c) 2007, Intel Corporation. All rights reserved.<BR>
+Copyright (c) 2007 - 2013, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD
License
which accompanies this distribution. The full text of the license may be
found at
@@ -360,8 +360,8 @@
Setting = UsbParseInterfaceDesc (DescBuf, Len, &Consumed);
if (Setting == NULL) {
- DEBUG (( EFI_D_ERROR, "UsbParseConfigDesc: failed to parse interface
setting\n"));
- goto ON_ERROR;
+ DEBUG (( EFI_D_ERROR, "UsbParseConfigDesc: warning: failed to get
interface setting, stop parsing now.\n"));
+ break;
} else if (Setting->Desc.InterfaceNumber >= NumIf) {
DEBUG (( EFI_D_ERROR, "UsbParseConfigDesc: mal-formated interface
descriptor\n"));
Modified: trunk/edk2/MdeModulePkg/Bus/Usb/UsbBusDxe/UsbEnumer.c
===================================================================
--- trunk/edk2/MdeModulePkg/Bus/Usb/UsbBusDxe/UsbEnumer.c 2013-03-29
03:14:30 UTC (rev 14225)
+++ trunk/edk2/MdeModulePkg/Bus/Usb/UsbBusDxe/UsbEnumer.c 2013-03-29
06:53:57 UTC (rev 14226)
@@ -2,7 +2,7 @@
Usb bus enumeration support.
-Copyright (c) 2007 - 2012, Intel Corporation. All rights reserved.<BR>
+Copyright (c) 2007 - 2013, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD
License
which accompanies this distribution. The full text of the license may be
found at
@@ -814,9 +814,6 @@
return EFI_SUCCESS;
ON_ERROR:
- if (Address != Bus->MaxDevices) {
- Bus->Devices[Address] = NULL;
- }
if (Child != NULL) {
UsbFreeDevice (Child);
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
------------------------------------------------------------------------------
Own the Future-Intel(R) Level Up Game Demo Contest 2013
Rise to greatness in Intel's independent game demo contest. Compete
for recognition, cash, and the chance to get your game on Steam.
$5K grand prize plus 10 genre and skill prizes. Submit your demo
by 6/6/13. http://altfarm.mediaplex.com/ad/ck/12124-176961-30367-2
_______________________________________________
edk2-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/edk2-commits