diff options
author | Enric Balletbo i Serra <enric.balletbo@collabora.com> | 2019-11-29 11:22:54 +0100 |
---|---|---|
committer | Enric Balletbo i Serra <enric.balletbo@collabora.com> | 2019-12-10 10:14:02 +0100 |
commit | a69b4eebe513b8fd8f73a4c4f053941e67045660 (patch) | |
tree | a160716944f250b938521fc6887d9798cb935f60 /drivers/platform/chrome | |
parent | 205c9326fd86659fadbfd4da66ab35eb2770a331 (diff) |
platform/chrome: cros_ec_lpc: Use platform_get_irq_optional() for optional IRQs
As platform_get_irq() now prints an error when the interrupt does not
exist, use platform_get_irq_optional() to get the IRQ which is optional
to avoid below error message during probe:
[ 5.113502] cros_ec_lpcs GOOG0004:00: IRQ index 0 not found
Signed-off-by: Enric Balletbo i Serra <enric.balletbo@collabora.com>
Reviewed-by: Guenter Roeck <groeck@chromium.org>
Diffstat (limited to 'drivers/platform/chrome')
-rw-r--r-- | drivers/platform/chrome/cros_ec_lpc.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/platform/chrome/cros_ec_lpc.c b/drivers/platform/chrome/cros_ec_lpc.c index dccf479c6625..ffdea7c347f2 100644 --- a/drivers/platform/chrome/cros_ec_lpc.c +++ b/drivers/platform/chrome/cros_ec_lpc.c @@ -396,7 +396,7 @@ static int cros_ec_lpc_probe(struct platform_device *pdev) * Some boards do not have an IRQ allotted for cros_ec_lpc, * which makes ENXIO an expected (and safe) scenario. */ - irq = platform_get_irq(pdev, 0); + irq = platform_get_irq_optional(pdev, 0); if (irq > 0) ec_dev->irq = irq; else if (irq != -ENXIO) { |