linux-watchdog.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/3] watchdog: dw_wdt: Remove the un-necessary check after platform_get_resource()
@ 2014-06-10  4:40 George Cherian
  2014-06-10  4:40 ` [PATCH 2/3] watchdog: lantiq_wdt: Remove the un-necessary check of resource " George Cherian
                   ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: George Cherian @ 2014-06-10  4:40 UTC (permalink / raw)
  To: wim; +Cc: linux-watchdog, linux-kernel, George Cherian

devm_ioremap_resource() checks for valid resource.
Remove the un-necessary check after platform_get_resource().

Signed-off-by: George Cherian <george.cherian@ti.com>
---
 drivers/watchdog/dw_wdt.c | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/drivers/watchdog/dw_wdt.c b/drivers/watchdog/dw_wdt.c
index ee4f86b..9f21029 100644
--- a/drivers/watchdog/dw_wdt.c
+++ b/drivers/watchdog/dw_wdt.c
@@ -296,9 +296,6 @@ static int dw_wdt_drv_probe(struct platform_device *pdev)
 	int ret;
 	struct resource *mem = platform_get_resource(pdev, IORESOURCE_MEM, 0);
 
-	if (!mem)
-		return -EINVAL;
-
 	dw_wdt.regs = devm_ioremap_resource(&pdev->dev, mem);
 	if (IS_ERR(dw_wdt.regs))
 		return PTR_ERR(dw_wdt.regs);
-- 
1.8.3.1


^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2014-06-10 19:24 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-06-10  4:40 [PATCH 1/3] watchdog: dw_wdt: Remove the un-necessary check after platform_get_resource() George Cherian
2014-06-10  4:40 ` [PATCH 2/3] watchdog: lantiq_wdt: Remove the un-necessary check of resource " George Cherian
2014-06-10 19:23   ` Guenter Roeck
2014-06-10  4:40 ` [PATCH 3/3] watchdog: shwdt: Remove the unnecessary " George Cherian
2014-06-10 19:24   ` Guenter Roeck
2014-06-10 19:23 ` [PATCH 1/3] watchdog: dw_wdt: Remove the un-necessary check " Guenter Roeck

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).