summaryrefslogtreecommitdiffstats
path: root/drivers/input/keyboard/samsung-keypad.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/input/keyboard/samsung-keypad.c')
-rw-r--r--drivers/input/keyboard/samsung-keypad.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/input/keyboard/samsung-keypad.c b/drivers/input/keyboard/samsung-keypad.c
index 316414465c77..1fe1aa2adf85 100644
--- a/drivers/input/keyboard/samsung-keypad.c
+++ b/drivers/input/keyboard/samsung-keypad.c
@@ -281,7 +281,7 @@ samsung_keypad_parse_dt(struct device *dev)
key_count = of_get_child_count(np);
keymap_data->keymap_size = key_count;
- keymap = devm_kzalloc(dev, sizeof(uint32_t) * key_count, GFP_KERNEL);
+ keymap = devm_kcalloc(dev, key_count, sizeof(uint32_t), GFP_KERNEL);
if (!keymap) {
dev_err(dev, "could not allocate memory for keymap\n");
return ERR_PTR(-ENOMEM);