diff options
author | Wolfram Sang <wsa+renesas@sang-engineering.com> | 2022-08-18 23:00:00 +0200 |
---|---|---|
committer | Stephen Boyd <sboyd@kernel.org> | 2022-08-22 16:22:53 -0700 |
commit | c19edff61210eb846bf8ec44c9f87d1ca9efdfd2 (patch) | |
tree | 7b4b4499fadffe512f48601c6822eb6a563fea9d /drivers/clk/clkdev.c | |
parent | 568035b01cfb107af8d2e4bd2fb9aea22cf5b868 (diff) | |
download | linux-c19edff61210eb846bf8ec44c9f87d1ca9efdfd2.tar.gz linux-c19edff61210eb846bf8ec44c9f87d1ca9efdfd2.tar.bz2 linux-c19edff61210eb846bf8ec44c9f87d1ca9efdfd2.zip |
clk: move from strlcpy with unused retval to strscpy
Follow the advice of the below link and prefer 'strscpy' in this
subsystem. Conversion is 1:1 because the return value is not used.
Generated by a coccinelle script.
Link: https://lore.kernel.org/r/CAHk-=wgfRnXz0W3D37d01q3JFkr_i_uTL=V6A6G1oUZcprmknw@mail.gmail.com/
Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
Link: https://lore.kernel.org/r/20220818210000.6600-1-wsa+renesas@sang-engineering.com
Signed-off-by: Stephen Boyd <sboyd@kernel.org>
Diffstat (limited to 'drivers/clk/clkdev.c')
-rw-r--r-- | drivers/clk/clkdev.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/clk/clkdev.c b/drivers/clk/clkdev.c index 67f601a41023..a4d4bd3f5be5 100644 --- a/drivers/clk/clkdev.c +++ b/drivers/clk/clkdev.c @@ -165,7 +165,7 @@ vclkdev_alloc(struct clk_hw *hw, const char *con_id, const char *dev_fmt, cla->cl.clk_hw = hw; if (con_id) { - strlcpy(cla->con_id, con_id, sizeof(cla->con_id)); + strscpy(cla->con_id, con_id, sizeof(cla->con_id)); cla->cl.con_id = cla->con_id; } |