gpio: adp5588-gpio: gpio_start must be signed
authorMichael Hennerich <michael.hennerich@analog.com>
Wed, 27 Oct 2010 22:33:20 +0000 (15:33 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Thu, 28 Oct 2010 01:03:07 +0000 (18:03 -0700)
Common code interprets this as a signed value (a negative value is used to
request dynamic ID allocation), so make sure the platform data has proper
types to support that.

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
include/linux/i2c/adp5588.h

index 531376b777732669a55c49fb67bc114624b2f890..bec05ed2176617c5417687860ee23e305498566f 100644 (file)
@@ -141,9 +141,9 @@ struct adp5588_kpad_platform_data {
 };
 
 struct adp5588_gpio_platform_data {
-       unsigned gpio_start;            /* GPIO Chip base # */
-       unsigned irq_base;              /* interrupt base # */
-       unsigned pullup_dis_mask;       /* Pull-Up Disable Mask */
+       int gpio_start;         /* GPIO Chip base # */
+       unsigned irq_base;      /* interrupt base # */
+       unsigned pullup_dis_mask; /* Pull-Up Disable Mask */
        int     (*setup)(struct i2c_client *client,
                                int gpio, unsigned ngpio,
                                void *context);