zoukankan      html  css  js  c++  java
  • 深入分析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 )

  • 相关阅读:
    mybatis(1.2)
    Could not find resource mybatis.xml 找不到mybatis主配置文件的三种解决方式
    mybatis(1)
    linux笔记(一)
    javaScript(笔记1)
    过滤器 防止用户恶意登陆
    用户注册调优 及Connection对象
    请求转发的实现及其优缺点
    重定向的实现及其优缺点
    http状态码
  • 原文地址:https://www.cnblogs.com/dragen/p/3131957.html
Copyright © 2011-2022 走看看