<feed xmlns='http://www.w3.org/2005/Atom'>
<title>Tianocore/edk2.git/MdeModulePkg/Bus/Usb, branch dependabot/github_actions/github/codeql-action-4.39.1</title>
<subtitle>EDK II (mirror)</subtitle>
<id>https://git.radix-linux.su/Tianocore/edk2.git/atom?h=dependabot%2Fgithub_actions%2Fgithub%2Fcodeql-action-4.39.1</id>
<link rel='self' href='https://git.radix-linux.su/Tianocore/edk2.git/atom?h=dependabot%2Fgithub_actions%2Fgithub%2Fcodeql-action-4.39.1'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/'/>
<updated>2026-10-21T21:53:42+00:00</updated>
<entry>
<title>MdeModulePkg/UsbBusDxe: Free BOS buffer on read failure</title>
<updated>2026-10-21T21:53:42+00:00</updated>
<author>
<name>Michael D Kinney</name>
<email>michael.d.kinney@intel.com</email>
</author>
<published>2026-10-16T21:45:07+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=52fa6fe8996f4b11881757b9300ee4ec584432ba'/>
<id>urn:sha1:52fa6fe8996f4b11881757b9300ee4ec584432ba</id>
<content type='text'>
UsbGetDevBosDesc() allocates a buffer for the initial BOS descriptor
request. If that request fails, the success-only cleanup is skipped and
the function returns without freeing the buffer. Repeated enumeration
attempts can leak one allocation per failure.

Free the initial buffer before returning the transfer error.

The leaking retrieval helper was introduced by PR #12714:
https://github.com/tianocore/edk2/pull/12714

Signed-off-by: Michael D Kinney &lt;michael.d.kinney@intel.com&gt;
</content>
</entry>
<entry>
<title>MdeModulePkg/UsbBusDxe: Bound BOS capability parsing</title>
<updated>2026-10-21T21:53:42+00:00</updated>
<author>
<name>Michael D Kinney</name>
<email>michael.d.kinney@intel.com</email>
</author>
<published>2026-10-16T21:45:03+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=bf25b6e4017b120decd2bb97384a8f319ba4303e'/>
<id>urn:sha1:bf25b6e4017b120decd2bb97384a8f319ba4303e</id>
<content type='text'>
UsbIsSSDevice() trusts device-reported NumDeviceCaps and capability
Length fields without bounding reads to the BOS buffer. Malformed values
can cause out-of-bounds reads and an exception during device enumeration.

Validate the BOS header and total length. Before reading each capability,
check that its header and declared length fit in the remaining bytes.
Reject malformed or truncated descriptors and recognize SuperSpeed only
after validating the complete capability list.

The unbounded parser was introduced by PR #12714:
https://github.com/tianocore/edk2/pull/12714

Signed-off-by: Michael D Kinney &lt;michael.d.kinney@intel.com&gt;
</content>
</entry>
<entry>
<title>MdeModulePkg/UsbBusDxe: Guard descriptor on SS retry</title>
<updated>2026-10-21T21:53:42+00:00</updated>
<author>
<name>Michael D Kinney</name>
<email>michael.d.kinney@intel.com</email>
</author>
<published>2026-10-16T21:44:42+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=7250fc9e3941e2899ab72ee7f30267c78615c7d3'/>
<id>urn:sha1:7250fc9e3941e2899ab72ee7f30267c78615c7d3</id>
<content type='text'>
UsbEnumerateNewDev() frees DevDesc before resetting the port for an
enumeration retry. UsbRootHubResetPort() scans that device during the
reset and previously dereferenced DevDesc without checking it.

For a SuperSpeed-capable device running below SuperSpeed, IsSSDev and
Speed still satisfy the scan's preceding conditions after DevDesc is
cleared. The DeviceClass access can therefore cause a null-pointer
exception. Add descriptor checks before those dereferences and clear
IsSSDev when freeing the descriptor.

The unsafe reset dereference was introduced by PR #12714:
https://github.com/tianocore/edk2/pull/12714

Signed-off-by: Michael D Kinney &lt;michael.d.kinney@intel.com&gt;
</content>
</entry>
<entry>
<title>MdeModulePkg/UsbBusDxe: Add GoogleTest coverage</title>
<updated>2026-10-21T21:53:42+00:00</updated>
<author>
<name>Michael D Kinney</name>
<email>michael.d.kinney@intel.com</email>
</author>
<published>2026-10-16T22:41:02+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=19bca85619073be97bf8c29f4511e6a78c7ed388'/>
<id>urn:sha1:19bca85619073be97bf8c29f4511e6a78c7ed388</id>
<content type='text'>
Test valid SuperSpeed recognition and reject capabilities extending beyond
the BOS total length or supplied buffer. Verify failed initial BOS reads
free their buffers and root-hub reset succeeds after descriptor cleanup.

Signed-off-by: Michael D Kinney &lt;michael.d.kinney@intel.com&gt;
</content>
</entry>
<entry>
<title>MdeModulePkg/UsbMassStorageDxe: Report blank optical media as media absent</title>
<updated>2026-10-21T04:58:42+00:00</updated>
<author>
<name>haword</name>
<email>zhenghaowei@loongson.cn</email>
</author>
<published>2026-10-16T02:09:03+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=705de24e39a093ceb57fd7372e697e73380e57fe'/>
<id>urn:sha1:705de24e39a093ceb57fd7372e697e73380e57fe</id>
<content type='text'>
A blank (unwritten) optical disc reports a zero capacity through READ
CAPACITY (LastBlock == 0).  The driver currently exposes such a device
with BlockSize 2048 and LastBlock 0, so upper layers such as PartitionDxe
and the BDS removable-media boot probe keep reading LBA 0. The drive
rejects the read with "Illegal Request / LBA out of range" (sense 5/21/0)
and UsbMassReadBlocks enters its reset recovery loop. So each failed probe
can block for tens of seconds and boot appears to hang.

Treat an optical device with zero capacity as media absent so that the
media is skipped instead of being probed.

Signed-off-by: Haword &lt;zhenghaowei@loongson.cn&gt;
</content>
</entry>
<entry>
<title>MdeModulePkg/UsbBusDxe: Raise TPL to CALLBACK for wanted UsbIo connect</title>
<updated>2026-09-21T06:06:06+00:00</updated>
<author>
<name>Marlboro_Chuang</name>
<email>Marlboro_Chuang@dell.com</email>
</author>
<published>2025-07-27T08:35:30+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=2ba169b02f7eebb34816c2d02a1cd9f92a524b1a'/>
<id>urn:sha1:2ba169b02f7eebb34816c2d02a1cd9f92a524b1a</id>
<content type='text'>
Raise TPL to TPL_CALLBACK around the ConnectController() call in
UsbBusRecursivelyConnectWantedUsbIo() and restore the original TPL
afterward.

UsbBusRecursivelyConnectWantedUsbIo() is normally reached through the
DriverBinding Start routine invoked by gBS-&gt;ConnectController(), which
runs at TPL_APPLICATION. While the wanted UsbIo handle is being
connected, the USB device can be removed. The device removal polling
event in UsbBus runs at TPL_CALLBACK. If the connect runs at
TPL_APPLICATION, that event can preempt the connection and cause
commands to be sent to a stale or non-existent USB device address,
producing a lot of timeout transfers.

This differs from UsbConnectDriver(), which is called from the
enumeration polling event (XHCI async event) and is usually already
at TPL_CALLBACK or TPL_NOTIFY. That function uses RestoreTPL()/
RaiseTPL() to ensure ConnectController() runs at TPL_CALLBACK.

Signed-off-by: Marlboro_Chuang &lt;marlboro.chuang@dell.com&gt;
</content>
</entry>
<entry>
<title>MdeModulePkg/UsbBusDxe: Handle a quirk in Interface descriptor</title>
<updated>2026-09-21T04:54:36+00:00</updated>
<author>
<name>Marlboro_Chuang</name>
<email>Marlboro_Chuang@dell.com</email>
</author>
<published>2025-07-27T10:39:54+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=82138022d2c283b6bbddb1cc575e2d2f8e66f779'/>
<id>urn:sha1:82138022d2c283b6bbddb1cc575e2d2f8e66f779</id>
<content type='text'>
Some specific device requires a quirk in the Interface descriptor for
InterfaceNumber to work properly

[Suggested Solution]
Implement the mechanism to ensure the first InterfaceNumber not equal
to zero.

Signed-off-by: Marlboro_Chuang &lt;marlboro.chuang@dell.com&gt;
</content>
</entry>
<entry>
<title>MdeModulePkg/UsbBusDxe: Fix UsbPortReset might run into recursive loop</title>
<updated>2026-07-31T10:54:54+00:00</updated>
<author>
<name>Jared Pan</name>
<email>jared.pan@dell.com</email>
</author>
<published>2026-06-23T03:09:25+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=7c2ec06a93ef36396db6f46f983a94d2aa26acdb'/>
<id>urn:sha1:7c2ec06a93ef36396db6f46f983a94d2aa26acdb</id>
<content type='text'>
UsbSelectConfig will introduce the UsbConnectDriver call.
If this UsbPortReset is happened in the Usb device driver Start() routine and the device FW can not be recovered by PortReset, the UsbSelectConfig will introduce the recursive loop.

[Suggested solution]
Since UsbPortReset should not change the Bus Topology, the Reset flow should only SetAddress and reconfigure the device.

Signed-off-by: Marlboro Chuang &lt;marlboro.chuang@dell.com&gt;
Signed-off-by: Jared Pan &lt;jared.pan@dell.com&gt;
</content>
</entry>
<entry>
<title>MdeModulePkg/UsbBusDxe: BOS Descriptor Check for SS Devices</title>
<updated>2026-07-22T07:25:57+00:00</updated>
<author>
<name>Jared Pan</name>
<email>jared.pan@dell.com</email>
</author>
<published>2026-07-13T08:10:37+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=4d5f8e68a1e9baec74c8bd73c0dd09a596c1c3f9'/>
<id>urn:sha1:4d5f8e68a1e9baec74c8bd73c0dd09a596c1c3f9</id>
<content type='text'>
Some SuperSpeed-capable devices may fall back to High-Speed
mode and cause subsequent commands to fail.

[Suggested Solution]
Check the BOS descriptor to verify SuperSpeed support and
trigger a port reset if needed to re-enumerate the device
properly.

Signed-off-by: Marlboro Chuang &lt;marlboro.chuang@dell.com&gt;
Signed-off-by: Jared Pan &lt;jared.pan@dell.com&gt;
</content>
</entry>
<entry>
<title>MdeModulePkg/UsbBusPei: Use dynamic buffer for USB configuration data</title>
<updated>2026-07-21T03:50:20+00:00</updated>
<author>
<name>DC-Damien</name>
<email>damien.chen@dell.com</email>
</author>
<published>2026-06-05T08:29:15+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/Tianocore/edk2.git/commit/?id=6a9c048ba54c7e27898b861410741f5b27bfb2d6'/>
<id>urn:sha1:6a9c048ba54c7e27898b861410741f5b27bfb2d6</id>
<content type='text'>
USB devices whose configuration descriptor TotalLength exceeds 1024
bytes (e.g. IR cameras with large descriptor tables) previously hit
an EFI_DEVICE_ERROR hard-limit and failed to enumerate in PEI.

Replace the fixed array with a UINT8 * pointer and dynamically
allocate the exact amount of memory required via
PeiServicesAllocatePool() after the TotalLength is learned from the
initial 4-byte descriptor probe.

Signed-off-by: Damien Chen &lt;damien.chen@dell.com&gt;
</content>
</entry>
</feed>
