Re: [PATCH v3 1/7] clkdev: Hold clocks_mutex while iterating clocks list

2019-04-10 Thread Stephen Boyd
Quoting Russell King - ARM Linux admin (2019-04-09 01:57:17) > On Tue, Apr 09, 2019 at 05:31:48AM +, Vaittinen, Matti wrote: > > On Mon, 2019-04-08 at 23:21 +0100, Russell King - ARM Linux admin > > wrote: > > > On Mon, Apr 08, 2019 at 10:00:02AM -0700, Stephen Boyd wrote: > > > > > > > > > >

Re: [PATCH v3 1/7] clkdev: Hold clocks_mutex while iterating clocks list

2019-04-09 Thread Russell King - ARM Linux admin
On Tue, Apr 09, 2019 at 05:31:48AM +, Vaittinen, Matti wrote: > On Mon, 2019-04-08 at 23:21 +0100, Russell King - ARM Linux admin > wrote: > > On Mon, Apr 08, 2019 at 10:00:02AM -0700, Stephen Boyd wrote: > > > Quoting Matti Vaittinen (2019-04-08 03:49:41) > > > > On Fri, Apr 05, 2019 at 01:37:

Re: [PATCH v3 1/7] clkdev: Hold clocks_mutex while iterating clocks list

2019-04-08 Thread Vaittinen, Matti
On Mon, 2019-04-08 at 23:21 +0100, Russell King - ARM Linux admin wrote: > On Mon, Apr 08, 2019 at 10:00:02AM -0700, Stephen Boyd wrote: > > Quoting Matti Vaittinen (2019-04-08 03:49:41) > > > On Fri, Apr 05, 2019 at 01:37:24PM -0700, Stephen Boyd wrote: > > > > Quoting Vaittinen, Matti (2019-04-04

Re: [PATCH v3 1/7] clkdev: Hold clocks_mutex while iterating clocks list

2019-04-08 Thread Russell King - ARM Linux admin
On Mon, Apr 08, 2019 at 10:00:02AM -0700, Stephen Boyd wrote: > Quoting Matti Vaittinen (2019-04-08 03:49:41) > > On Fri, Apr 05, 2019 at 01:37:24PM -0700, Stephen Boyd wrote: > > > Quoting Vaittinen, Matti (2019-04-04 23:51:43) > > > > On Thu, 2019-04-04 at 14:53 -0700, Stephen Boyd wrote: > > > >

Re: [PATCH v3 1/7] clkdev: Hold clocks_mutex while iterating clocks list

2019-04-08 Thread Stephen Boyd
Quoting Matti Vaittinen (2019-04-08 03:49:41) > On Fri, Apr 05, 2019 at 01:37:24PM -0700, Stephen Boyd wrote: > > Quoting Vaittinen, Matti (2019-04-04 23:51:43) > > > On Thu, 2019-04-04 at 14:53 -0700, Stephen Boyd wrote: > > > > We recently introduced a change to support devm clk lookups. That > >

Re: [PATCH v3 1/7] clkdev: Hold clocks_mutex while iterating clocks list

2019-04-08 Thread Matti Vaittinen
On Fri, Apr 05, 2019 at 01:37:24PM -0700, Stephen Boyd wrote: > Quoting Vaittinen, Matti (2019-04-04 23:51:43) > > On Thu, 2019-04-04 at 14:53 -0700, Stephen Boyd wrote: > > > We recently introduced a change to support devm clk lookups. That > > > change > > > introduced a code-path that used clk_f

Re: [PATCH v3 1/7] clkdev: Hold clocks_mutex while iterating clocks list

2019-04-05 Thread Stephen Boyd
Quoting Vaittinen, Matti (2019-04-04 23:51:43) > On Thu, 2019-04-04 at 14:53 -0700, Stephen Boyd wrote: > > We recently introduced a change to support devm clk lookups. That > > change > > introduced a code-path that used clk_find() without holding the > > 'clocks_mutex'. Unfortunately, clk_find()

Re: [PATCH v3 1/7] clkdev: Hold clocks_mutex while iterating clocks list

2019-04-04 Thread Vaittinen, Matti
Hello Stephen, Thanks for taking care of this! On Thu, 2019-04-04 at 14:53 -0700, Stephen Boyd wrote: > We recently introduced a change to support devm clk lookups. That > change > introduced a code-path that used clk_find() without holding the > 'clocks_mutex'. Unfortunately, clk_find() iterates

[PATCH v3 1/7] clkdev: Hold clocks_mutex while iterating clocks list

2019-04-04 Thread Stephen Boyd
We recently introduced a change to support devm clk lookups. That change introduced a code-path that used clk_find() without holding the 'clocks_mutex'. Unfortunately, clk_find() iterates over the 'clocks' list and so we need to prevent the list from being modified while iterating over it by holdin