mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-11-08 03:33:25 -05:00
[media] coda: Unregister v4l2 upon alloc_workqueue() error
If alloc_workqueue() fails, we should go to the 'err_v4l2_register' label, which will unregister the v4l2 device. Signed-off-by: Fabio Estevam <[email protected]> Acked-by: Philipp Zabel <[email protected]> Signed-off-by: Mauro Carvalho Chehab <[email protected]>
This commit is contained in:
parent
b7bd660a51
commit
74d08d55ed
1 changed files with 2 additions and 1 deletions
|
|
@ -2152,7 +2152,8 @@ static int coda_probe(struct platform_device *pdev)
|
|||
dev->workqueue = alloc_workqueue("coda", WQ_UNBOUND | WQ_MEM_RECLAIM, 1);
|
||||
if (!dev->workqueue) {
|
||||
dev_err(&pdev->dev, "unable to alloc workqueue\n");
|
||||
return -ENOMEM;
|
||||
ret = -ENOMEM;
|
||||
goto err_v4l2_register;
|
||||
}
|
||||
|
||||
platform_set_drvdata(pdev, dev);
|
||||
|
|
|
|||
Loading…
Reference in a new issue