반응형





언제 부터 변경된 건지는 확실치 않지만 현재 쓰는 리눅스 버전에서는 SA_INTERRUPT 대신에  IRQF_DISABLED를 사용하는 거로 바뀐거 같다..


http://lwn.net/Articles/229673/ 에 따르면 대응관계는 다음과 같다..

+#define SA_INTERRUPT		deprecated_irq_flag(IRQF_DISABLED)
+#define SA_SAMPLE_RANDOM	deprecated_irq_flag(IRQF_SAMPLE_RANDOM)
+#define SA_SHIRQ		deprecated_irq_flag(IRQF_SHARED)
+#define SA_PROBEIRQ		deprecated_irq_flag(IRQF_PROBE_SHARED)
+#define SA_PERCPU		deprecated_irq_flag(IRQF_PERCPU)
+
+#define SA_TRIGGER_LOW		deprecated_irq_flag(IRQF_TRIGGER_LOW)
+#define SA_TRIGGER_HIGH		deprecated_irq_flag(IRQF_TRIGGER_HIGH)
+#define SA_TRIGGER_FALLING	deprecated_irq_flag(IRQF_TRIGGER_FALLING)
+#define SA_TRIGGER_RISING	deprecated_irq_flag(IRQF_TRIGGER_RISING)
+#define SA_TRIGGER_MASK		deprecated_irq_flag(IRQF_TRIGGER_MASK)


각각의 상수에 대한 정의는 

http://lxr.free-electrons.com/source/include/linux/interrupt.h#L128에 나와 있음..

 38 /*
 39  * These flags used only by the kernel as part of the
 40  * irq handling routines.
 41  *
 42  * IRQF_DISABLED - keep irqs disabled when calling the action handler.
 43  *                 DEPRECATED. This flag is a NOOP and scheduled to be removed
 44  * IRQF_SHARED - allow sharing the irq among several devices
 45  * IRQF_PROBE_SHARED - set by callers when they expect sharing mismatches to occur
 46  * IRQF_TIMER - Flag to mark this interrupt as timer interrupt
 47  * IRQF_PERCPU - Interrupt is per cpu
 48  * IRQF_NOBALANCING - Flag to exclude this interrupt from irq balancing
 49  * IRQF_IRQPOLL - Interrupt is used for polling (only the interrupt that is
 50  *                registered first in an shared interrupt is considered for
 51  *                performance reasons)
 52  * IRQF_ONESHOT - Interrupt is not reenabled after the hardirq handler finished.
 53  *                Used by threaded interrupts which need to keep the
 54  *                irq line disabled until the threaded handler has been run.
 55  * IRQF_NO_SUSPEND - Do not disable this IRQ during suspend
 56  * IRQF_FORCE_RESUME - Force enable it on resume even if IRQF_NO_SUSPEND is set
 57  * IRQF_NO_THREAD - Interrupt cannot be threaded
 58  * IRQF_EARLY_RESUME - Resume IRQ early during syscore instead of at device
 59  *                resume time.
 60  */
 61 #define IRQF_DISABLED           0x00000020
 62 #define IRQF_SHARED             0x00000080
 63 #define IRQF_PROBE_SHARED       0x00000100
 64 #define __IRQF_TIMER            0x00000200
 65 #define IRQF_PERCPU             0x00000400
 66 #define IRQF_NOBALANCING        0x00000800
 67 #define IRQF_IRQPOLL            0x00001000
 68 #define IRQF_ONESHOT            0x00002000
 69 #define IRQF_NO_SUSPEND         0x00004000
 70 #define IRQF_FORCE_RESUME       0x00008000
 71 #define IRQF_NO_THREAD          0x00010000
 72 #define IRQF_EARLY_RESUME       0x00020000


문제 발생시 지나치지 마시고 댓글 남겨주시면 가능한 빨리 답장드립니다.


제가 쓴 책도 한번 검토해보세요 ^^

+ Recent posts