> If I am not mistaken (1:55 AM here), either 1) you do not clear the RX
> related bits of IntrStatus in r8169_interrupt() but you clear it in
> rtl8169_poll() and you add local_irq_{en/dis}able() to rtl8169_poll()
> (ala 8139cp.c) or 2) you modify r8169_interrupt() so that it can signal
> to rtl8169_poll() that it cleared itself the Rx bits of IntrStatus
whereas
> rtl8169_poll() was running (ala epic100-netdev).
>
>If you hesitate, go for 1). 2) works but I have not benchmarketed it yet
:o)
Actually, I implemented it in a different way (though similar to #1). I
have the Rx and TX bits not being cleared from the Interrupt status
register while polling (which doesn't matter because they aren't in the
interrupt mask). After the poll completes, the mask is reset to include
the Tx and Rx bit. If any new packets that came in while it was doing the
poll work, the interrupt will pop when the mask is reset (and the new work
will get scheduled). When the interrupt handler gets called now, it will
clear the Rx and Tx interrupt bits.
I'm sure the code explains it better than the words above. :-)
>
>If you have doubts regarding your Tx part, feel free to send any code.
The Tx code has been integrated with the latest version of my NAPI patch.
It is actually working very well. Take a peek and let me know what you
think.
BTW, I did a little code clean-up in these changes. If you want me to
split it out into a separate patch, just let me know.
Thanks,
Jon
r8169.diff
Description: Binary data
Kconfig.diff
Description: Binary data
|