diff options
author | Andy Shevchenko <andriy.shevchenko@linux.intel.com> | 2019-10-11 06:22:58 -0400 |
---|---|---|
committer | Andy Shevchenko <andriy.shevchenko@linux.intel.com> | 2019-10-14 08:31:50 -0400 |
commit | 832392db9747b9c95724d37fc6a5dadd3d4ec514 (patch) | |
tree | 5ba27b609b1fdfc37d26d78a6826426905214f8a | |
parent | 71eea7071583b04e9b796ee1d6f7a07334426495 (diff) |
platform/x86: i2c-multi-instantiate: Fail the probe if no IRQ provided
For APIC case of interrupt we don't fail a ->probe() of the driver,
which makes kernel to print a lot of warnings from the children.
We have two options here:
- switch to platform_get_irq_optional(), though it won't stop children
to be probed and failed
- fail the ->probe() of i2c-multi-instantiate
Since the in reality we never had devices in the wild where IRQ resource
is optional, the latter solution suits the best.
Fixes: 799d3379a672 ("platform/x86: i2c-multi-instantiate: Introduce IOAPIC IRQ support")
Reported-by: Ammy Yi <ammy.yi@intel.com>
Cc: Heikki Krogerus <heikki.krogerus@linux.intel.com>
Cc: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Reviewed-by: Heikki Krogerus <heikki.krogerus@linux.intel.com>
-rw-r--r-- | drivers/platform/x86/i2c-multi-instantiate.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/platform/x86/i2c-multi-instantiate.c b/drivers/platform/x86/i2c-multi-instantiate.c index ea68f6ed66ae..ffb8d5d1eb5f 100644 --- a/drivers/platform/x86/i2c-multi-instantiate.c +++ b/drivers/platform/x86/i2c-multi-instantiate.c | |||
@@ -108,6 +108,7 @@ static int i2c_multi_inst_probe(struct platform_device *pdev) | |||
108 | if (ret < 0) { | 108 | if (ret < 0) { |
109 | dev_dbg(dev, "Error requesting irq at index %d: %d\n", | 109 | dev_dbg(dev, "Error requesting irq at index %d: %d\n", |
110 | inst_data[i].irq_idx, ret); | 110 | inst_data[i].irq_idx, ret); |
111 | goto error; | ||
111 | } | 112 | } |
112 | board_info.irq = ret; | 113 | board_info.irq = ret; |
113 | break; | 114 | break; |