media_device_cleanup() wasn't called, which caused a small
memory leak.
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
 
 err_mdev_unregister:
        media_device_unregister(&vimc->mdev);
+       media_device_cleanup(&vimc->mdev);
 err_comp_unbind_all:
        component_unbind_all(master, NULL);
 err_v4l2_unregister:
        dev_dbg(master, "unbind");
 
        media_device_unregister(&vimc->mdev);
+       media_device_cleanup(&vimc->mdev);
        component_unbind_all(master, NULL);
        v4l2_device_unregister(&vimc->v4l2_dev);
 }