Unit ARMGIC

From Ultibo.org
Revision as of 04:38, 19 June 2021 by Ultibo (Talk | contribs)

Jump to: navigation, search

Return to Unit Reference


Description


ARM Generic Interrupt Controller Driver

Constants


To be documented

Type definitions


To be documented

Public variables


None defined

Function declarations



ARM GIC functions

function ARMGICCreate(DistAddress,CPUAddress:PtrUInt):PGICDevice;
Description: To be documented
Note None documented


function ARMGICStart(GIC:PGICDevice):LongWord;
Description: To be documented
Note None documented


function ARMGICGetEntry(GIC:PGICDevice; CPUID,Number,Flags:LongWord; var Entry:TInterruptEntry; Index:LongWord):LongWord;
Description: To be documented
Note The returned Entry is a copy of the registered value. Caller should free Entry if required.

For shared entries the Index parameter indicates which entry in the chain to return (0 equals first etc).


function ARMGICRegisterEntry(GIC:PGICDevice; const Entry:TInterruptEntry):LongWord;
Description: To be documented
Note Entry must be allocated from heap as a pointer so it will be retained while the interrupt remains registered.

Entry must not be freed by the caller.


function ARMGICDeregisterEntry(GIC:PGICDevice; const Entry:TInterruptEntry):LongWord;
Description: To be documented
Note The Entry can be a local temporary copy allocated either from the stack or on the heap, this routine will free the original Entry passed to Register once it is successfully deregistered.

Caller should free Entry if required.


ARM GIC interrupt functions

function ARMGICDispatchIRQ(CPUID:LongWord; Thread:TThreadHandle):TThreadHandle;
Description: To be documented
Note Called by ARMv7/8IRQHandler in PlatformARMv7/8


function ARMGICDispatchFIQ(CPUID:LongWord; Thread:TThreadHandle):TThreadHandle;
Description: To be documented
Note Called by ARMv7/8FIQHandler in PlatformARMv7/8


function ARMGICDispatchInterrupt(CPUID:LongWord; Thread:TThreadHandle):TThreadHandle;
Description: Process any pending IRQ/FIQ requests
Note Called by ARMGICDispatchIRQ/ARMGICDispatchFIQ.

A DataMemoryBarrier is executed before and after calling this function.


ARM GIC helper functions

function ARMGICIsValid(GIC:PGICDevice; Number:LongWord):Boolean;
Description: To be documented
Note None documented


function ARMGICIsLocal(GIC:PGICDevice; Number:LongWord):Boolean;
Description: To be documented
Note None documented


function ARMGICIsSoftware(GIC:PGICDevice; Number:LongWord):Boolean;
Description: To be documented
Note None documented


function ARMGICIsGlobal(GIC:PGICDevice; Number:LongWord):Boolean;
Description: To be documented
Note None documented


function ARMGICGetIRQCount(GIC:PGICDevice):LongWord;
Description: To be documented
Note None documented


function ARMGICGetFIQCount(GIC:PGICDevice):LongWord;
Description: To be documented
Note None documented


function ARMGICGetIRQStart(GIC:PGICDevice):LongWord;
Description: To be documented
Note None documented


function ARMGICGetIRQRouting(GIC:PGICDevice):LongWord;
Description: To be documented
Note None documented


function ARMGICGetFIQRouting(GIC:PGICDevice):LongWord;
Description: To be documented
Note None documented


function ARMGICGetIRQLocalCount(GIC:PGICDevice):LongWord;
Description: To be documented
Note None documented


function ARMGICGetFIQLocalCount(GIC:PGICDevice):LongWord;
Description: To be documented
Note None documented


function ARMGICGetIRQLocalStart(GIC:PGICDevice):LongWord;
Description: To be documented
Note None documented


function ARMGICGetIRQSoftwareCount(GIC:PGICDevice):LongWord;
Description: To be documented
Note None documented


function ARMGICGetFIQSoftwareCount(GIC:PGICDevice):LongWord;
Description: To be documented
Note None documented


function ARMGICGetIRQSoftwateStart(GIC:PGICDevice):LongWord;
Description: To be documented
Note None documented


Return to Unit Reference