Bogus interrupts: test fix
I've updated the 2.2-pre4 test kernel on my web page, it contains a test fix for the bogus interrupt problem. Please try it and give me feedback. Also, do not worry about the "lost interrupts" counter I added to /proc/interrupts, they are not really "lost" but I would be interested in knowing how much of them you get with ordinary use of the system.
The "fix" looks like this:
void __pmac pmac_mask_and_ack_irq(int irq_nr)
{
unsigned long bit = 1UL << (irq_nr & 0x1f);
int i = irq_nr >> 5;
if ((unsigned)irq_nr >= max_irqs)
return;
/*spin_lock(&irq_controller_lock);*/
clear_bit(irq_nr, cached_irq_mask);
if (test_and_clear_bit(irq_nr, lost_interrupts))
atomic_dec(&n_lost_interrupts);
out_le32(&pmac_irq_hw[i]->ack, bit);
out_le32(&pmac_irq_hw[i]->enable, cached_irq_mask[i]);
out_le32(&pmac_irq_hw[i]->ack, bit);
do {
/* make sure ack gets to controller before we enable interrupts */
sync();
} while(in_le32(&pmac_irq_hw[i]->flag) & bit);
/*spin_unlock(&irq_controller_lock);*/
/*if ( irq_controller_lock.lock )
panic("irq controller lock still held in mask and ack\n");*/
}Note that the sync() may now be useless. I don't have anymore bogus interrupts on the PowerBook for now but I usually have very few of them anyway. I'm more interested by results from people with a real problem (io slowdown due to lots of them).
I'll post this kernel on an ftp site later today too.
Signature · 11 lines
E-Mail: <mailto:[email protected]> BenH. Web : <http://calvaweb.calvacom.fr/bh40/> [[ This message was sent via the linuxppc-dev mailing list. Replies are ]] [[ not forced back to the list, so be sure to Cc linuxppc-dev if your ]] [[ reply is of general interest. To unsubscribe from linuxppc-dev, send ]] [[ the message 'unsubscribe' to [email protected] ]]
Quoted 3 lines · Benjamin Herrenschmidt
I've updated the 2.2-pre4 test kernel on my web page, it contains a test fix for the bogus interrupt problem. Please try it and give me feedback.
Really good! The improvement of ide performance is impressive. The slowdown effect has gone during ide _reads_ [= almost "normal" response times compared to Intel/Linux systems], but is still present during ide _writes_ (I tested it with a program which writes or reads 200 MB with simple read/write calls, so I have enough time for a login on a 2nd console). BTW, the read transfer speed given by hdparm (PB G3/300, IBM DYLA 28100) is 7.08 MB/s.
The bogus interrupts are gone _completely_; still 0 after ~1 hour with a lot of io. LST interrupts are == 1 (one) after the same time.
Yours, and THANKS for your work,
Albrecht.
Signature · 16 lines
+-----------------------------------------------------------------------------+ | Dr.-Ing. Albrecht Dre\3 ---- | | Max-Planck-Institut f"ur Radioastronomie |\ / /o o\ | | Technische Abt. Optische Interferometrie | \ / | / | | | Auf dem H"ugel 69 | \ | \ ---/ | | D-53121 Bonn (Germany) ------------+------+------------------- | | | / | | | Phone (+49) 228 525 319 | / / | | Fax (+49) 228 525 411 |/ / | | Mail [email protected] | +-------------- electrical engineers do it with less resistance --------------+ [[ This message was sent via the linuxppc-dev mailing list. Replies are ]] [[ not forced back to the list, so be sure to Cc linuxppc-dev if your ]] [[ reply is of general interest. To unsubscribe from linuxppc-dev, send ]] [[ the message 'unsubscribe' to [email protected] ]]