• 深入分析SCU GIC驱动 1 ZEDBOARD,ZYNQ7000


    Scu gic in depth – 1

    Scu unit is a powerful unit to deal with the coherence of L2 and memory ,and contains a general interrupt controller pl390 :

    It deal with the following several kinds of interrupt:

    • Private Peripheral interrupt of core 0 and 1: 5x2=10
    • Software generated interrupt: 16x2=32
    • I/O Peripherals interrupt: 44
    • PL logic interrupt: 16

    In total , it deal with up to 92 interupts input . however

    /*

    * The maximum number of interrupts supported by the hardware.

    */

    #define XSCUGIC_MAX_NUM_INTR_INPUTS 95

    So what is the left 3 interupts?

     

    NOTICE:

    SCU GIC will depatch 16 kinds of interrupt to programmable logic unit to trigger hardware process and this is useful to communicate between cpu and FPGA .

     

    Step 1: init the scu_gic module:

        Int XScuGic_CfgInitialize(XScuGic* InstancePtr,XGcuGic_Config* ConfigPtr,u32 EffectiveAddr)

    The function will init some inner data struct and disable all interrupt source.

    EffectiveAddr is relative to Physial Address, equals virtual address.

     

    Step 2: connect interrupt routes:

        Int Connect( IntancePtr , Int_ID , InterruptHandler , void* CallBackRef )

    Connect the interrupt route according to the specified interrupt ID number. The parameter CallBackRef contains some arguments.

    Step 3 : Enable the interrupt :

        Void Enable ( InstancePtr , Int_ID )

    Step 4: get the interrupt information:

        Void GetPriorityTriggerType(InstancePtr, Int_ID, Priority , Trigger )

  • 相关阅读:
    网页挂马实验
    基于内核网络过滤实验
    基与内核的键盘记录实验
    网络蠕虫病毒代码分析
    脚本病毒编写实验
    病毒查找与清除实验
    木马分析(植入分析)实验
    木马分析(控制分析)实验
    木马分析(隐藏分析)实验
    移动存储型病毒分析实验
  • 原文地址:https://www.cnblogs.com/dragen/p/3131957.html
Copyright © 2020-2023  润新知