Watchdog Timer (WDT) DXE driver for the Intel Purley PCH (South Cluster LBG). Programs the PCH watchdog timer registers via IO ports, manages timer reload/start/stop before OS boot, and hooks into BDS/ReadyToBoot event notification.
0x390 - 0x1075 (26 functions)
13338
0178_WdtDxe_9af0b6f4206b/WdtDxe.efi (PE32+ X64, UEFI DXE driver)
| Address | Name | Purpose |
|---|---|---|
| 0x390 | _ModuleEntryPoint | DXE entry point: calls init then registration |
| 0x3AC | sub_3AC | UEFI boot/runtime services init + protocol locates |
| 0x578 | sub_578 | Main registration: installs timer event + notify callbacks |
| 0x704 | sub_704 | WDT runtime handler: runs before OS boot (TimerCallback) |
| 0x85C | sub_85C | WDT allow-known-reset entry point (wrapper for sub_E38) |
| 0x86C | sub_86C | IO port 32-bit read wrapper (__indword) |
| 0x89C | sub_89C | IO port 32-bit write wrapper (__outdword) |
| 0x8DC | sub_8DC | DebugLib singleton: locate and cache debug protocol |
| 0x95C | sub_95C | DebugPrint wrapper with CMOS-based debug level filtering |
| 0x9E4 | sub_9E4 | DebugAssert wrapper |
| 0xA24 | sub_A24 | UEFI config table lookup by GUID (EfiGetSystemConfigurationTable) |
| 0xAE8 | sub_AE8 | LegacyBoot event registration (EfiCreateEventLegacyBootEx) |
| 0xB8C | sub_B8C | PCH MMIO PCI config space read (cycle decoding base) |
| 0xBBC | sub_BBC | HOB list singleton: locate and cache gEfiHobListGuid |
| 0xC40 | sub_C40 | HOB traversal: find gEfiHobListGuid / HOB type 4 |
| 0xC90 | sub_C90 | Get WDT timer IO base address from PCH cycle decoding |
| 0xCEC | sub_CEC | ReloadAndStartTimer: program WDT counter + enable |
| 0xD94 | sub_D94 | DisableTimer: clear WDT enable bit |
| 0xDD4 | sub_DD4 | CheckTimerStatus: read back WDT status register |
| 0xE38 | sub_E38 | AllowKnownReset: set debug flag + clear known-reset bit |
| 0xE80 | sub_E80 | IsWdtRequired: check if WDT is required (bit 22-23 mask) |
| 0xED4 | sub_ED4 | IsWdtEnabled: check if WDT is currently enabled (bit 14) |
| 0xF28 | sub_F28 | PCD protocol singleton: locate and cache PCD protocol |
| 0xFB4 | sub_FB4 | GUID comparison (16-byte compare via ReadUnaligned64) |
| 0x101C | sub_101C | ReadUnaligned64 wrapper |
| 0x104C | sub_104C | ReadUnaligned16 wrapper (with alignment assert) |
0x390 _ModuleEntryPoint: Standard UEFI DXE entry point. Calls sub_3AC (init) then sub_578 (registration). Returns EFI_STATUS.
0x85C sub_85C: Called externally to allow known WDT reset. Delegates to sub_E38. This is the public interface for AllowKnownReset functionality.
sub_C90: Resolves the WDT timer's IO base address by reading the PCH's LPC IO decode registers via MMIO PCI config space (offset +0x84 from cycle decoding base). Returns (pci_reg & 0xFFFC) + 0x54. This is the PCH WDT timer base at IO port 0x54 (+ 0x84 = 0xA0 = TCO Base).sub_CEC: Programs the WDT counter (10-bit value, max 1023). Sets bit 15 (TCO_RLD) and bit 14 (TCO_TMR_HALT) if not debug BIOS, enables timer by setting bit 31. Disabled in debug BIOS (sets bit 22).sub_D94: Clears bits 14-15 (disables timer) and bit 22. Does NOT touch the WDT_IRQ bit (bit 17).sub_DD4: Reads timer status; returns 1 if bit 23 (TIMEOUT) is set, 0 otherwise.sub_E38: Sets byte_1A28 = 1, then clears bit 17 (WDT_IRQ / SMI) while keeping enable state.sub_E80: Checks bits 22-23 (0x3F0000 mask). Returns 1 if any set, meaning a prior boot timed out or had WDT fault.sub_ED4: Checks bit 14 (TCO_TMR_HALT). Returns 1 if timer is NOT halted (i.e., enabled).sub_86C: __indword(port) -- aligned DWORD IO read.sub_89C: __outdword(port, value) -- aligned DWORD IO write.sub_104C: *(uint16 *)addr with alignment assert.sub_101C: *(uint64 *)addr with null check.sub_8DC: Lazily locates the EFI_DEBUG_PROTOCOL via BootServices->LocateProtocol on first call, caches in qword_1A08.sub_95C: DebugPrint with CMOS-based severity filter. Reads CMOS 0x4B to get debug level. If level > 3, checks 0xFDAF0490 bit 1 for chipset override. Maps level to mask (EFI_D_ERROR for level 1, EFI_D_WARN for others) and calls protocol's DebugPrint.sub_9E4: DebugAssert. Calls protocol's Assert at index 8.gDS) via config table lookup.mPciUsra) via LocateProtocol for PCH cycle decoding.sub_BBC.sub_F28.sub_F28()+32(5) -- reads PCD token 5 (likely PcdWdtTimeout or similar).| Address | Name | Purpose |
|---|---|---|
| 0x19E8 | SystemTable | Cached EFI_SYSTEM_TABLE pointer |
| 0x19F0 | BootServices | Cached gBS pointer |
| 0x19F8 | ImageHandle | Cached driver image handle |
| 0x1A00 | RuntimeServices | Cached gRT pointer |
| 0x1A08 | qword_1A08 | EFI_DEBUG_PROTOCOL (lazy init) |
| 0x1A10 | qword_1A10 | DxeServicesTable (gDS) |
| 0x1A18 | qword_1A18 | MmPci base protocol (mPciUsra) |
| 0x1A20 | qword_1A20 | HOB list pointer (mHobList) |
| 0x1A28 | byte_1A28 | WDT debug flag: disables WDT in debug BIOS builds |
| 0x1A30 | qword_1A30 | PCD protocol pointer (mPcd) |
| 0x1A40 | ImageHandle_0 | Image handle for event registration (NotifyTpl) |
sub_D94 (DisableTimer) -- LegacyBoot notifysub_704 (RunWdtBeforeOsBoot) -- ReadyToBoot notifyCMOS Debug Level (RTC CMOS 0x4B)
0xFDAF0490 bit 1, falls back to level 1PCH WDT Timer Registers (IO mapped, base at TCOBASE + 0x54)
(counter - 1) programmed into bits 9-0_ModuleEntryPoint -> sub_3AC (protocols, tables, PCD) -> sub_578 (register callbacks)(Wdt) Entry Point to WdtDxe -- driver startup(Wdt) WDT event registration; Status = %r -- event registration result(Wdt) RunWdtBeforeOsBoot -- timer callback entry(Wdt) Handoff Hob missing! -- HOB not found during timer callback(Wdt) ReloadAndStartTimer(%d) -- timer being programmed(Wdt) Wdt disabled in Debug BIOS -- debug build skips enable(Wdt) DisableTimer -- timer disable(Wdt) CheckTimerStatus -- status check(Wdt) Readback = (%x) -- register readback(Wdt) Status = FAILURE -- timeout detected(Wdt) AllowKnownReset -- known reset allowed(Wdt) IsWdtRequired / - yes / - no -- requirement check(Wdt) IsWdtEnabled -- enable state checkSource path: e:\hs\PurleySktPkg\SouthClusterLbg\Wdt\Dxe\WdtDxe.c
Build path: e:\hs\Build\HR6N0XMLK\DEBUG_VS2015\X64\PurleySktPkg\SouthClusterLbg\Wdt\Dxe\WdtDxe\DEBUG\