Skip to content

Commit b1a8804

Browse files
andy-shevchanwoochoi
authored andcommitted
extcon: intel-mrfld: Don't shadow error from devm_extcon_dev_allocate()
Don't shadow error from devm_extcon_dev_allocate() and return it as is. Link: https://lore.kernel.org/lkml/[email protected]/ Signed-off-by: Andy Shevchenko <[email protected]> Signed-off-by: Chanwoo Choi <[email protected]>
1 parent b1781d0 commit b1a8804

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/extcon/extcon-intel-mrfld.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -214,7 +214,7 @@ static int mrfld_extcon_probe(struct platform_device *pdev)
214214

215215
data->edev = devm_extcon_dev_allocate(dev, mrfld_extcon_cable);
216216
if (IS_ERR(data->edev))
217-
return -ENOMEM;
217+
return PTR_ERR(data->edev);
218218

219219
ret = devm_extcon_dev_register(dev, data->edev);
220220
if (ret < 0)

0 commit comments

Comments
 (0)