diff options
Diffstat (limited to 'arch')
21 files changed, 94 insertions, 38 deletions
diff --git a/arch/powerpc/boot/dts/kuroboxHD.dts b/arch/powerpc/boot/dts/kuroboxHD.dts index ec71ab819fee..1c14dcde6838 100644 --- a/arch/powerpc/boot/dts/kuroboxHD.dts +++ b/arch/powerpc/boot/dts/kuroboxHD.dts @@ -60,7 +60,7 @@ XXXX add flash parts, rtc, ?? i2c@80003000 { #address-cells = <1>; #size-cells = <0>; - device_type = "i2c"; + cell-index = <0>; compatible = "fsl-i2c"; reg = <80003000 1000>; interrupts = <5 2>; diff --git a/arch/powerpc/boot/dts/kuroboxHG.dts b/arch/powerpc/boot/dts/kuroboxHG.dts index 32ecd2319928..1b973fa34605 100644 --- a/arch/powerpc/boot/dts/kuroboxHG.dts +++ b/arch/powerpc/boot/dts/kuroboxHG.dts @@ -60,7 +60,7 @@ XXXX add flash parts, rtc, ?? i2c@80003000 { #address-cells = <1>; #size-cells = <0>; - device_type = "i2c"; + cell-index = <0>; compatible = "fsl-i2c"; reg = <80003000 1000>; interrupts = <5 2>; diff --git a/arch/powerpc/boot/dts/lite5200.dts b/arch/powerpc/boot/dts/lite5200.dts index 6731763f0282..23eeeb1fc61e 100644 --- a/arch/powerpc/boot/dts/lite5200.dts +++ b/arch/powerpc/boot/dts/lite5200.dts @@ -284,7 +284,8 @@ }; i2c@3d00 { - device_type = "i2c"; + #address-cells = <1>; + #size-cells = <0>; compatible = "mpc5200-i2c","fsl-i2c"; cell-index = <0>; reg = <3d00 40>; @@ -294,7 +295,8 @@ }; i2c@3d40 { - device_type = "i2c"; + #address-cells = <1>; + #size-cells = <0>; compatible = "mpc5200-i2c","fsl-i2c"; cell-index = <1>; reg = <3d40 40>; diff --git a/arch/powerpc/boot/dts/lite5200b.dts b/arch/powerpc/boot/dts/lite5200b.dts index b540388c608c..f94e073de9a7 100644 --- a/arch/powerpc/boot/dts/lite5200b.dts +++ b/arch/powerpc/boot/dts/lite5200b.dts @@ -300,7 +300,8 @@ }; i2c@3d00 { - device_type = "i2c"; + #address-cells = <1>; + #size-cells = <0>; compatible = "mpc5200b-i2c","mpc5200-i2c","fsl-i2c"; cell-index = <0>; reg = <3d00 40>; @@ -310,7 +311,8 @@ }; i2c@3d40 { - device_type = "i2c"; + #address-cells = <1>; + #size-cells = <0>; compatible = "mpc5200b-i2c","mpc5200-i2c","fsl-i2c"; cell-index = <1>; reg = <3d40 40>; diff --git a/arch/powerpc/boot/dts/mpc8313erdb.dts b/arch/powerpc/boot/dts/mpc8313erdb.dts index 9e7eba973262..d417f1bbff6e 100644 --- a/arch/powerpc/boot/dts/mpc8313erdb.dts +++ b/arch/powerpc/boot/dts/mpc8313erdb.dts @@ -52,7 +52,9 @@ }; i2c@3000 { - device_type = "i2c"; + #address-cells = <1>; + #size-cells = <0>; + cell-index = <0>; compatible = "fsl-i2c"; reg = <3000 100>; interrupts = <e 8>; @@ -61,7 +63,9 @@ }; i2c@3100 { - device_type = "i2c"; + #address-cells = <1>; + #size-cells = <0>; + cell-index = <1>; compatible = "fsl-i2c"; reg = <3100 100>; interrupts = <f 8>; diff --git a/arch/powerpc/boot/dts/mpc832x_mds.dts b/arch/powerpc/boot/dts/mpc832x_mds.dts index c64f3037a13b..f866e81f9368 100644 --- a/arch/powerpc/boot/dts/mpc832x_mds.dts +++ b/arch/powerpc/boot/dts/mpc832x_mds.dts @@ -59,7 +59,7 @@ i2c@3000 { #address-cells = <1>; #size-cells = <0>; - device_type = "i2c"; + cell-index = <0>; compatible = "fsl-i2c"; reg = <3000 100>; interrupts = <e 8>; diff --git a/arch/powerpc/boot/dts/mpc832x_rdb.dts b/arch/powerpc/boot/dts/mpc832x_rdb.dts index 388c8a7012e1..91849dd64223 100644 --- a/arch/powerpc/boot/dts/mpc832x_rdb.dts +++ b/arch/powerpc/boot/dts/mpc832x_rdb.dts @@ -52,7 +52,9 @@ }; i2c@3000 { - device_type = "i2c"; + #address-cells = <1>; + #size-cells = <0>; + cell-index = <0>; compatible = "fsl-i2c"; reg = <3000 100>; interrupts = <e 8>; diff --git a/arch/powerpc/boot/dts/mpc8349emitx.dts b/arch/powerpc/boot/dts/mpc8349emitx.dts index 5072f6d0a46d..c29e4f4a7ae5 100644 --- a/arch/powerpc/boot/dts/mpc8349emitx.dts +++ b/arch/powerpc/boot/dts/mpc8349emitx.dts @@ -51,7 +51,9 @@ }; i2c@3000 { - device_type = "i2c"; + #address-cells = <1>; + #size-cells = <0>; + cell-index = <0>; compatible = "fsl-i2c"; reg = <3000 100>; interrupts = <e 8>; @@ -60,7 +62,9 @@ }; i2c@3100 { - device_type = "i2c"; + #address-cells = <1>; + #size-cells = <0>; + cell-index = <1>; compatible = "fsl-i2c"; reg = <3100 100>; interrupts = <f 8>; diff --git a/arch/powerpc/boot/dts/mpc8349emitxgp.dts b/arch/powerpc/boot/dts/mpc8349emitxgp.dts index 074f7a2ab7e4..6e51d172e4f8 100644 --- a/arch/powerpc/boot/dts/mpc8349emitxgp.dts +++ b/arch/powerpc/boot/dts/mpc8349emitxgp.dts @@ -51,7 +51,9 @@ }; i2c@3000 { - device_type = "i2c"; + #address-cells = <1>; + #size-cells = <0>; + cell-index = <0>; compatible = "fsl-i2c"; reg = <3000 100>; interrupts = <e 8>; @@ -60,7 +62,9 @@ }; i2c@3100 { - device_type = "i2c"; + #address-cells = <1>; + #size-cells = <0>; + cell-index = <1>; compatible = "fsl-i2c"; reg = <3100 100>; interrupts = <f 8>; diff --git a/arch/powerpc/boot/dts/mpc834x_mds.dts b/arch/powerpc/boot/dts/mpc834x_mds.dts index 49363f89cb71..73311e82ab5d 100644 --- a/arch/powerpc/boot/dts/mpc834x_mds.dts +++ b/arch/powerpc/boot/dts/mpc834x_mds.dts @@ -59,7 +59,7 @@ i2c@3000 { #address-cells = <1>; #size-cells = <0>; - device_type = "i2c"; + cell-index = <0>; compatible = "fsl-i2c"; reg = <3000 100>; interrupts = <e 8>; @@ -75,7 +75,7 @@ i2c@3100 { #address-cells = <1>; #size-cells = <0>; - device_type = "i2c"; + cell-index = <1>; compatible = "fsl-i2c"; reg = <3100 100>; interrupts = <f 8>; diff --git a/arch/powerpc/boot/dts/mpc836x_mds.dts b/arch/powerpc/boot/dts/mpc836x_mds.dts index 0b2d2b588daa..8b7d77887503 100644 --- a/arch/powerpc/boot/dts/mpc836x_mds.dts +++ b/arch/powerpc/boot/dts/mpc836x_mds.dts @@ -64,7 +64,7 @@ i2c@3000 { #address-cells = <1>; #size-cells = <0>; - device_type = "i2c"; + cell-index = <0>; compatible = "fsl-i2c"; reg = <3000 100>; interrupts = <e 8>; @@ -80,7 +80,7 @@ i2c@3100 { #address-cells = <1>; #size-cells = <0>; - device_type = "i2c"; + cell-index = <1>; compatible = "fsl-i2c"; reg = <3100 100>; interrupts = <f 8>; diff --git a/arch/powerpc/boot/dts/mpc8540ads.dts b/arch/powerpc/boot/dts/mpc8540ads.dts index 6442a717ec3b..435a2b6e55a1 100644 --- a/arch/powerpc/boot/dts/mpc8540ads.dts +++ b/arch/powerpc/boot/dts/mpc8540ads.dts @@ -63,7 +63,9 @@ }; i2c@3000 { - device_type = "i2c"; + #address-cells = <1>; + #size-cells = <0>; + cell-index = <0>; compatible = "fsl-i2c"; reg = <3000 100>; interrupts = <2b 2>; diff --git a/arch/powerpc/boot/dts/mpc8541cds.dts b/arch/powerpc/boot/dts/mpc8541cds.dts index f3f4d79deb63..101c0b6095b0 100644 --- a/arch/powerpc/boot/dts/mpc8541cds.dts +++ b/arch/powerpc/boot/dts/mpc8541cds.dts @@ -63,7 +63,9 @@ }; i2c@3000 { - device_type = "i2c"; + #address-cells = <1>; + #size-cells = <0>; + cell-index = <0>; compatible = "fsl-i2c"; reg = <3000 100>; interrupts = <2b 2>; diff --git a/arch/powerpc/boot/dts/mpc8544ds.dts b/arch/powerpc/boot/dts/mpc8544ds.dts index 6c608de1fc1b..a81eccae17a8 100644 --- a/arch/powerpc/boot/dts/mpc8544ds.dts +++ b/arch/powerpc/boot/dts/mpc8544ds.dts @@ -64,7 +64,9 @@ }; i2c@3000 { - device_type = "i2c"; + #address-cells = <1>; + #size-cells = <0>; + cell-index = <0>; compatible = "fsl-i2c"; reg = <3000 100>; interrupts = <2b 2>; @@ -72,6 +74,17 @@ dfsrr; }; + i2c@3100 { + #address-cells = <1>; + #size-cells = <0>; + cell-index = <1>; + compatible = "fsl-i2c"; + reg = <3100 100>; + interrupts = <2b 2>; + interrupt-parent = <&mpic>; + dfsrr; + }; + mdio@24520 { #address-cells = <1>; #size-cells = <0>; diff --git a/arch/powerpc/boot/dts/mpc8548cds.dts b/arch/powerpc/boot/dts/mpc8548cds.dts index 69ca5025d972..70358dc0e571 100644 --- a/arch/powerpc/boot/dts/mpc8548cds.dts +++ b/arch/powerpc/boot/dts/mpc8548cds.dts @@ -63,7 +63,9 @@ }; i2c@3000 { - device_type = "i2c"; + #address-cells = <1>; + #size-cells = <0>; + cell-index = <0>; compatible = "fsl-i2c"; reg = <3000 100>; interrupts = <2b 2>; @@ -71,6 +73,17 @@ dfsrr; }; + i2c@3100 { + #address-cells = <1>; + #size-cells = <0>; + cell-index = <1>; + compatible = "fsl-i2c"; + reg = <3100 100>; + interrupts = <2b 2>; + interrupt-parent = <&mpic>; + dfsrr; + }; + mdio@24520 { #address-cells = <1>; #size-cells = <0>; diff --git a/arch/powerpc/boot/dts/mpc8555cds.dts b/arch/powerpc/boot/dts/mpc8555cds.dts index 57029cca32b2..1e8bf4663b06 100644 --- a/arch/powerpc/boot/dts/mpc8555cds.dts +++ b/arch/powerpc/boot/dts/mpc8555cds.dts @@ -63,7 +63,9 @@ }; i2c@3000 { - device_type = "i2c"; + #address-cells = <1>; + #size-cells = <0>; + cell-index = <0>; compatible = "fsl-i2c"; reg = <3000 100>; interrupts = <2b 2>; diff --git a/arch/powerpc/boot/dts/mpc8568mds.dts b/arch/powerpc/boot/dts/mpc8568mds.dts index 54394372b12a..d73e5f165ef8 100644 --- a/arch/powerpc/boot/dts/mpc8568mds.dts +++ b/arch/powerpc/boot/dts/mpc8568mds.dts @@ -74,7 +74,7 @@ i2c@3000 { #address-cells = <1>; #size-cells = <0>; - device_type = "i2c"; + cell-index = <0>; compatible = "fsl-i2c"; reg = <3000 100>; interrupts = <2b 2>; @@ -90,7 +90,7 @@ i2c@3100 { #address-cells = <1>; #size-cells = <0>; - device_type = "i2c"; + cell-index = <1>; compatible = "fsl-i2c"; reg = <3100 100>; interrupts = <2b 2>; diff --git a/arch/powerpc/boot/dts/mpc8572ds.dts b/arch/powerpc/boot/dts/mpc8572ds.dts index 0eb44fb9647d..91d15e8de9b5 100644 --- a/arch/powerpc/boot/dts/mpc8572ds.dts +++ b/arch/powerpc/boot/dts/mpc8572ds.dts @@ -69,7 +69,9 @@ }; i2c@3000 { - device_type = "i2c"; + #address-cells = <1>; + #size-cells = <0>; + cell-index = <0>; compatible = "fsl-i2c"; reg = <3000 100>; interrupts = <2b 2>; @@ -78,7 +80,9 @@ }; i2c@3100 { - device_type = "i2c"; + #address-cells = <1>; + #size-cells = <0>; + cell-index = <1>; compatible = "fsl-i2c"; reg = <3100 100>; interrupts = <2b 2>; diff --git a/arch/powerpc/boot/dts/mpc8610_hpcd.dts b/arch/powerpc/boot/dts/mpc8610_hpcd.dts index 966edf1161a6..e9c444ed922f 100644 --- a/arch/powerpc/boot/dts/mpc8610_hpcd.dts +++ b/arch/powerpc/boot/dts/mpc8610_hpcd.dts @@ -47,10 +47,10 @@ bus-frequency = <0>; i2c@3000 { - device_type = "i2c"; - compatible = "fsl-i2c"; #address-cells = <1>; #size-cells = <0>; + cell-index = <0>; + compatible = "fsl-i2c"; reg = <3000 100>; interrupts = <2b 2>; interrupt-parent = <&mpic>; @@ -58,10 +58,10 @@ }; i2c@3100 { - device_type = "i2c"; - compatible = "fsl-i2c"; #address-cells = <1>; #size-cells = <0>; + cell-index = <1>; + compatible = "fsl-i2c"; reg = <3100 100>; interrupts = <2b 2>; interrupt-parent = <&mpic>; diff --git a/arch/powerpc/boot/dts/mpc8641_hpcn.dts b/arch/powerpc/boot/dts/mpc8641_hpcn.dts index b039f2136c9b..dc0efafd584f 100644 --- a/arch/powerpc/boot/dts/mpc8641_hpcn.dts +++ b/arch/powerpc/boot/dts/mpc8641_hpcn.dts @@ -69,7 +69,9 @@ bus-frequency = <0>; i2c@3000 { - device_type = "i2c"; + #address-cells = <1>; + #size-cells = <0>; + cell-index = <0>; compatible = "fsl-i2c"; reg = <3000 100>; interrupts = <2b 2>; @@ -78,7 +80,9 @@ }; i2c@3100 { - device_type = "i2c"; + #address-cells = <1>; + #size-cells = <0>; + cell-index = <1>; compatible = "fsl-i2c"; reg = <3100 100>; interrupts = <2b 2>; 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; |