Lines Matching +full:interrupt +full:- +full:src

9  * 1999-2001 (c) Dan Malek <dan@embeddedalley.com>
17 /* The CPM2 internal interrupt controller. It is usually
18 * the only interrupt controller.
19 * There are two 32-bit registers (high/low) for up to 64
22 * Now, the fun starts.....Interrupt Numbers DO NOT MAP
24 * That is, interrupt 4 does not map to bit position 4.
51 static unsigned long ppc_cached_irq_mask[2]; /* 2 32-bit registers */
86 out_be32(&cpm2_intctl->ic_simrh + word, ppc_cached_irq_mask[word]); in cpm2_mask_irq()
98 out_be32(&cpm2_intctl->ic_simrh + word, ppc_cached_irq_mask[word]); in cpm2_unmask_irq()
109 out_be32(&cpm2_intctl->ic_sipnrh + word, 1 << bit); in cpm2_ack()
121 out_be32(&cpm2_intctl->ic_simrh + word, ppc_cached_irq_mask[word]); in cpm2_end_irq()
132 unsigned int src = irqd_to_hwirq(d); in cpm2_set_irq_type() local
139 if (src >= CPM2_IRQ_PORTC15 && src <= CPM2_IRQ_PORTC0) { in cpm2_set_irq_type()
163 if (src >= CPM2_IRQ_EXT1 && src <= CPM2_IRQ_EXT7) in cpm2_set_irq_type()
164 edibit = (14 - (src - CPM2_IRQ_EXT1)); in cpm2_set_irq_type()
166 if (src >= CPM2_IRQ_PORTC15 && src <= CPM2_IRQ_PORTC0) in cpm2_set_irq_type()
167 edibit = (31 - (CPM2_IRQ_PORTC0 - src)); in cpm2_set_irq_type()
170 IRQ_SET_MASK_OK_NOCOPY : -EINVAL; in cpm2_set_irq_type()
172 vold = in_be32(&cpm2_intctl->ic_siexr); in cpm2_set_irq_type()
180 out_be32(&cpm2_intctl->ic_siexr, vnew); in cpm2_set_irq_type()
185 return -EINVAL; in cpm2_set_irq_type()
205 bits = in_be32(&cpm2_intctl->ic_sivec); in cpm2_get_irq()
209 return(-1); in cpm2_get_irq()
232 cpm2_intctl = &cpm2_immr->im_intctl; in cpm2_pic_init()
240 out_be32(&cpm2_intctl->ic_simrh, 0x00000000); in cpm2_pic_init()
241 out_be32(&cpm2_intctl->ic_simrl, 0x00000000); in cpm2_pic_init()
246 out_be32(&cpm2_intctl->ic_sipnrh, 0xffffffff); in cpm2_pic_init()
247 out_be32(&cpm2_intctl->ic_sipnrl, 0xffffffff); in cpm2_pic_init()
251 i = in_be32(&cpm2_intctl->ic_sivec); in cpm2_pic_init()
254 /* Initialize the default interrupt mapping priorities, in cpm2_pic_init()
257 out_be16(&cpm2_intctl->ic_sicr, 0); in cpm2_pic_init()
258 out_be32(&cpm2_intctl->ic_scprrh, 0x05309770); in cpm2_pic_init()
259 out_be32(&cpm2_intctl->ic_scprrl, 0x05309770); in cpm2_pic_init()