Commit 720fd66d authored by Julia Lawall's avatar Julia Lawall Committed by Samuel Ortiz

mfd: Fix egpio kzalloc return test

Since ei is already known to be non-NULL, I assume that what was intended
was to test the result of kzalloc.
Signed-off-by: default avatarJulia Lawall <julia@diku.dk>
Signed-off-by: default avatarSamuel Ortiz <sameo@openedhand.com>
parent d2f8d7ee
...@@ -307,7 +307,7 @@ static int __init egpio_probe(struct platform_device *pdev) ...@@ -307,7 +307,7 @@ static int __init egpio_probe(struct platform_device *pdev)
ei->nchips = pdata->num_chips; ei->nchips = pdata->num_chips;
ei->chip = kzalloc(sizeof(struct egpio_chip) * ei->nchips, GFP_KERNEL); ei->chip = kzalloc(sizeof(struct egpio_chip) * ei->nchips, GFP_KERNEL);
if (!ei) { if (!ei->chip) {
ret = -ENOMEM; ret = -ENOMEM;
goto fail; goto fail;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment