lkml.org 
[lkml]   [2007]   [Oct]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 2/5] forcedeth: interrupt handling cleanup
Yinghai Lu wrote:
> On 10/7/07, Jeff Garzik <jeff@garzik.org> wrote:
>> Yinghai Lu wrote:
>>> On 10/6/07, Jeff Garzik <jeff@garzik.org> wrote:
>>>> commit a606d2a111cdf948da5d69eb1de5526c5c2dafef
>>>> Author: Jeff Garzik <jeff@garzik.org>
>>>> Date: Fri Oct 5 22:56:05 2007 -0400
>>>>
>>>> [netdrvr] forcedeth: interrupt handling cleanup
>>>>
>>>> * nv_nic_irq_optimized() and nv_nic_irq_other() were complete duplicates
>>>> of nv_nic_irq(), with the exception of one function call. Consolidate
>>>> all three into a single interrupt handler, deleting a lot of redundant
>>>> code.
>>>>
>>>> * greatly simplify irq handler locking.
>>>>
>>>> Prior to this change, the irq handler(s) would acquire and release
>>>> np->lock for each action (RX, TX, other events).
>>>>
>>>> For the common case -- RX or TX work -- the lock is always acquired,
>>>> making all successive acquire/release combinations largely redundant.
>>>>
>>>> Acquire the lock at the beginning of the irq handler, and release it at
>>>> the end of the irq handler. This is simple, easy, and obvious.
>>>>
>>>> * remove irq handler work loop.
>>>>
>>>> All interesting events emanating from the irq handler either have
>>>> their own work loops, or they poke a timer into action.
>>>>
>>>> Therefore, delete the pointless master interrupt handler work loop.
>>>>
>>>> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
>>>>
>> Do you have ideas/suggestions for a different method?
>
> in the e1000 driver, it has seperate handler for msi and ioapic.
>
> but in forcedeth, the nv_nic_irq_optimized keep check msi_flags...,
> with num of msi interrupt number, that could cause cpu loading get a
> little bit high..., even the network performance is ok.

With all the activity in the interrupt handler, a few in-cache branches
are definitely going to be lost in the noise.

Separating the interrupt handlers between MSI and non-MSI tends to be of
more benefit when the separation is accompanied by more efficient
locking in the MSI interrupt handler, or a different mode of interrupt
clear, or some other attribute.

Though CPU usage would be a good thing to measure, with these patches.

Jeff




-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2007-10-07 22:11    [W:0.058 / U:0.748 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site