* arch/mips/au1000/common/irq.c
@ 2003-03-13 18:47 Jeff Baitis
2003-03-13 18:50 ` arch/mips/au1000/common/irq.c Dan Malek
2003-03-13 18:59 ` arch/mips/au1000/common/irq.c Pete Popov
0 siblings, 2 replies; 5+ messages in thread
From: Jeff Baitis @ 2003-03-13 18:47 UTC (permalink / raw)
To: Pete Popov; +Cc: linux-mips
Pete:
I've got a question concerning irq.c. In intc0_req0_irqdispatch() (linux_2_4
branch) on lines 545 thru 552, the code reads:
for (i=0; i<32; i++) {
if ((intc0_req0 & (1<<i))) {
intc0_req0 &= ~(1<<i);
do_IRQ(irq, regs);
break;
}
irq++;
}
My question is: why do we increment i and irq independently?
Why doesn't the code read:
for (i=0; i<32; i++) {
if ((intc0_req0 & (1<<i))) {
intc0_req0 &= ~(1<<i);
do_IRQ(i, regs);
break;
}
}
Thanks for your help!
-Jeff
--
Jeffrey Baitis - Associate Software Engineer
Evolution Robotics, Inc.
130 West Union Street
Pasadena CA 91103
tel: 626.535.2776 | fax: 626.535.2777 | baitisj@evolution.com
^ permalink raw reply [flat|nested] 5+ messages in thread* Re: arch/mips/au1000/common/irq.c 2003-03-13 18:47 arch/mips/au1000/common/irq.c Jeff Baitis @ 2003-03-13 18:50 ` Dan Malek 2003-03-13 22:13 ` arch/mips/au1000/common/irq.c Jeff Baitis 2003-03-13 18:59 ` arch/mips/au1000/common/irq.c Pete Popov 1 sibling, 1 reply; 5+ messages in thread From: Dan Malek @ 2003-03-13 18:50 UTC (permalink / raw) To: baitisj; +Cc: Pete Popov, linux-mips Jeff Baitis wrote: > Pete: > > I've got a question concerning irq.c. In intc0_req0_irqdispatch() (linux_2_4 > branch) on lines 545 thru 552, the code reads: I'm hacking these functions to use 'clz' and for other updates, so the code will be changing soon, anyway :-) Comment on the next version :-) Thanks. -- Dan ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: arch/mips/au1000/common/irq.c 2003-03-13 18:50 ` arch/mips/au1000/common/irq.c Dan Malek @ 2003-03-13 22:13 ` Jeff Baitis 2003-03-13 22:25 ` arch/mips/au1000/common/irq.c Jeff Baitis 0 siblings, 1 reply; 5+ messages in thread From: Jeff Baitis @ 2003-03-13 22:13 UTC (permalink / raw) To: Dan Malek; +Cc: Pete Popov, linux-mips Dan: I just verified that I get an IRQ storm when I plug a 3.3-volt based SMC EPIC/100 network card into the PCI slot of the Au1500. Before I bring the interface up, I notice that the driver tries to allocate IRQ 1 (INTA). This is the same IRQ that the ill-fated CardBus bridge attempts to use. ;) As soon as I bring the SMC interface up using ifconfig (and have the interface plugged into an active Ethernet network), the IRQ storm ensues. I'll try Hartvig's patch, look over the irq.c levels, and see how everything fares. Thanks all! Regards, Jeff On Thu, Mar 13, 2003 at 01:50:46PM -0500, Dan Malek wrote: > Jeff Baitis wrote: > > > Pete: > > > > I've got a question concerning irq.c. In intc0_req0_irqdispatch() (linux_2_4 > > branch) on lines 545 thru 552, the code reads: > > I'm hacking these functions to use 'clz' and for other updates, so > the code will be changing soon, anyway :-) Comment on the next version :-) > > Thanks. > > > -- Dan > > > -- Jeffrey Baitis - Associate Software Engineer Evolution Robotics, Inc. 130 West Union Street Pasadena CA 91103 tel: 626.535.2776 | fax: 626.535.2777 | baitisj@evolution.com ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: arch/mips/au1000/common/irq.c 2003-03-13 22:13 ` arch/mips/au1000/common/irq.c Jeff Baitis @ 2003-03-13 22:25 ` Jeff Baitis 0 siblings, 0 replies; 5+ messages in thread From: Jeff Baitis @ 2003-03-13 22:25 UTC (permalink / raw) To: Dan Malek; +Cc: Pete Popov, linux-mips, Hartvig Ekner Hartvig's patch has solved my IRQ storm problems. Thank you all very much for your attention! Regards, Jeff On Thu, Mar 13, 2003 at 02:13:31PM -0800, Jeff Baitis wrote: > Dan: > > I just verified that I get an IRQ storm when I plug a 3.3-volt based SMC > EPIC/100 network card into the PCI slot of the Au1500. Before I bring the > interface up, I notice that the driver tries to allocate IRQ 1 (INTA). This is > the same IRQ that the ill-fated CardBus bridge attempts to use. ;) > > As soon as I bring the SMC interface up using ifconfig (and have the interface > plugged into an active Ethernet network), the IRQ storm ensues. > > I'll try Hartvig's patch, look over the irq.c levels, and see how everything > fares. > > Thanks all! > > Regards, > > Jeff > > > On Thu, Mar 13, 2003 at 01:50:46PM -0500, Dan Malek wrote: > > Jeff Baitis wrote: > > > > > Pete: > > > > > > I've got a question concerning irq.c. In intc0_req0_irqdispatch() (linux_2_4 > > > branch) on lines 545 thru 552, the code reads: > > > > I'm hacking these functions to use 'clz' and for other updates, so > > the code will be changing soon, anyway :-) Comment on the next version :-) > > > > Thanks. > > > > > > -- Dan > > > > > > > > -- > Jeffrey Baitis - Associate Software Engineer > > Evolution Robotics, Inc. > 130 West Union Street > Pasadena CA 91103 > > tel: 626.535.2776 | fax: 626.535.2777 | baitisj@evolution.com > > -- Jeffrey Baitis - Associate Software Engineer Evolution Robotics, Inc. 130 West Union Street Pasadena CA 91103 tel: 626.535.2776 | fax: 626.535.2777 | baitisj@evolution.com ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: arch/mips/au1000/common/irq.c 2003-03-13 18:47 arch/mips/au1000/common/irq.c Jeff Baitis 2003-03-13 18:50 ` arch/mips/au1000/common/irq.c Dan Malek @ 2003-03-13 18:59 ` Pete Popov 1 sibling, 0 replies; 5+ messages in thread From: Pete Popov @ 2003-03-13 18:59 UTC (permalink / raw) To: baitisj; +Cc: linux-mips On Thu, 2003-03-13 at 10:47, Jeff Baitis wrote: > Pete: > > I've got a question concerning irq.c. In intc0_req0_irqdispatch() (linux_2_4 > branch) on lines 545 thru 552, the code reads: > > for (i=0; i<32; i++) { > if ((intc0_req0 & (1<<i))) { > intc0_req0 &= ~(1<<i); > do_IRQ(irq, regs); > break; > } > irq++; > } > > My question is: why do we increment i and irq independently? > Why doesn't the code read: > > for (i=0; i<32; i++) { > if ((intc0_req0 & (1<<i))) { > intc0_req0 &= ~(1<<i); > do_IRQ(i, regs); > break; > } > } > > Thanks for your help! No reason. It was probably more clear to me when writing the code and later I didn't look for such improvements. Like Dan said though, he's updating/optimizing that part of the code anyway ... Pete ^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2003-03-13 22:25 UTC | newest] Thread overview: 5+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2003-03-13 18:47 arch/mips/au1000/common/irq.c Jeff Baitis 2003-03-13 18:50 ` arch/mips/au1000/common/irq.c Dan Malek 2003-03-13 22:13 ` arch/mips/au1000/common/irq.c Jeff Baitis 2003-03-13 22:25 ` arch/mips/au1000/common/irq.c Jeff Baitis 2003-03-13 18:59 ` arch/mips/au1000/common/irq.c Pete Popov
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox