diff options
author | Jean Delvare <khali@linux-fr.org> | 2009-12-14 15:17:27 -0500 |
---|---|---|
committer | Jean Delvare <khali@linux-fr.org> | 2009-12-14 15:17:27 -0500 |
commit | e5e9f44c246fbafe723e579e9fe887677beb40e4 (patch) | |
tree | 53d65b38b6db7aa250400056091a760cced42cd7 /include/linux/i2c.h | |
parent | 1f86df49ddfd0067cce941187d57b2fd2f749a9e (diff) |
i2c: Drop I2C_CLIENT_INSMOD_2 to 8
These macros simply declare an enum, so drivers might as well declare
it themselves. This puts an end to the arbitrary limit of 8 chip types
per i2c driver.
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Tested-by: Wolfram Sang <w.sang@pengutronix.de>
Diffstat (limited to 'include/linux/i2c.h')
-rw-r--r-- | include/linux/i2c.h | 24 |
1 files changed, 0 insertions, 24 deletions
diff --git a/include/linux/i2c.h b/include/linux/i2c.h index 7178b27146ed..cc6e1508ae90 100644 --- a/include/linux/i2c.h +++ b/include/linux/i2c.h | |||
@@ -602,29 +602,5 @@ union i2c_smbus_data { | |||
602 | module_param_array(var, short, &var##_num, 0); \ | 602 | module_param_array(var, short, &var##_num, 0); \ |
603 | MODULE_PARM_DESC(var, desc) | 603 | MODULE_PARM_DESC(var, desc) |
604 | 604 | ||
605 | /* These are the ones you want to use in your own drivers. Pick the one | ||
606 | which matches the number of devices the driver differenciates between. */ | ||
607 | #define I2C_CLIENT_INSMOD_2(chip1, chip2) \ | ||
608 | enum chips { any_chip, chip1, chip2 } | ||
609 | |||
610 | #define I2C_CLIENT_INSMOD_3(chip1, chip2, chip3) \ | ||
611 | enum chips { any_chip, chip1, chip2, chip3 } | ||
612 | |||
613 | #define I2C_CLIENT_INSMOD_4(chip1, chip2, chip3, chip4) \ | ||
614 | enum chips { any_chip, chip1, chip2, chip3, chip4 } | ||
615 | |||
616 | #define I2C_CLIENT_INSMOD_5(chip1, chip2, chip3, chip4, chip5) \ | ||
617 | enum chips { any_chip, chip1, chip2, chip3, chip4, chip5 } | ||
618 | |||
619 | #define I2C_CLIENT_INSMOD_6(chip1, chip2, chip3, chip4, chip5, chip6) \ | ||
620 | enum chips { any_chip, chip1, chip2, chip3, chip4, chip5, chip6 } | ||
621 | |||
622 | #define I2C_CLIENT_INSMOD_7(chip1, chip2, chip3, chip4, chip5, chip6, chip7) \ | ||
623 | enum chips { any_chip, chip1, chip2, chip3, chip4, chip5, chip6, \ | ||
624 | chip7 } | ||
625 | |||
626 | #define I2C_CLIENT_INSMOD_8(chip1, chip2, chip3, chip4, chip5, chip6, chip7, chip8) \ | ||
627 | enum chips { any_chip, chip1, chip2, chip3, chip4, chip5, chip6, \ | ||
628 | chip7, chip8 } | ||
629 | #endif /* __KERNEL__ */ | 605 | #endif /* __KERNEL__ */ |
630 | #endif /* _LINUX_I2C_H */ | 606 | #endif /* _LINUX_I2C_H */ |