[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <dcd94db0-37b0-5a31-6a36-facdf7f58ed3@lechnology.com>
Date: Tue, 23 Jan 2018 21:01:54 -0600
From: David Lechner <david@...hnology.com>
To: Bartosz Golaszewski <brgl@...ev.pl>, Sekhar Nori <nsekhar@...com>,
Kevin Hilman <khilman@...nel.org>,
Wolfram Sang <wsa@...-dreams.de>
Cc: linux-arm-kernel@...ts.infradead.org, linux-i2c@...r.kernel.org,
linux-kernel@...r.kernel.org,
Bartosz Golaszewski <bgolaszewski@...libre.com>
Subject: Re: [PATCH] i2c: davinci: fix the cpufreq transition
On 01/22/2018 08:42 AM, Bartosz Golaszewski wrote:
> From: Bartosz Golaszewski <bgolaszewski@...libre.com>
>
> i2c_davinci_cpufreq_transition() is implemented in a way that will
> block if it ever gets called while no transfer is in progress.
>
> Not only that, but reinit_completion() is never called for xfr_complete.
>
> Use the fact that cpufreq uses an srcu_notifier (running in process
> context) for transitions and that the bus_lock is taken during the call
> to master_xfer() and simplify the code by removing the transfer
> completion entirely and protecting i2c_davinci_cpufreq_transition()
> with i2c_lock/unlock_adapter().
>
> Reported-by: David Lechner <david@...hnology.com>
> Signed-off-by: Bartosz Golaszewski <bgolaszewski@...libre.com>
> ---
Tested that it fixes the lockup when there is no active transfer.
Tested-by: David Lechner <david@...hnology.com>
Powered by blists - more mailing lists