Skip to content

Commit a1ea085

Browse files
Wei Yongjunbebarino
authored andcommitted
clk: stm32: rcc_reset: 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: 637cee5 ("clk: stm32: Introduce STM32MP13 RCC drivers (Reset Clock Controller)") Reported-by: Hulk Robot <[email protected]> Signed-off-by: Wei Yongjun <[email protected]> Link: https://lore.kernel.org/r/[email protected] Tested-by: Gabriel Fernandez <[email protected]> Reviewed-by: Gabriel Fernandez <[email protected]> Signed-off-by: Stephen Boyd <[email protected]>
1 parent f2906aa commit a1ea085

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

drivers/clk/stm32/reset-stm32.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,7 @@ int stm32_rcc_reset_init(struct device *dev, const struct of_device_id *match,
111111
if (!reset_data)
112112
return -ENOMEM;
113113

114+
spin_lock_init(&reset_data->lock);
114115
reset_data->membase = base;
115116
reset_data->rcdev.owner = THIS_MODULE;
116117
reset_data->rcdev.ops = &stm32_reset_ops;

0 commit comments

Comments
 (0)