123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126 |
- /*++
- Copyright (c) 2014 Minoca Corp. All Rights Reserved
- Module Name:
- archdbg.c
- Abstract:
- This module implements architecture-specific debug device support for the
- hardware library.
- Author:
- Evan Green 8-Apr-2014
- Environment:
- Kernel
- --*/
- //
- // ------------------------------------------------------------------- Includes
- //
- #include <minoca/kernel/kernel.h>
- #include "../hlp.h"
- //
- // ---------------------------------------------------------------- Definitions
- //
- //
- // ------------------------------------------------------ Data Type Definitions
- //
- //
- // ----------------------------------------------- Internal Function Prototypes
- //
- //
- // Builtin hardware module function prototypes.
- //
- VOID
- HlpPl11SerialModuleEntry (
- VOID
- );
- VOID
- HlpOmapSerialModuleEntry (
- VOID
- );
- VOID
- HlpNs16550SerialModuleEntry (
- VOID
- );
- //
- // -------------------------------------------------------------------- Globals
- //
- //
- // Built-in hardware modules.
- //
- PHARDWARE_MODULE_ENTRY HlBuiltinDebugDevices[] = {
- HlpPl11SerialModuleEntry,
- HlpOmapSerialModuleEntry,
- HlpNs16550SerialModuleEntry,
- };
- //
- // ------------------------------------------------------------------ Functions
- //
- KSTATUS
- HlpArchInitializeDebugDevices (
- VOID
- )
- /*++
- Routine Description:
- This routine performs architecture-specific initialization for the serial
- subsystem.
- Arguments:
- None.
- Return Value:
- Status code.
- --*/
- {
- ULONG ModuleCount;
- PHARDWARE_MODULE_ENTRY ModuleEntry;
- ULONG ModuleIndex;
- //
- // Loop through and initialize every built in hardware module.
- //
- ModuleCount = sizeof(HlBuiltinDebugDevices) /
- sizeof(HlBuiltinDebugDevices[0]);
- for (ModuleIndex = 0; ModuleIndex < ModuleCount; ModuleIndex += 1) {
- ModuleEntry = HlBuiltinDebugDevices[ModuleIndex];
- ModuleEntry();
- }
- return STATUS_SUCCESS;
- }
- //
- // --------------------------------------------------------- Internal Functions
- //
|