audk/MdeModulePkg/Bus/Pci
Laszlo Ersek c3d5d800d7 MdeModulePkg/EhciDxe: fix host controller reset condition in BindingStart
Commit 09943f5ecc ("MdeModulePkg: Skip to manage usb debug port in EDKII
EHCI driver if it's used by usb debug port driver", 2012-04-28) made the
host controller reset in EhcDriverBindingStart() conditional. The intent
was to avoid the reset when
- one of the USB ports on the host controller was a Debug Port, AND
- the Debug Port was in use.

This translates to the following positive condition: reset the controller
only if:
- no USB port on the host controller is a Debug Port, OR
- the Debug Port is not in use.

Commit 09943f5ecc failed to implement the first subcondition, and thus
the result is too strict now (for resetting the host controller). Relax it
to the correct condition.

This issue was found by Steven Shi on QEMU. QEMU's EHCI device model does
not have a Debug Port. In repeated disconnect / connect cycles, the
controller is never reset in EhcDriverBindingStart(), therefore the
devices on the controller are never re-enumerated after a disconnect.

Cc: Gerd Hoffmann <kraxel@redhat.com>
Cc: Jian J Wang <jian.j.wang@intel.com>
Cc: Ruiyu Ni <ruiyu.ni@intel.com>
Cc: Star Zeng <star.zeng@intel.com>
Cc: Steven Shi <steven.shi@intel.com>
Reported-by: Steven Shi <steven.shi@intel.com>
Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=1129
Fixes: 09943f5ecc
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Star Zeng <star.zeng@intel.com>
Tested-by: Steven Shi <steven.shi@intel.com>
2018-09-05 14:00:12 +02:00
..
EhciDxe MdeModulePkg/EhciDxe: fix host controller reset condition in BindingStart 2018-09-05 14:00:12 +02:00
EhciPei MdeModulePkg EhciPei: Remove a redundant function 2018-08-30 14:44:03 +08:00
IdeBusPei MdeModulePkg: Clean up source files 2018-06-28 11:19:45 +08:00
IncompatiblePciDeviceSupportDxe MdeModulePkg: Clean up source files 2018-06-28 11:19:45 +08:00
NonDiscoverablePciDeviceDxe MdeModulePkg/NonDiscoverable: fix memory override bug 2017-11-08 12:52:04 +08:00
NvmExpressDxe MdeModulePkg NvmExpressDxe: Remove redundant functions 2018-08-21 16:28:56 +08:00
NvmExpressPei MdeModulePkg: Remove redundant library classes and GUIDs 2018-08-20 14:53:45 +08:00
PciBusDxe MdeModulePkg/PciBus: Restrict one VGA per HostBridge not Segment 2018-08-27 09:40:22 +08:00
PciHostBridgeDxe MdeModulePkg: Clean up source files 2018-06-28 11:19:45 +08:00
PciSioSerialDxe MdeModulePkg: Clean up source files 2018-06-28 11:19:45 +08:00
SataControllerDxe MdeModulePkg SataControllerDxe: Use compare logic in if condition 2018-07-03 14:44:08 +08:00
SdMmcPciHcDxe MdeModulePkg SdMmcPciHcDxe: Remove redundant functions 2018-08-21 16:28:57 +08:00
SdMmcPciHcPei MdeModulePkg: Clean up source files 2018-06-28 11:19:45 +08:00
UfsPciHcDxe MdeModulePkg: Remove redundant library classes and GUIDs 2018-08-20 14:53:45 +08:00
UfsPciHcPei MdeModulePkg: Clean up source files 2018-06-28 11:19:45 +08:00
UhciDxe MdeModulePkg: Clean up source files 2018-06-28 11:19:45 +08:00
UhciPei MdeModulePkg UhciPei: Remove redundant functions 2018-08-21 16:28:58 +08:00
XhciDxe MdeModulePkg XhciDxe: Remove redundant functions 2018-08-21 16:28:59 +08:00
XhciPei MdeModulePkg XhciPei: Remove redundant functions 2018-08-21 16:28:59 +08:00