lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20191215175120.3290-13-tiny.windzz@gmail.com>
Date:   Sun, 15 Dec 2019 17:51:20 +0000
From:   Yangtao Li <tiny.windzz@...il.com>
To:     manuel.lauss@...il.com, ulf.hansson@...aro.org,
        khilman@...libre.com, chaotian.jing@...iatek.com,
        matthias.bgg@...il.com, nico@...xnic.net, adrian.hunter@...el.com,
        agross@...nel.org, bjorn.andersson@...aro.org, ben-linux@...ff.org,
        jh80.chung@...sung.com, vireshk@...nel.org, mripard@...nel.org,
        wens@...e.org, wsa+renesas@...g-engineering.com,
        gregkh@...uxfoundation.org, kstewart@...uxfoundation.org,
        yamada.masahiro@...ionext.com, tglx@...utronix.de,
        allison@...utok.net, yoshihiro.shimoda.uh@...esas.com,
        geert+renesas@...der.be, linus.walleij@...aro.org
Cc:     linux-mmc@...r.kernel.org, linux-kernel@...r.kernel.org,
        linux-arm-kernel@...ts.infradead.org,
        linux-amlogic@...ts.infradead.org,
        linux-mediatek@...ts.infradead.org, linux-arm-msm@...r.kernel.org,
        Yangtao Li <tiny.windzz@...il.com>
Subject: [PATCH 13/13] mmc: au1xmmc: switch to platform_get_irq

platform_get_resource(pdev, IORESOURCE_IRQ) is not recommended for
requesting IRQ's resources, as they can be not ready yet. Using
platform_get_irq() instead is preferred for getting IRQ even if it
was not retrieved earlier.

Signed-off-by: Yangtao Li <tiny.windzz@...il.com>
---
 drivers/mmc/host/au1xmmc.c | 7 ++-----
 1 file changed, 2 insertions(+), 5 deletions(-)

diff --git a/drivers/mmc/host/au1xmmc.c b/drivers/mmc/host/au1xmmc.c
index bc8aeb47a7b4..8823680ca42c 100644
--- a/drivers/mmc/host/au1xmmc.c
+++ b/drivers/mmc/host/au1xmmc.c
@@ -984,12 +984,9 @@ static int au1xmmc_probe(struct platform_device *pdev)
 		goto out2;
 	}
 
-	r = platform_get_resource(pdev, IORESOURCE_IRQ, 0);
-	if (!r) {
-		dev_err(&pdev->dev, "no IRQ defined\n");
+	host->irq = platform_get_irq(pdev, 0);
+	if (host->irq < 0)
 		goto out3;
-	}
-	host->irq = r->start;
 
 	mmc->ops = &au1xmmc_ops;
 
-- 
2.17.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ