clk: avoid returning local variable pointers during clock registration
Several clock drivers initialize the clk_hw init element to a
local variable before calling [devm_]clk_hw_register() on it.
This style is fine. However, the init pointer value becomes
invalid as soon as the registration function returns. Clear
the init pointer to avoid the possibility of accessing an
invalid memory address after registration completes.
Change-Id: I3ae72c2c7ebc30e443c7034d072591827f4342aa
Signed-off-by:
David Collins <collinsd@codeaurora.org>
Loading
Please register or sign in to comment