* [PATCH] drivers/leds/leds-pca9633.c: Fix kcalloc parameters swapped
@ 2012-02-10 11:34 Axel Lin
0 siblings, 0 replies; only message in thread
From: Axel Lin @ 2012-02-10 11:34 UTC (permalink / raw)
To: linux-kernel; +Cc: Peter Meerwald, Richard Purdie, Andrew Morton
The first parameter should be "number of elements" and the second parameter
should be "element size".
Signed-off-by: Axel Lin <axel.lin@gmail.com>
---
drivers/leds/leds-pca9633.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/leds/leds-pca9633.c b/drivers/leds/leds-pca9633.c
index c408ddc..80cb61a 100644
--- a/drivers/leds/leds-pca9633.c
+++ b/drivers/leds/leds-pca9633.c
@@ -110,7 +110,7 @@ static int __devinit pca9633_probe(struct i2c_client *client,
}
}
- pca9633 = kcalloc(sizeof(*pca9633), 4, GFP_KERNEL);
+ pca9633 = kcalloc(4, sizeof(*pca9633), GFP_KERNEL);
if (!pca9633)
return -ENOMEM;
--
1.7.5.4
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2012-02-10 11:34 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-02-10 11:34 [PATCH] drivers/leds/leds-pca9633.c: Fix kcalloc parameters swapped Axel Lin
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).