svn path=/dists/trunk/linux-2.6/; revision=11530
This commit is contained in:
Martin Michlmayr 2008-06-06 06:10:42 +00:00
parent 7fb1ffc66c
commit d14d9ae58b
2 changed files with 63 additions and 0 deletions

View File

@ -0,0 +1,62 @@
I2C subsystem now requires .id_table, adjust pca9532 driver accordingly.
Signed-off-by: Riku Voipio <riku.voipio@iki.fi>
---
drivers/leds/leds-pca9532.c | 16 +++++++++++++---
1 files changed, 13 insertions(+), 3 deletions(-)
diff --git a/drivers/leds/leds-pca9532.c b/drivers/leds/leds-pca9532.c
index 36b4088..4064d4f 100644
--- a/drivers/leds/leds-pca9532.c
+++ b/drivers/leds/leds-pca9532.c
@@ -18,7 +18,7 @@
#include <linux/mutex.h>
#include <linux/leds-pca9532.h>
-static unsigned short normal_i2c[] = { /*0x60,*/ I2C_CLIENT_END};
+static const unsigned short normal_i2c[] = { /*0x60,*/ I2C_CLIENT_END};
I2C_CLIENT_INSMOD_1(pca9532);
#define PCA9532_REG_PSC(i) (0x2+(i)*2)
@@ -38,15 +38,24 @@ struct pca9532_data {
u8 psc[2];
};
-static int pca9532_probe(struct i2c_client *client);
+static int pca9532_probe(struct i2c_client *client,
+ const struct i2c_device_id *id);
static int pca9532_remove(struct i2c_client *client);
+static const struct i2c_device_id pca9532_id[] = {
+ { "pca9532", 0 },
+ { }
+};
+
+MODULE_DEVICE_TABLE(i2c, pca9532_id);
+
static struct i2c_driver pca9532_driver = {
.driver = {
.name = "pca9532",
},
.probe = pca9532_probe,
.remove = pca9532_remove,
+ .id_table = pca9532_id,
};
/* We have two pwm/blinkers, but 16 possible leds to drive. Additionaly,
@@ -257,7 +266,8 @@ exit:
}
-static int pca9532_probe(struct i2c_client *client)
+static int pca9532_probe(struct i2c_client *client,
+ const struct i2c_device_id *id)
{
struct pca9532_data *data = i2c_get_clientdata(client);
struct pca9532_platform_data *pca9532_pdata = client->dev.platform_data;
--
1.5.5.1
--
"rm -rf" only sounds scary if you don't have backups

View File

@ -31,6 +31,7 @@
+ features/arm/speed_flush_cache.patch
+ features/arm/5281d0.patch
+ features/arm/led-pca9532-generic.patch
+ features/arm/led-pca9532-fix.patch
+ features/arm/led-pca9532-n2100.patch
+ features/all/at76.patch
+ bugfix/fix-hifn_795X-divdi3.patch