Re: [PATCH] IIO: Adds ACPI support for ST gyroscopes

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 03/25/2015 07:05 PM, sathyanarayanan kuppuswamy wrote:
  static acpi_status
  acpi_gpio_adr_space_handler(u32 function, acpi_physical_address address,
                  u32 bits, u64 *value, void *handler_context,
diff --git a/drivers/i2c/i2c-core.c b/drivers/i2c/i2c-core.c
index edf274cabe81..c12a3f24ada4 100644
--- a/drivers/i2c/i2c-core.c
+++ b/drivers/i2c/i2c-core.c
@@ -629,8 +629,13 @@ static int i2c_device_probe(struct device *dev)
      if (!client)
          return 0;
-    if (!client->irq && dev->of_node) {
-        int irq = of_irq_get(dev->of_node, 0);
+    if (client->irq <= 0) {
Isn't irq 0 a valid interrupt number ? Shouldn't it be client->irq < 0 ?

0 is a invalid interrupt number these days, and is typically used to indicate no IRQ.

--
To unsubscribe from this list: send the line "unsubscribe linux-iio" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Input]     [Linux Kernel]     [Linux SCSI]     [X.org]

  Powered by Linux