Commit Graph

216 Commits

Author SHA1 Message Date
eric_tian efe9186f09 add error handling on usb related modules.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@9566 6f19259b-4bc3-4df7-8a09-765794883524
2009-12-16 00:58:46 +00:00
AJFISH f147a39e3c Tempoprary removal of this ASSERT as it crashes the BeagleBoard. We can put it back in when we figure out the issue.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@9547 6f19259b-4bc3-4df7-8a09-765794883524
2009-12-10 00:24:29 +00:00
vanjeff 0ce94f384e Set Handle to NULL when creating a new handle.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@9358 6f19259b-4bc3-4df7-8a09-765794883524
2009-10-26 02:28:49 +00:00
davidhuang 9060e3ec6d 1. Impl PI 1.2 PCI part. Major changes include:
a. Update PciBusDxe module, and move it from IntelFrameworkModulePkg to MdeModulePkg
  b. Move IncompatiblePciDeviceSupportDxe module from IntelFrameworkModulePkg to MdeModulePkg
  c. Update the related consumes in inf/dsc/fdf

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@9347 6f19259b-4bc3-4df7-8a09-765794883524
2009-10-20 03:43:40 +00:00
jljusten ce422d36a8 MdeModule EhciDxe: Fix compiler warning for IA32 architecture.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@9340 6f19259b-4bc3-4df7-8a09-765794883524
2009-10-14 20:47:57 +00:00
eric_tian 739802e49c update code to eliminate the wrong assumption that pci address is equal to host address in all archs.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@9339 6f19259b-4bc3-4df7-8a09-765794883524
2009-10-14 06:22:49 +00:00
jljusten d7576cf9b6 MdeModulePkg-UsbBusDxe: Add work around for slower USB hubs/devices
Increase the value of USB_GENERAL_DEVICE_REQUEST_TIMEOUT from
50 milliseconds to 100 milliseconds.  This provides a work around
for slower USB hubs and devices.

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@9330 6f19259b-4bc3-4df7-8a09-765794883524
2009-10-05 17:59:53 +00:00
eric_tian db731882fa For the data region which will be touched by Pci Bus Master, we should allocate memory by PciIo.AllocateBuffer() but not AllocatePool() base library API. So the memory region can be used to map into Pci controller-specific address thru PciIo.Map().
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@9323 6f19259b-4bc3-4df7-8a09-765794883524
2009-09-30 03:00:36 +00:00
vanjeff 6fe852082f 1. updated PCI/AGP Devices to check RemainingDevicePath in Supported() and Start() functions. The main changes are:
a. Add check validation of RemainingDevicePath in Supported()
  b. In Star() function, if RemaingDevicePath is the End of Device Path Node, don't create child device and return EFI_SUCCESS.
2. fixed one device path issue in ScsiBus driver.



git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@9264 6f19259b-4bc3-4df7-8a09-765794883524
2009-09-15 07:50:48 +00:00
vanjeff af4a63857c updated the Bus Driver that is able to create all or one of its child handles on each call to Start() not to create new child handle if RemainingDeviepath is the End of Device Path Node, per UEFI 2.3.
The others changes include:
1. Check RemainingDevicePath at beginning of Supported(), make sure it has been verified before Start() is called.
2. Check IO protocol firstly rather than EfiDevicePathProtocolGuid, reduce the times entering into Start() function because EfiDevicePathProtocolGuid existed on most of handle.
3. If no any child device is created on last time, and RemainingDevicePath is valid Uart Devcie path, go on creating child device handle based on this RemainingDevicePath.


git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@9262 6f19259b-4bc3-4df7-8a09-765794883524
2009-09-14 08:55:03 +00:00
eric_tian 3af875e220 In various archs, Processor memory address may not be same with Pci memory address. For usb host controller, we should use pci memory address to initialize framelist register and all address field in QH/TD.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@9259 6f19259b-4bc3-4df7-8a09-765794883524
2009-09-14 05:26:09 +00:00
eric_tian 16a97771ad free allocated memory in error handler.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@9173 6f19259b-4bc3-4df7-8a09-765794883524
2009-08-24 06:24:24 +00:00
eric_tian 73f8ef8c08 add error handler in return places.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@9119 6f19259b-4bc3-4df7-8a09-765794883524
2009-08-19 02:32:56 +00:00
eric_tian 9420fc148a modify the incorrect timeout value definitions in Usb driver
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@9117 6f19259b-4bc3-4df7-8a09-765794883524
2009-08-19 01:41:43 +00:00
eric_tian ba19956ac3 add comments to clarify the enhancement on EHCI driver, which is guaranteed to get attached to EHCI host controller before UHCI driver attaches to uhci host controller.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@9040 6f19259b-4bc3-4df7-8a09-765794883524
2009-08-11 05:55:14 +00:00
eric_tian a261044cf5 code cleanup:
1. remove unused macro/remove unnecessary included header file
2. for those values defined by PCI spec, use the naming of definition in IndustryStandard/Pci.h
3. use BITX macro in Base.h rather than define one by self.

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@8992 6f19259b-4bc3-4df7-8a09-765794883524
2009-07-24 05:34:55 +00:00
eric_tian cd92e3fb28 Adding a segment code to make sure that the EHCI controller get attached to the EHCI controller before the UHCI driver attaches to the UHCI controller
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@8984 6f19259b-4bc3-4df7-8a09-765794883524
2009-07-23 12:50:08 +00:00
rsun3 88e349f1fe Fixed a bug that the system hangs with an assert in DiskIo.c that is division overflow due to block size == 0 when no flppy media is present in a specific type of USB floppy drive (NEC PC-VP-BU04)at power on.
Root cause is that Read Capacity command returns media not present error, then UsbMassStorage driver issues Sense Request command to get the sense data. However, the USB floppy drive still returns the previous error for the Sense Request command. UsbBootRequestSense() does not handle this case correctly and returns EFI_SUCCESS so that the block size of the Block IO protocol instance is set to be 0.

Solution is to fix the logic to handle the case and add protective logic to avoid setting block size to be 0.

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@8979 6f19259b-4bc3-4df7-8a09-765794883524
2009-07-23 01:30:16 +00:00
vanjeff 6795df33dd remove UndiRuntimeDxe from MdeModulePkg to OptionRomPkg
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@8739 6f19259b-4bc3-4df7-8a09-765794883524
2009-07-03 14:36:04 +00:00
gikidy d14faa5275 Update the SCSI Disk Driver to not mount drives on physical only SCSI channels
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@8677 6f19259b-4bc3-4df7-8a09-765794883524
2009-06-29 05:58:14 +00:00
gikidy ef13cf23ee Enhance error handle of BuildDevicePath for it is possible to receive other errors.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@8667 6f19259b-4bc3-4df7-8a09-765794883524
2009-06-26 06:29:00 +00:00
eric_tian 7e038442a8 remove the self-implementation on checksum() in this module by using BaseLib.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@8637 6f19259b-4bc3-4df7-8a09-765794883524
2009-06-24 02:30:53 +00:00
gikidy 4607d9e5e1 The USB keyboard driver use too high TPL event (Notify) to a ckeck repeated key stoke, should use CallBack instead.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@8527 6f19259b-4bc3-4df7-8a09-765794883524
2009-06-11 06:25:30 +00:00
mdkinney 776a705ef1 Update USB Mass Storage driver to declare its dependency on the BaseLib
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@8353 6f19259b-4bc3-4df7-8a09-765794883524
2009-05-20 20:04:23 +00:00
rsun3 d1a8a1dc99 Fix a bug in the SCSI Bus driver due to which some SCSI devices can not be discovered. Per SCSI spec, the standard INQUIRY data shall contain at least 36 bytes and the length of the data is variable. The definition
///
/// Standard INQUIRY data format
///
typedef struct {
  UINT8 Peripheral_Type : 5;
  UINT8 Peripheral_Qualifier : 3;
  UINT8 DeviceType_Modifier : 7;
  UINT8 Rmb : 1;
  UINT8 Version;
  UINT8 Response_Data_Format;
  UINT8 Addnl_Length;
  UINT8 Reserved_5_95[95 - 5 + 1];
} EFI_SCSI_INQUIRY_DATA;

is longer than 36 bytes and EFI_BAD_BUFFER_SIZE may be returned if the actual inquiry data is less than that of EFI_SCSI_INQUIRY_DATA.

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@8329 6f19259b-4bc3-4df7-8a09-765794883524
2009-05-19 05:38:40 +00:00
gikidy 0254efc01e Replace references to RFC 3066 with RFC 4646.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@8212 6f19259b-4bc3-4df7-8a09-765794883524
2009-04-30 05:32:11 +00:00
vanjeff bdc825139c Changed ID into Id.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@8130 6f19259b-4bc3-4df7-8a09-765794883524
2009-04-20 05:47:57 +00:00
rsun3 cb7d01c0c9 HII Library Class interface refine.
The "HiiLib" prefix for all HII Library API function names changed to "Hii".

Remove: 
  HiiLibPreparePackageList(), replaced by HiiAddPackages()
  HiiLibNewString(), replaced by HiiSetString()
  HiiLibGetStringFromHandle(), replaced by HiiGetString()
  HiiLibGetStringFromToken(), replaced by HiiGetPackageString()
  HiiLibExtractGuidFromHiiHandle()
  HiiLibDevicePathToHiiHandle()
  HiiLibGetSupportedSecondaryLanguages()
  HiiLibGetSupportedLanguageNumber()
  HiiLibExportPackageLists()
  HiiLibListPackageLists()
  
Interface change:
  HiiAddPackages()
  HiiSetString()
  HiiGetString()
  HiiGetHiiHandles()

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@8083 6f19259b-4bc3-4df7-8a09-765794883524
2009-04-14 10:47:19 +00:00
jljusten 6d3ea23f11 Fix various 'EFIAPI' inconsistencies found while building MdeModulePkg.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@8062 6f19259b-4bc3-4df7-8a09-765794883524
2009-04-10 20:58:18 +00:00
vanjeff 0428a6cb12 fixed DMA not be stopped issue when gBS->ExitBootServices called.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@8058 6f19259b-4bc3-4df7-8a09-765794883524
2009-04-10 08:31:45 +00:00
qhuang8 c41c3e55d5 Install default keyboard layout package in USB keyboard driver.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@8056 6f19259b-4bc3-4df7-8a09-765794883524
2009-04-10 04:28:13 +00:00
vanjeff 8a67d804b3 return value not follow spec.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@8028 6f19259b-4bc3-4df7-8a09-765794883524
2009-04-07 02:29:49 +00:00
jji4 b5378fa05e Remove bypass of F11 and F12.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@8019 6f19259b-4bc3-4df7-8a09-765794883524
2009-04-03 06:47:25 +00:00
jji4 b96cd3133d Read-Capacity16 command added for SCSI drivers
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@8000 6f19259b-4bc3-4df7-8a09-765794883524
2009-04-01 08:25:36 +00:00
eric_tian 1e5914b54a R8 tracker sync:
Our UEFI Driver supports both SCSI Passthru (SPT) and Ext SCSI Passthru (That is our driver installs both SCSI Passthru and Ext SCSI Passthru). When we unload our driver SCSI Bus driver closes only ESPT and keeps SPT open. Due to this when I load my driver second time the SPT installation will fail and now attempting to unload will either crash the system or hang the system. 

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@7906 6f19259b-4bc3-4df7-8a09-765794883524
2009-03-19 07:03:01 +00:00
vanjeff 0dc9978436 add check for invalid handle.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@7795 6f19259b-4bc3-4df7-8a09-765794883524
2009-03-04 04:31:46 +00:00
eric_tian 3dcdbe7a52 update
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@7694 6f19259b-4bc3-4df7-8a09-765794883524
2009-02-25 13:08:46 +00:00
vanjeff 7fc80d4484 Retired gSimpleTextInExNotifyGuid, used local structure address to be notify handle.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@7666 6f19259b-4bc3-4df7-8a09-765794883524
2009-02-25 05:35:12 +00:00
vanjeff aa8f4f55ff 1. Retired HotPlugDevice protocol.
2. Check devicepath node to get hot plug information. Currently, USB and PCCard device are checked.

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@7562 6f19259b-4bc3-4df7-8a09-765794883524
2009-02-23 02:51:45 +00:00
xli24 fbfa4a1da7 Minor update on capitalization for ECC check.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@7561 6f19259b-4bc3-4df7-8a09-765794883524
2009-02-23 02:47:51 +00:00
vanjeff db0bd81c85 enhanced security check.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@7516 6f19259b-4bc3-4df7-8a09-765794883524
2009-02-13 03:36:02 +00:00
eric_tian cb0b858d6e add assert logic to avoid Klocwork fake report
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@7513 6f19259b-4bc3-4df7-8a09-765794883524
2009-02-12 08:41:34 +00:00
eric_tian a1b749d074 add assert logic to avoid Klocwork fake report
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@7511 6f19259b-4bc3-4df7-8a09-765794883524
2009-02-12 06:23:15 +00:00
eric_tian fd0d484170 clean ecc
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@7461 6f19259b-4bc3-4df7-8a09-765794883524
2009-02-06 06:17:01 +00:00
xli24 ed3a31b518 Pass ECC check.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@7455 6f19259b-4bc3-4df7-8a09-765794883524
2009-02-06 05:34:53 +00:00
jji4 a676b86b67 Coding style checked
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@7454 6f19259b-4bc3-4df7-8a09-765794883524
2009-02-06 05:12:48 +00:00
eric_tian 4de1f28761 fix ecc
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@7451 6f19259b-4bc3-4df7-8a09-765794883524
2009-02-06 05:00:13 +00:00
qwang12 7b728d6273 Use TO_START and BY_START for UEFI driver model driver.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@7431 6f19259b-4bc3-4df7-8a09-765794883524
2009-02-04 07:59:50 +00:00
qwang12 17d6c2e782 3) Doxygen comment cleanup.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@7430 6f19259b-4bc3-4df7-8a09-765794883524
2009-02-04 07:02:05 +00:00
qwang12 e08d88c59e 3) Doxygen comment cleanup.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@7429 6f19259b-4bc3-4df7-8a09-765794883524
2009-02-04 06:59:23 +00:00