clk: Emit a stern warning with writable debugfs enabled
authorStephen Boyd <sboyd@kernel.org>
Fri, 10 Dec 2021 01:34:05 +0000 (17:34 -0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 27 Jan 2022 10:05:30 +0000 (11:05 +0100)
commit4919c073780614df6f996ac33309fbbf2f67b199
tree47dc4b3005251006cabd25527bcbed9c208233b2
parent3872d146f2b093982e62c6f1f2c4e8f71eed4050
clk: Emit a stern warning with writable debugfs enabled

commit 489a71964f9d74e697a12cd0ace20ed829eb1f93 upstream.

We don't want vendors to be enabling this part of the clk code and
shipping it to customers. Exposing the ability to change clk frequencies
and parents via debugfs is potentially damaging to the system if folks
don't know what they're doing. Emit a strong warning so that the message
is clear: don't enable this outside of development systems.

Fixes: 37215da5553e ("clk: Add support for setting clk_rate via debugfs")
Cc: Geert Uytterhoeven <geert+renesas@glider.be>
Link: https://lore.kernel.org/r/20211210014237.2130300-1-sboyd@kernel.org
Signed-off-by: Stephen Boyd <sboyd@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/clk/clk.c