Ignore:
Timestamp:
Nov 3, 2014, 11:03:55 AM (10 years ago)
Author:
alain
Message:

Introducing dynamic allocation of peripheral channels (NIC, TTY, CMA, TIM)
Intoducing a kernel function for all system calls: No more direct call
to the peripheral drivers.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • soft/giet_vm/giet_kernel/irq_handler.h

    r322 r440  
    3636};
    3737
    38 ///////////////////////////////////////////////////////////////////////////////
    39 // Prototypes of the Interrupt Service Routines (ISRs) supported by the GIET.
    40 ///////////////////////////////////////////////////////////////////////////////
     38///////////////////////////////////////////////////////////////////////////////////
     39//    irq_handler functions
     40///////////////////////////////////////////////////////////////////////////////////
    4141
     42///////////////////////////////////////////////////////////////////////////////////
     43// This function access the ICU or XICU component (Interrupt Controler Unit)
     44// to get the interrupt vector entry. There is one ICU or XICU component per
     45// cluster, and this component can support up to NB_PROCS_MAX output IRQs.
     46// It returns the highest priority active interrupt index (smaller
     47// indexes have the highest priority).
     48// Any value larger than 31 means "no active interrupt", and no ISR is executed.
     49//
     50// There is three interrupt vectors per processor (stored in the processor's
     51// scheduler) for the three HWI, PTI, and WTI interrupts types.
     52// Each interrupt vector entry contains three bits fields:
     53// - isr_id     bits[15:0]  : defines the type of ISR to be executed.
     54// - channel_id bits[30:16] : defines the channel for multi-channels peripherals.
     55// - valid      bit 31      : valid interrupt vector entry
     56// If the peripheral is replicated in clusters, the channel_id is
     57// a global index : channel_id = cluster_id * NB_CHANNELS_MAX + loc_id   
     58///////////////////////////////////////////////////////////////////////////////////
    4259extern void _irq_demux();
    4360
     61///////////////////////////////////////////////////////////////////////////////////
     62// This default ISR is called  when the interrupt handler is called,
     63// and there is no active IRQ. It simply displays a warning message on TTY[0].
     64///////////////////////////////////////////////////////////////////////////////////
    4465extern void _isr_default();
    4566
     67///////////////////////////////////////////////////////////////////////////////////
     68// This ISR can only be executed after a WTI (IPI) to force a context switch
     69// on a remote processor. The context switch is only executed if the current task
     70// is the IDLE_TASK, or if the value written in the mailbox is non zero.
     71///////////////////////////////////////////////////////////////////////////////////
     72extern void _isr_wakup( unsigned int irq_type,
     73                        unsigned int irq_id,
     74                        unsigned int channel );
     75
     76/////////////////////////////////////////////////////////////////////////////////////
     77// This ISR is in charge of context switch, and handles the IRQs generated by
     78// the "system" timers. It can be PTI in case of XCU, or it can be HWI generated
     79// by an external timer in case of ICU.
     80// The ISR acknowledges the IRQ, and calls the _ctx_switch() function.
     81/////////////////////////////////////////////////////////////////////////////////////
    4682extern void _isr_tick( unsigned int irq_type,
    4783                       unsigned int irq_id,
    4884                       unsigned int channel );
    49 
    50 extern void _isr_wakup( unsigned int irq_type,
    51                         unsigned int irq_id,
    52                         unsigned int channel );
    5385
    5486#endif
Note: See TracChangeset for help on using the changeset viewer.