From: George Cherian <george.cherian@ti.com>
To: <wim@iguana.be>
Cc: <linux-watchdog@vger.kernel.org>, <linux-kernel@vger.kernel.org>,
George Cherian <george.cherian@ti.com>
Subject: [PATCH 1/3] watchdog: dw_wdt: Remove the un-necessary check after platform_get_resource()
Date: Tue, 10 Jun 2014 10:10:06 +0530 [thread overview]
Message-ID: <1402375208-18445-1-git-send-email-george.cherian@ti.com> (raw)
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
next reply other threads:[~2014-06-10 4:41 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-06-10 4:40 George Cherian [this message]
2014-06-10 4:40 ` [PATCH 2/3] watchdog: lantiq_wdt: Remove the un-necessary check of resource after platform_get_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
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1402375208-18445-1-git-send-email-george.cherian@ti.com \
--to=george.cherian@ti.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-watchdog@vger.kernel.org \
--cc=wim@iguana.be \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).