Skip to content

Commit

Permalink
mfd: Fix egpio kzalloc return test
Browse files Browse the repository at this point in the history
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: Julia Lawall <julia@diku.dk>
Signed-off-by: Samuel Ortiz <sameo@openedhand.com>
  • Loading branch information
Julia Lawall authored and Samuel Ortiz committed Feb 17, 2009
1 parent d2f8d7e commit 720fd66
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/mfd/htc-egpio.c
Original file line number Diff line number Diff line change
Expand Up @@ -307,7 +307,7 @@ static int __init egpio_probe(struct platform_device *pdev)

ei->nchips = pdata->num_chips;
ei->chip = kzalloc(sizeof(struct egpio_chip) * ei->nchips, GFP_KERNEL);
if (!ei) {
if (!ei->chip) {
ret = -ENOMEM;
goto fail;
}
Expand Down

0 comments on commit 720fd66

Please sign in to comment.