From: Banajit Goswami Date: Thu, 20 May 2010 10:58:25 +0000 (+0100) Subject: watchdog: s3c2410_wdt - Fix on handling of the request_mem_region fail X-Git-Tag: v2.6.35-rc1~269^2~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=100fb76f0acfebcb7c72875890b9ef33ff04dc2b;p=profile%2Fivi%2Fkernel-adaptation-intel-automotive.git watchdog: s3c2410_wdt - Fix on handling of the request_mem_region fail If the request for wdt_mem region fails, this patch modifies the driver such that, it does not try to release the wdt_mem region on exit. Signed-off-by: Banajit Goswami Signed-off-by: Kukjin Kim Signed-off-by: Ben Dooks Signed-off-by: Wim Van Sebroeck --- diff --git a/drivers/watchdog/s3c2410_wdt.c b/drivers/watchdog/s3c2410_wdt.c index 095cbf3..3009325 100644 --- a/drivers/watchdog/s3c2410_wdt.c +++ b/drivers/watchdog/s3c2410_wdt.c @@ -426,8 +426,7 @@ static int __devinit s3c2410wdt_probe(struct platform_device *pdev) wdt_mem = request_mem_region(res->start, size, pdev->name); if (wdt_mem == NULL) { dev_err(dev, "failed to get memory region\n"); - ret = -ENOENT; - goto err_req; + return -EBUSY; } wdt_base = ioremap(res->start, size);