diff options
Diffstat (limited to 'drivers/extcon/extcon-max14577.c')
-rw-r--r-- | drivers/extcon/extcon-max14577.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/extcon/extcon-max14577.c b/drivers/extcon/extcon-max14577.c index d49e891b5675..7309743d0da1 100644 --- a/drivers/extcon/extcon-max14577.c +++ b/drivers/extcon/extcon-max14577.c @@ -692,10 +692,9 @@ static int max14577_muic_probe(struct platform_device *pdev) u8 id; info = devm_kzalloc(&pdev->dev, sizeof(*info), GFP_KERNEL); - if (!info) { - dev_err(&pdev->dev, "failed to allocate memory\n"); + if (!info) return -ENOMEM; - } + info->dev = &pdev->dev; info->max14577 = max14577; |