dresd
设备树中的interrupts属性解析
dciminterrupts属性会有两种不同的参数:
1. 带两个参数的情形
system什么意思
⽰例:
忘记英文
interrupt-parent = <&gpio2>;
autopilot interrupts = <5 1>;
表⽰中断控制器是GPIO2,使⽤GPIO2的第5号中断,这⾥的第5号中断指的是5号引脚,1是指中断触发的⽅式为上升沿触发,详见内核代码中的头⽂件include/dt-bindings/interrupt-controller/irq.h
degree2. 带三个参数的情形
healshow ⽰例:
interrupts = <GIC_SPI 66 1>;
圣诞英文贺卡
2.1 先了解⼀下中断的类型
IPI:inter-procesr interrupt 中断号0~15
PPI:per processor interrupts 中断号16~31
SPI:shared processor interrupts 中断号 32 ~32+224
kenzo怎么读
SGI:software generated interrupts (SGI).corner是什么意思
所以上述⽰例表⽰中断类型为共享处理器中断(SPI),中断号为SPI中断类型中的第66号中断号,计算出来的实际中断号即为32+66=98号中断,1表⽰上升沿触发中断