usb: musb: core: call dma_controller_destroy() in the err path

The cleanup in the error is missing the dma controller. The structure is
allocated at runtime and ux500 allocates even a little more than just
this struct. So cleanup!

Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Signed-off-by: Felipe Balbi <balbi@ti.com>
This commit is contained in:
Sebastian Andrzej Siewior 2013-06-19 17:38:14 +02:00 коммит произвёл Felipe Balbi
Родитель 6904b845e2
Коммит f3ce4d5b2d
1 изменённых файлов: 2 добавлений и 0 удалений

Просмотреть файл

@ -1933,6 +1933,8 @@ fail4:
musb_gadget_cleanup(musb);
fail3:
if (musb->dma_controller)
dma_controller_destroy(musb->dma_controller);
pm_runtime_put_sync(musb->controller);
fail2: