summaryrefslogtreecommitdiffstats
path: root/drivers/clk/versatile
diff options
context:
space:
mode:
authorMarkus Elfring <elfring@users.sourceforge.net>2017-09-27 21:24:43 +0200
committerStephen Boyd <sboyd@codeaurora.org>2017-11-13 17:42:56 -0800
commita72da43c92dc09488ac2944b103de037c435302a (patch)
treec4f7b497aa93ddde8ec0ae96cf8265475d939483 /drivers/clk/versatile
parente343b81e4d9d1551ec3a651a7d30630a268fd35e (diff)
downloadblackbird-obmc-linux-a72da43c92dc09488ac2944b103de037c435302a.tar.gz
blackbird-obmc-linux-a72da43c92dc09488ac2944b103de037c435302a.zip
clk: versatile: Improve sizeof() usage
Replace the specification of a data structure by a pointer dereference as the parameter for the operator "sizeof" to make the corresponding size determination a bit safer according to the Linux coding style convention. This issue was detected by using the Coccinelle software. Signed-off-by: Markus Elfring <elfring@users.sourceforge.net> Acked-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
Diffstat (limited to 'drivers/clk/versatile')
-rw-r--r--drivers/clk/versatile/clk-icst.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/clk/versatile/clk-icst.c b/drivers/clk/versatile/clk-icst.c
index 20ab4ceffb28..dafe7a45875d 100644
--- a/drivers/clk/versatile/clk-icst.c
+++ b/drivers/clk/versatile/clk-icst.c
@@ -359,7 +359,7 @@ static struct clk *icst_clk_setup(struct device *dev,
struct clk_init_data init;
struct icst_params *pclone;
- icst = kzalloc(sizeof(struct clk_icst), GFP_KERNEL);
+ icst = kzalloc(sizeof(*icst), GFP_KERNEL);
if (!icst)
return ERR_PTR(-ENOMEM);
OpenPOWER on IntegriCloud