Loading Documentation/i2c/writing-clients +3 −3 Original line number Diff line number Diff line Loading @@ -267,9 +267,9 @@ insmod parameter of the form force_<kind>. Fortunately, as a module writer, you just have to define the `normal_i2c' parameter. The complete declaration could look like this: /* Scan 0x37, and 0x48 to 0x4f */ static unsigned short normal_i2c[] = { 0x37, 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, I2C_CLIENT_END }; /* Scan 0x4c to 0x4f */ static const unsigned short normal_i2c[] = { 0x4c, 0x4d, 0x4e, 0x4f, I2C_CLIENT_END }; /* Magic definition of all other variables and things */ I2C_CLIENT_INSMOD; Loading arch/arm/mach-pxa/akita-ioexp.c +1 −1 Original line number Diff line number Diff line Loading @@ -29,7 +29,7 @@ #define MAX7310_TIMEOUT 0x04 /* Addresses to scan */ static unsigned short normal_i2c[] = { 0x18, I2C_CLIENT_END }; static const unsigned short normal_i2c[] = { 0x18, I2C_CLIENT_END }; /* I2C Magic */ I2C_CLIENT_INSMOD; Loading drivers/i2c/chips/eeprom.c +1 −1 Original line number Diff line number Diff line Loading @@ -35,7 +35,7 @@ #include <linux/mutex.h> /* Addresses to scan */ static unsigned short normal_i2c[] = { 0x50, 0x51, 0x52, 0x53, 0x54, static const unsigned short normal_i2c[] = { 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, I2C_CLIENT_END }; /* Insmod parameters */ Loading drivers/i2c/chips/max6875.c +1 −1 Original line number Diff line number Diff line Loading @@ -34,7 +34,7 @@ #include <linux/mutex.h> /* Do not scan - the MAX6875 access method will write to some EEPROM chips */ static unsigned short normal_i2c[] = {I2C_CLIENT_END}; static const unsigned short normal_i2c[] = { I2C_CLIENT_END }; /* Insmod parameters */ I2C_CLIENT_INSMOD_1(max6875); Loading drivers/i2c/chips/pcf8574.c +5 −3 Original line number Diff line number Diff line Loading @@ -41,9 +41,11 @@ #include <linux/i2c.h> /* Addresses to scan */ static unsigned short normal_i2c[] = { 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, static const unsigned short normal_i2c[] = { 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, I2C_CLIENT_END }; I2C_CLIENT_END }; /* Insmod parameters */ I2C_CLIENT_INSMOD_2(pcf8574, pcf8574a); Loading Loading
Documentation/i2c/writing-clients +3 −3 Original line number Diff line number Diff line Loading @@ -267,9 +267,9 @@ insmod parameter of the form force_<kind>. Fortunately, as a module writer, you just have to define the `normal_i2c' parameter. The complete declaration could look like this: /* Scan 0x37, and 0x48 to 0x4f */ static unsigned short normal_i2c[] = { 0x37, 0x48, 0x49, 0x4a, 0x4b, 0x4c, 0x4d, 0x4e, 0x4f, I2C_CLIENT_END }; /* Scan 0x4c to 0x4f */ static const unsigned short normal_i2c[] = { 0x4c, 0x4d, 0x4e, 0x4f, I2C_CLIENT_END }; /* Magic definition of all other variables and things */ I2C_CLIENT_INSMOD; Loading
arch/arm/mach-pxa/akita-ioexp.c +1 −1 Original line number Diff line number Diff line Loading @@ -29,7 +29,7 @@ #define MAX7310_TIMEOUT 0x04 /* Addresses to scan */ static unsigned short normal_i2c[] = { 0x18, I2C_CLIENT_END }; static const unsigned short normal_i2c[] = { 0x18, I2C_CLIENT_END }; /* I2C Magic */ I2C_CLIENT_INSMOD; Loading
drivers/i2c/chips/eeprom.c +1 −1 Original line number Diff line number Diff line Loading @@ -35,7 +35,7 @@ #include <linux/mutex.h> /* Addresses to scan */ static unsigned short normal_i2c[] = { 0x50, 0x51, 0x52, 0x53, 0x54, static const unsigned short normal_i2c[] = { 0x50, 0x51, 0x52, 0x53, 0x54, 0x55, 0x56, 0x57, I2C_CLIENT_END }; /* Insmod parameters */ Loading
drivers/i2c/chips/max6875.c +1 −1 Original line number Diff line number Diff line Loading @@ -34,7 +34,7 @@ #include <linux/mutex.h> /* Do not scan - the MAX6875 access method will write to some EEPROM chips */ static unsigned short normal_i2c[] = {I2C_CLIENT_END}; static const unsigned short normal_i2c[] = { I2C_CLIENT_END }; /* Insmod parameters */ I2C_CLIENT_INSMOD_1(max6875); Loading
drivers/i2c/chips/pcf8574.c +5 −3 Original line number Diff line number Diff line Loading @@ -41,9 +41,11 @@ #include <linux/i2c.h> /* Addresses to scan */ static unsigned short normal_i2c[] = { 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, static const unsigned short normal_i2c[] = { 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x27, 0x38, 0x39, 0x3a, 0x3b, 0x3c, 0x3d, 0x3e, 0x3f, I2C_CLIENT_END }; I2C_CLIENT_END }; /* Insmod parameters */ I2C_CLIENT_INSMOD_2(pcf8574, pcf8574a); Loading