public inbox for linux-rockchip@lists.infradead.org
 help / color / mirror / Atom feed
* [PATCH] mailbox: rockchip: Delete redundant return value check of platform_get_resource()
@ 2017-03-25 15:56 Belen Sarabia
  0 siblings, 0 replies; only message in thread
From: Belen Sarabia @ 2017-03-25 15:56 UTC (permalink / raw)
  To: Jassi Brar, Heiko Stuebner
  Cc: linux-rockchip-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r

Delete redundant error handling on the result to platform_get_resource() when the value is
passed to devm_ioremap_resource().

Signed-off-by: Belen Sarabia <belensarabia-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
---
 drivers/mailbox/rockchip-mailbox.c | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/drivers/mailbox/rockchip-mailbox.c b/drivers/mailbox/rockchip-mailbox.c
index d702a20..4dae133 100644
--- a/drivers/mailbox/rockchip-mailbox.c
+++ b/drivers/mailbox/rockchip-mailbox.c
@@ -205,9 +205,6 @@ static int rockchip_mbox_probe(struct platform_device *pdev)
 	mb->mbox.txdone_irq = true;
 
 	res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
-	if (!res)
-		return -ENODEV;
-
 	mb->mbox_base = devm_ioremap_resource(&pdev->dev, res);
 	if (IS_ERR(mb->mbox_base))
 		return PTR_ERR(mb->mbox_base);
-- 
1.9.1

^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2017-03-25 15:56 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-03-25 15:56 [PATCH] mailbox: rockchip: Delete redundant return value check of platform_get_resource() Belen Sarabia

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox