Skip to content

Commit

Permalink
Input: imx6ul_tsc - use the preferred method for kzalloc()
Browse files Browse the repository at this point in the history
According to Documentation/CodingStyle:

"The preferred form for passing a size of a struct is the following:

	p = kmalloc(sizeof(*p), ...);"

so do as suggested.

Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
  • Loading branch information
Fabio Estevam authored and Dmitry Torokhov committed Sep 19, 2015
1 parent 3905de6 commit 5eab3cf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/input/touchscreen/imx6ul_tsc.c
Original file line number Diff line number Diff line change
Expand Up @@ -347,7 +347,7 @@ static int imx6ul_tsc_probe(struct platform_device *pdev)
int tsc_irq;
int adc_irq;

tsc = devm_kzalloc(&pdev->dev, sizeof(struct imx6ul_tsc), GFP_KERNEL);
tsc = devm_kzalloc(&pdev->dev, sizeof(*tsc), GFP_KERNEL);
if (!tsc)
return -ENOMEM;

Expand Down

0 comments on commit 5eab3cf

Please sign in to comment.