Newer
Older
AMI-Aptio-BIOS-Reversed / AmiModulePkg / Usb / Int13 / UsbInt13 / README.md
@Ajax Dong Ajax Dong 2 days ago 1 KB Restructure the repo

UsbInt13

Index Module Size Phase
300 UsbInt13.efi 8,900 bytes (22C4h) DXE

Overview

UsbInt13 is a DXE driver that provides legacy INT13 BIOS support for USB mass storage devices in the Lenovo HR650X platform. It enables booting from USB floppy, USB HDD, and USB CDROM devices when the system operates in legacy BIOS / CSM compatibility mode. The driver allocates and manages INT13 device parameter tables in legacy BIOS data areas, handles USB hotplug events by installing and uninstalling INT13 handlers, and reorders boot priority at ReadyToBoot to honor user boot selection.

Key Functions

  • UsbInt13DriverEntry -- Main driver entry point; initializes global pointers and registers callbacks
  • UsbInt13AllocateLegacyStructs -- Allocates INT13 parameter tables and BBS data structures in legacy memory
  • UsbInt13InitHotplugStructs -- Initializes three hotplug device descriptors (FDD, HDD, CDROM)
  • UsbInt13ReadyToBootCallback -- Reorders boot priority and installs INT13 handlers at ReadyToBoot
  • UsbInt13BuildInt13ParamTable -- Builds INT13 device parameter table entries for each detected device
  • UsbInt13EnumerateUsbDevices -- Enumerates USB host controllers and connected mass storage devices
  • UsbInt13InstallDevice -- Installs an INT13 handler for a discovered USB device
  • UsbInt13UninstallDevice -- Removes an INT13 handler on device removal

Dependencies

  • EFI_USB_HC_PROTOCOL -- USB host controller access
  • Legacy BIOS BBS protocol -- BBS table management
  • HOB list -- system configuration hand-off blocks

Platform

  • Source: AmiModulePkg/Usb/Int13/UsbInt13.c
  • Architecture: X64 (PE32+)
  • Formats: PE32+, 5 sections (.text, .rdata, .data, section_3, .xdata)
  • SHA256: 5d61a388d1438cdc245f7887cfaa8a4d2d7c7b1e49739012f9389f80e87f4956