diff options
author | Wang Hai <wanghai38@huawei.com> | 2021-06-30 03:58:23 +0200 |
---|---|---|
committer | Stephen Boyd <sboyd@kernel.org> | 2021-06-30 20:17:20 +0200 |
commit | b1f247714acb2a78452ba555807764b2c1115a40 (patch) | |
tree | 9fa7153dbf2251ff0b5979db034161cf0e8426bc | |
parent | Merge branches 'clk-st', 'clk-si' and 'clk-hisilicon' into clk-next (diff) | |
download | linux-b1f247714acb2a78452ba555807764b2c1115a40.tar.xz linux-b1f247714acb2a78452ba555807764b2c1115a40.zip |
clk: stm32mp1: fix missing spin_lock_init()
The driver allocates the spinlock but not initialize it.
Use spin_lock_init() on it to initialize it correctly.
Fixes: c392df194a2d ("clk: stm32mp1: move RCC reset controller into RCC clock driver")
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Wang Hai <wanghai38@huawei.com>
Link: https://lore.kernel.org/r/20210630015824.2555840-1-wanghai38@huawei.com
Signed-off-by: Stephen Boyd <sboyd@kernel.org>
-rw-r--r-- | drivers/clk/clk-stm32mp1.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/clk/clk-stm32mp1.c b/drivers/clk/clk-stm32mp1.c index 6adc625e79cb..256575bd29b9 100644 --- a/drivers/clk/clk-stm32mp1.c +++ b/drivers/clk/clk-stm32mp1.c @@ -2263,6 +2263,7 @@ static int stm32_rcc_reset_init(struct device *dev, void __iomem *base, if (!reset_data) return -ENOMEM; + spin_lock_init(&reset_data->lock); reset_data->membase = base; reset_data->rcdev.owner = THIS_MODULE; reset_data->rcdev.ops = &stm32_reset_ops; |