[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <alpine.DEB.2.20.1609201725550.6905@nanos>
Date: Tue, 20 Sep 2016 17:33:29 +0200 (CEST)
From: Thomas Gleixner <tglx@...utronix.de>
To: Peter Rosin <peda@...ntia.se>
cc: Peter Zijlstra <peterz@...radead.org>,
Bartosz Golaszewski <bgolaszewski@...libre.com>,
Wolfram Sang <wsa@...-dreams.de>,
Linus Walleij <linus.walleij@...aro.org>,
Alexandre Courbot <gnurou@...il.com>,
Andy Shevchenko <andriy.shevchenko@...ux.intel.com>,
Vignesh R <vigneshr@...com>, Yong Li <yong.b.li@...el.com>,
Geert Uytterhoeven <geert+renesas@...der.be>,
Ingo Molnar <mingo@...hat.com>,
linux-i2c <linux-i2c@...r.kernel.org>,
linux-gpio <linux-gpio@...r.kernel.org>,
LKML <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH v2 0/4] gpio: fix an incorrect lockdep warning
On Tue, 20 Sep 2016, Peter Rosin wrote:
> On 2016-09-19 11:03, Peter Zijlstra wrote:
> >
> > Use the -RT kernel and all locks will end up as rt_mutex. Avoiding
> > inversion on one specific lock, while there are then a gazillion other
> > than can equally create inversion doesn't make sense to me.
That's true, but the locking of the i2c stuff is pretty much self contained
and the results of using an rtmutex speak for themself.
One of the issues is that i2c needs to use threaded interrupt handlers and
blocking out the handler thread with a preempted user space task is hurting
performance badly.
I don't think that using a rtmutex there is wrong. It cures at least a very
clear priority inversion issue versus the threaded interrupt handler.
Forcing all i2c users off to RT is not really an option. RT has other
drawbacks vs. throughput which you don't want to impose on everything which
happens to use i2c.
> 2a will cause a lockdep splat if i2c0:mux_lock is in the same
> lockdep class & subclass as i2c1:mux_lock. So, lockdep needs
> separate lockdep classes depending on the i2c root adapter
> (subclasses are needed to handle deeper trees, so they are off
> limits). Great fun. How do I go about creating a new lockdep
> class for every i2c root adapter instance?
lockdep_set_class() .....
Thanks,
tglx
Powered by blists - more mailing lists