Commit dee19be7 authored by Heiko Stübner's avatar Heiko Stübner Committed by Felipe Balbi

usb: gadget: s3c-hsudc: use release_mem_region instead of release_resource

As the memory region is requested through request_mem_region
use the correct paired method to release it in the error path
and don't go "beneath the API".
Reported-by: default avatarRussell King <rmk+kernel@arm.linux.org.uk>
Signed-off-by: default avatarHeiko Stuebner <heiko@sntech.de>
Signed-off-by: default avatarFelipe Balbi <balbi@ti.com>
parent bab7d037
......@@ -1376,9 +1376,7 @@ static int __devinit s3c_hsudc_probe(struct platform_device *pdev)
iounmap(hsudc->regs);
err_remap:
release_resource(hsudc->mem_rsrc);
kfree(hsudc->mem_rsrc);
release_mem_region(res->start, resource_size(res));
err_res:
if (hsudc->transceiver)
otg_put_transceiver(hsudc->transceiver);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment