diff options
| author | Hans de Goede <hdegoede@redhat.com> | 2017-11-22 06:28:17 -0500 |
|---|---|---|
| committer | Wolfram Sang <wsa@the-dreams.de> | 2017-11-27 13:11:27 -0500 |
| commit | 6e0c9507bf51e1517a80ad0ac171e5402528fcef (patch) | |
| tree | 0adec0b63d87192ea27dd696d61e9a4b5d9559e0 | |
| parent | 4fbd8d194f06c8a3fd2af1ce560ddb31f7ec8323 (diff) | |
i2c: i801: Fix Failed to allocate irq -2147483648 error
On Apollo Lake devices the BIOS does not set up IRQ routing for the i801
SMBUS controller IRQ, so we end up with dev->irq set to IRQ_NOTCONNECTED.
Detect this and do not try to use the irq in this case silencing:
i801_smbus 0000:00:1f.1: Failed to allocate irq -2147483648: -107
Cc: stable@vger.kernel.org
BugLink: https://communities.intel.com/thread/114759
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Reviewed-by: Jean Delvare <jdelvare@suse.de>
Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
| -rw-r--r-- | drivers/i2c/busses/i2c-i801.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/i2c/busses/i2c-i801.c b/drivers/i2c/busses/i2c-i801.c index 9e12a53ef7b8..8eac00efadc1 100644 --- a/drivers/i2c/busses/i2c-i801.c +++ b/drivers/i2c/busses/i2c-i801.c | |||
| @@ -1617,6 +1617,9 @@ static int i801_probe(struct pci_dev *dev, const struct pci_device_id *id) | |||
| 1617 | /* Default timeout in interrupt mode: 200 ms */ | 1617 | /* Default timeout in interrupt mode: 200 ms */ |
| 1618 | priv->adapter.timeout = HZ / 5; | 1618 | priv->adapter.timeout = HZ / 5; |
| 1619 | 1619 | ||
| 1620 | if (dev->irq == IRQ_NOTCONNECTED) | ||
| 1621 | priv->features &= ~FEATURE_IRQ; | ||
| 1622 | |||
| 1620 | if (priv->features & FEATURE_IRQ) { | 1623 | if (priv->features & FEATURE_IRQ) { |
| 1621 | u16 pcictl, pcists; | 1624 | u16 pcictl, pcists; |
| 1622 | 1625 | ||
