diff options
author | Kumar Gala <galak@kernel.crashing.org> | 2007-12-11 23:17:24 -0600 |
---|---|---|
committer | Kumar Gala <galak@kernel.crashing.org> | 2007-12-11 23:17:24 -0600 |
commit | ec9686c4a57ea46c97126660936f66e8a5eb87eb (patch) | |
tree | d785261ff5e953a3dbcb7fe803739ea34df94f50 /arch/powerpc/sysdev/fsl_soc.c | |
parent | 1c1d1672b6b00c7061ea2468d740b4aaf34a763c (diff) | |
download | blackbird-op-linux-ec9686c4a57ea46c97126660936f66e8a5eb87eb.tar.gz blackbird-op-linux-ec9686c4a57ea46c97126660936f66e8a5eb87eb.zip |
[POWERPC] FSL: I2C device tree cleanups
* Removed device_type = "i2c"
* Added missing second I2C controller on MPC8548 CDS, MPC8544 DS
* Added #address-cells, #size-cells, and cell-index where missing
Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
Diffstat (limited to 'arch/powerpc/sysdev/fsl_soc.c')
-rw-r--r-- | arch/powerpc/sysdev/fsl_soc.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/arch/powerpc/sysdev/fsl_soc.c b/arch/powerpc/sysdev/fsl_soc.c index 3ace7474809e..81af4bdf252a 100644 --- a/arch/powerpc/sysdev/fsl_soc.c +++ b/arch/powerpc/sysdev/fsl_soc.c @@ -390,13 +390,11 @@ static void __init of_register_i2c_devices(struct device_node *adap_node, static int __init fsl_i2c_of_init(void) { struct device_node *np; - unsigned int i; + unsigned int i = 0; struct platform_device *i2c_dev; int ret; - for (np = NULL, i = 0; - (np = of_find_compatible_node(np, "i2c", "fsl-i2c")) != NULL; - i++) { + for_each_compatible_node(np, NULL, "fsl-i2c") { struct resource r[2]; struct fsl_i2c_platform_data i2c_data; const unsigned char *flags = NULL; @@ -432,7 +430,7 @@ static int __init fsl_i2c_of_init(void) if (ret) goto unreg; - of_register_i2c_devices(np, i); + of_register_i2c_devices(np, i++); } return 0; |