[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <alpine.DEB.2.11.1410292201530.5308@nanos>
Date: Wed, 29 Oct 2014 22:03:20 +0100 (CET)
From: Thomas Gleixner <tglx@...utronix.de>
To: Peter Zijlstra <peterz@...radead.org>
cc: Sabrina Dubroca <sd@...asysnail.net>, netdev@...r.kernel.org,
linux-kernel@...r.kernel.org, jeffrey.t.kirsher@...el.com
Subject: Re: e1000_netpoll(): disable_irq() triggers might_sleep() on
linux-next
On Wed, 29 Oct 2014, Peter Zijlstra wrote:
> On Wed, Oct 29, 2014 at 09:23:42PM +0100, Thomas Gleixner wrote:
> > But at least it allows to mitigate the impact by making it conditional
> > at a central point.
> >
> > static inline void netpoll_lock(struct net_device *nd)
> > {
> > if (netpoll_active(nd))
> > spin_lock(&nd->netpoll_lock);
> > }
>
> branch fail vs lock might be a toss on most machines, but if we're
> hitting cold cachelines we loose big.
Well, if the net_device is not cache hot on irq entry you have lost
already. The extra branch/lock is not going to add much to that.
Thanks,
tglx
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists