TI:OMAP: [PATCH 2/7] Enable I2C bus switching
Quoted 33 lines · Khasim Syed Mohammed
From
9bb1c3501c8f098dac6e224c99e409ebf92b0ab9Mon Sep 17 00:00:00 2001
From: Syed Mohammed Khasim <[email protected]>
Date: Mon, 18 Jan 2010 18:11:14 +0530
Subject: [PATCH] Enable I2C bus switchingOMAP3 supports Multiple I2C channels, this patch allows us to use i2c dev <bus no> command to switch between busses.
Signed-off-by Syed Mohammed Khasim <[email protected]>Acked-by Heiko Schocher <[email protected]>--- drivers/i2c/omap24xx_i2c.c | 5 +++++ include/configs/omap3_beagle.h | 6 ++++++ 2 files changed, 11 insertions(+), 0 deletions(-)drivers/i2c/omap24xx_i2c.c +5
-0@@ -435,3 +435,8 @@ int i2c_set_bus_num(unsigned int bus)return 0 ; } + +int i2c_get_bus_num (void ) +{ +return (int ) current_bus; +}include/configs/omap3_beagle.h +0
-0
include/configs/omap3_beagle.h line 107
Quoted 8 lines
include/configs/omap3_beagle.h +5
-0@@ -100,6 +100,12 @@/* DDR - I use Micron DDR */ #define CONFIG_OMAP3_MICRON_DDR 1 +/* Enable Multi Bus support for I2C */ +#define CONFIG_I2C_MULTI_BUS 1 + +/* Probe all devices */ +#define CONFIG_SYS_I2C_NOPROBES {0x0, 0x0}
Most/All of the configs I reviewed set the addr element to a valid address. I do not believe 0 is a valid address on omap. If the intent is a double negative
{0, 0} == probe all
Then add a comment.
Tom
Quoted 39 lines · Tom
Quoted 38 lines · Khasim Syed Mohammed
From
9bb1c3501c8f098dac6e224c99e409ebf92b0ab9Mon Sep 17 00:00:00 2001
From: Syed Mohammed Khasim <[email protected]>
Date: Mon, 18 Jan 2010 18:11:14 +0530
Subject: [PATCH] Enable I2C bus switchingOMAP3 supports Multiple I2C channels, this patch allows us to use i2c dev <bus no> command to switch between busses.
Signed-off-by Syed Mohammed Khasim <[email protected]>Acked-by Heiko Schocher <[email protected]>---
?drivers/i2c/omap24xx_i2c.c ? ? | ? ?5 +++++ ?include/configs/omap3_beagle.h | ? ?6 ++++++ ?2 files changed, 11 insertions(+), 0 deletions(-)drivers/i2c/omap24xx_i2c.c +5
-0@@ -435,3 +435,8 @@ int i2c_set_bus_num(unsigned int bus) ? ? ? ?return 0; ?} + +int i2c_get_bus_num (void ) +{ + ? ? ? return (int) current_bus; +}include/configs/omap3_beagle.h +0
-0@@ -100,6 +100,12 @@?/* DDR - I use Micron DDR */
?#defineCONFIG_OMAP3_MICRON_DDR? ? ? ? ? ? ? ?1
Quoted 12 lines
include/configs/omap3_beagle.h
Quoted 5 lines
include/configs/omap3_beagle.h +5
-0+/* Enable Multi Bus support for I2C */ +#define CONFIG_I2C_MULTI_BUS ? ? ? ? ? 1 + +/* Probe all devices */ +#define CONFIG_SYS_I2C_NOPROBES ? ? ? ? ? ? ? ?{0x0, 0x0}Most/All of the configs I reviewed set the addr element to a valid address. ?I do not believe 0 is a valid address on omap. ?If the intent is a double negative
{0, 0} == probe all
Then add a comment.
I thought I already added a comment ,
Quoted 1 line
Quoted 1 line
+/* Probe all devices */
What more are you expecting. please print ...
Regards,
Khasim
Quoted 50 lines · Khasim Syed Mohammed
Quoted 38 lines · Tom
Quoted 37 lines · Khasim Syed Mohammed
From
9bb1c3501c8f098dac6e224c99e409ebf92b0ab9Mon Sep 17 00:00:00 2001
From: Syed Mohammed Khasim <[email protected]>
Date: Mon, 18 Jan 2010 18:11:14 +0530
Subject: [PATCH] Enable I2C bus switchingOMAP3 supports Multiple I2C channels, this patch allows us to use i2c dev <bus no> command to switch between busses.
Signed-off-by Syed Mohammed Khasim <[email protected]>Acked-by Heiko Schocher <[email protected]>--- drivers/i2c/omap24xx_i2c.c | 5 +++++ include/configs/omap3_beagle.h | 6 ++++++ 2 files changed, 11 insertions(+), 0 deletions(-)drivers/i2c/omap24xx_i2c.c +5
-0@@ -435,3 +435,8 @@ int i2c_set_bus_num(unsigned int bus)return 0 ; } + +int i2c_get_bus_num (void ) +{ +return (int ) current_bus; +}include/configs/omap3_beagle.h +0
-0@@ -100,6 +100,12 @@/* DDR - I use Micron DDR */ #define CONFIG_OMAP3_MICRON_DDR 1Quoted 11 lines
include/configs/omap3_beagle.h line 107
Quoted 5 lines
include/configs/omap3_beagle.h +5
-0+/* Enable Multi Bus support for I2C */ +#define CONFIG_I2C_MULTI_BUS 1 + +/* Probe all devices */ +#define CONFIG_SYS_I2C_NOPROBES {0x0, 0x0}Most/All of the configs I reviewed set the addr element to a valid address. I do not believe 0 is a valid address on omap. If the intent is a double negative
{0, 0} == probe all
Then add a comment.
Quoted 4 lines
I thought I already added a comment ,
Quoted 1 line
include/configs/omap3_beagle.h line 108
Quoted 1 line
include/configs/omap3_beagle.h +1
-0+/* Probe all devices */ What more are you expecting. please print ...
Sorry.
I missed that.
This is fine.
Tom
Quoted 3 lines
Regards,
Khasim
Quoted 37 lines · Tom
Quoted 36 lines · Khasim Syed Mohammed
From
9bb1c3501c8f098dac6e224c99e409ebf92b0ab9Mon Sep 17 00:00:00 2001
From: Syed Mohammed Khasim<[email protected]>
Date: Mon, 18 Jan 2010 18:11:14 +0530
Subject: [PATCH] Enable I2C bus switchingOMAP3 supports Multiple I2C channels, this patch allows us to use i2c dev<bus no> command to switch between busses.
Signed-off-by Syed Mohammed Khasim<[email protected]>Acked-by Heiko Schocher<[email protected]>--- drivers/i2c/omap24xx_i2c.c | 5 +++++ include/configs/omap3_beagle.h | 6 ++++++ 2 files changed, 11 insertions(+), 0 deletions(-)drivers/i2c/omap24xx_i2c.c +5
-0@@ -435,3 +435,8 @@ int i2c_set_bus_num(unsigned int bus)return 0 ; } + +int i2c_get_bus_num (void ) +{ +return (int ) current_bus; +}include/configs/omap3_beagle.h +0
-0@@ -100,6 +100,12 @@/* DDR - I use Micron DDR */ #define CONFIG_OMAP3_MICRON_DDR 1
Quoted 11 lines
include/configs/omap3_beagle.h line 107
Quoted 5 lines
include/configs/omap3_beagle.h +5
-0+/* Enable Multi Bus support for I2C */ +#define CONFIG_I2C_MULTI_BUS 1 + +/* Probe all devices */ +#define CONFIG_SYS_I2C_NOPROBES {0x0, 0x0}Most/All of the configs I reviewed set the addr element to a valid address. I do not believe 0 is a valid address on omap. If the intent is a double negative
{0, 0} == probe all
Then add a comment.
I would fix this, but I have no idea what to add :( Any hint?
Dirk
Dirk,
Quoted 52 lines · Dirk Behme
Quoted 38 lines · Tom
Quoted 36 lines · Khasim Syed Mohammed
From 9bb1c3501c8f098dac6e224c99e409ebf92b0ab9 Mon Sep 17 00:00:00 2001From: Syed Mohammed Khasim<[email protected]>
Date: Mon, 18 Jan 2010 18:11:14 +0530
Subject: [PATCH] Enable I2C bus switchingOMAP3 supports Multiple I2C channels, this patch allows
us to use i2c dev<bus no> command to switch between busses.Signed-off-by Syed Mohammed Khasim<[email protected]>Acked-by Heiko Schocher<[email protected]>--- drivers/i2c/omap24xx_i2c.c | 5 +++++ include/configs/omap3_beagle.h | 6 ++++++ 2 files changed, 11 insertions(+), 0 deletions(-)drivers/i2c/omap24xx_i2c.c +5
-0@@ -435,3 +435,8 @@ int i2c_set_bus_num(unsigned int bus)return 0 ; } + +int i2c_get_bus_num (void ) +{ +return (int ) current_bus; +}include/configs/omap3_beagle.h +0
-0@@ -100,6 +100,12 @@/* DDR - I use Micron DDR */ #define CONFIG_OMAP3_MICRON_DDR 1Quoted 12 lines
include/configs/omap3_beagle.h line 108
Quoted 6 lines
include/configs/omap3_beagle.h +5
-0+/* Enable Multi Bus support for I2C */ +#define CONFIG_I2C_MULTI_BUS 1 + +/* Probe all devices */ +#define CONFIG_SYS_I2C_NOPROBES {0x0, 0x0}Most/All of the configs I reviewed set the addr element to a valid address. I do not believe 0 is a valid address on omap. If the intent is a double negative
{0, 0} == probe all
Then add a comment.
Quoted 3 lines
I would fix this, but I have no idea what to add :( Any hint?
CONFIG_SYS_I2C_NOPROBES doesn't have to be defined. It's there as a convenience in case there are devices that you don't want to be included when probing the bus. If there's nothing you want to skip, don't define it.
Quoted 3 lines
Dirk
_____
regards,
Ben
Syed Mohammed
Quoted 61 lines · Ben Warren
Dirk,
Quoted 58 lines · Dirk Behme
Quoted 54 lines · Tom
Quoted 39 lines · Khasim Syed Mohammed
? From
9bb1c3501c8f098dac6e224c99e409ebf92b0ab9Mon Sep 17 00:00:00 2001
From: Syed Mohammed Khasim<[email protected]>
Date: Mon, 18 Jan 2010 18:11:14 +0530
Subject: [PATCH] Enable I2C bus switchingOMAP3 supports Multiple I2C channels, this patch allows us to use i2c dev<bus no> ? command to switch between busses.
Signed-off-by Syed Mohammed Khasim<[email protected]>Acked-by Heiko Schocher<[email protected]>---
?drivers/i2c/omap24xx_i2c.c? ? | ? ?5 +++++ ?include/configs/omap3_beagle.h| ? ?6 ++++++ ? 2 files changed, 11 insertions(+), 0 deletions(-)drivers/i2c/omap24xx_i2c.c +5
-0@@ -435,3 +435,8 @@ int i2c_set_bus_num(unsigned int bus) ? ? ? ?return 0; ? } + +int i2c_get_bus_num (void ) +{ + ? ? ? return (int) current_bus; +}include/configs/omap3_beagle.h +0
-0@@ -100,6 +100,12 @@? /* DDR - I use Micron DDR */
? #defineCONFIG_OMAP3_MICRON_DDR? ? ? ? ? ? ?1include/configs/omap3_beagle.h
Quoted 5 lines
include/configs/omap3_beagle.h +5
-0+/* Enable Multi Bus support for I2C */ +#define CONFIG_I2C_MULTI_BUS ? ? ? ? ? 1 + +/* Probe all devices */ +#define CONFIG_SYS_I2C_NOPROBES ? ? ? ? ? ? ? ?{0x0, 0x0}Most/All of the configs I reviewed set the addr element to a valid address. ?I do not believe 0 is a valid address on omap. ?If the intent is a double negative
{0, 0} == probe all
Then add a comment.
Quoted 8 lines
Quoted 3 lines
I would fix this, but I have no idea what to add :( Any hint?
CONFIG_SYS_I2C_NOPROBESdoesn't have to be defined. ?It's there as a convenience in case there are devices that you don't want to be included when probing the bus. ?If there's nothing you want to skip, don't define it.Quoted 1 line
With out this option enabled it fails to compile for Multi bus I2C support
More over, this patch is already accepted and has nothing more to do. May be Tom is waiting for a re-submission along with other patches.
May be we can post only the beagle rev and I2C patch first.
Regards,
Khasim
Quoted 57 lines · Khasim
Quoted 56 lines · Ben Warren
Dirk,
Quoted 53 lines · Dirk Behme
Quoted 51 lines · Tom
Quoted 34 lines · Khasim Syed Mohammed
From
9bb1c3501c8f098dac6e224c99e409ebf92b0ab9Mon Sep 17 00:00:00 2001
From: Syed Mohammed Khasim<[email protected]>
Date: Mon, 18 Jan 2010 18:11:14 +0530
Subject: [PATCH] Enable I2C bus switchingOMAP3 supports Multiple I2C channels, this patch allows
us to use i2c dev<bus no> command to switch between busses.Signed-off-by Syed Mohammed Khasim<[email protected]>Acked-by Heiko Schocher<[email protected]>--- drivers/i2c/omap24xx_i2c.c | 5 +++++ include/configs/omap3_beagle.h | 6 ++++++ 2 files changed, 11 insertions(+), 0 deletions(-)drivers/i2c/omap24xx_i2c.c +5
-0@@ -435,3 +435,8 @@ int i2c_set_bus_num(unsigned int bus)return 0 ; } + +int i2c_get_bus_num (void ) +{ +return (int ) current_bus; +}include/configs/omap3_beagle.h +0
-0include/configs/omap3_beagle.h line 108
Quoted 9 lines
include/configs/omap3_beagle.h +5
-0@@ -100,6 +100,12 @@/* DDR - I use Micron DDR */ #define CONFIG_OMAP3_MICRON_DDR 1 +/* Enable Multi Bus support for I2C */ +#define CONFIG_I2C_MULTI_BUS 1 + +/* Probe all devices */ +#define CONFIG_SYS_I2C_NOPROBES {0x0, 0x0}Most/All of the configs I reviewed set the addr element to a valid address. I do not believe 0 is a valid address on omap. If the intent is a double negative
{0, 0} == probe all
Then add a comment.
Quoted 9 lines
Quoted 6 lines
Quoted 3 lines
I would fix this, but I have no idea what to add :( Any hint?
CONFIG_SYS_I2C_NOPROBESdoesn't have to be defined. It's there as a convenience in case there are devices that you don't want to be included when probing the bus. If there's nothing you want to skip, don't define it.With out this option enabled it fails to compile for Multi bus I2C support
I had reservations about the CONFIG_SYS_I2C_NOPROBES being noop-ed. Maybe the multibus support needs to be improved?
Quoted 3 lines
More over, this patch is already accepted and has nothing more to do. May be Tom is waiting for a re-submission along with other patches.
This was part of a patch set.
I was expecting a rev of the whole patch set.
Quoted 1 line
May be we can post only the beagle rev and I2C patch first.
If you are waiting on a rev of the patchset, you may break the patchset into its logical parts.
Given the late comment on the i2c patch, it may be best to break the Beagle rev from the i2c.
Tom
Quoted 7 lines
Regards,
Khasim
_______________________________________________
U-Boot mailing list
U-Boot at lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot
Syed,
Quoted 67 lines · Khasim
Quoted 65 lines · Ben Warren
Dirk,
Quoted 61 lines · Dirk Behme
Quoted 40 lines · Tom
Quoted 37 lines · Khasim Syed Mohammed
From 9bb1c3501c8f098dac6e224c99e409ebf92b0ab9 Mon Sep 17 00:00:00 2001From: Syed Mohammed Khasim<[email protected]>
Date: Mon, 18 Jan 2010 18:11:14 +0530
Subject: [PATCH] Enable I2C bus switchingOMAP3 supports Multiple I2C channels, this patch allows
us to use i2c dev<bus no> command to switch between busses.Signed-off-by Syed Mohammed Khasim<[email protected]>Acked-by Heiko Schocher<[email protected]>--- drivers/i2c/omap24xx_i2c.c | 5 +++++ include/configs/omap3_beagle.h | 6 ++++++ 2 files changed, 11 insertions(+), 0 deletions(-)drivers/i2c/omap24xx_i2c.c +5
-0@@ -435,3 +435,8 @@ int i2c_set_bus_num(unsigned int bus)return 0 ; } + +int i2c_get_bus_num (void ) +{ +return (int ) current_bus; +}include/configs/omap3_beagle.h +0
-0@@ -100,6 +100,12 @@/* DDR - I use Micron DDR */ #define CONFIG_OMAP3_MICRON_DDR 1Quoted 14 lines
include/configs/omap3_beagle.h line 109
Quoted 7 lines
include/configs/omap3_beagle.h +5
-0+/* Enable Multi Bus support for I2C */ +#define CONFIG_I2C_MULTI_BUS 1 + +/* Probe all devices */ +#define CONFIG_SYS_I2C_NOPROBES {0x0, 0x0}Most/All of the configs I reviewed set the addr element to a valid address. I do not believe 0 is a valid address on omap. If the intent is a double negative
{0, 0} == probe all
Then add a comment.I would fix this, but I have no idea what to add :( Any hint?
Quoted 8 lines
Quoted 5 lines
CONFIG_SYS_I2C_NOPROBESdoesn't have to be defined. It's there as a convenience in case there are devices that you don't want to be included when probing the bus. If there's nothing you want to skip, don't define it.Quoted 1 line
With out this option enabled it fails to compile for Multi bus I2C support
Then there's something wrong with this submission. I can build any in-tree board with MULTI_BUS support with and without the NOPROBES list. There's no reason why they should be coupled.
Quoted 8 lines
More over, this patch is already accepted and has nothing more to do. May be Tom is waiting for a re-submission along with other patches.
May be we can post only the beagle rev and I2C patch first.
Regards,
Khasim
regards,
Ben
Quoted 66 lines · Khasim
Quoted 65 lines · Ben Warren
Dirk,
Quoted 61 lines · Dirk Behme
Quoted 41 lines · Tom
Quoted 38 lines · Khasim Syed Mohammed
From 9bb1c3501c8f098dac6e224c99e409ebf92b0ab9 Mon Sep 17 00:00:00 2001From: Syed Mohammed Khasim<[email protected]>
Date: Mon, 18 Jan 2010 18:11:14 +0530
Subject: [PATCH] Enable I2C bus switchingOMAP3 supports Multiple I2C channels, this patch allows
us to use i2c dev<bus no> command to switch between busses.Signed-off-by Syed Mohammed Khasim<[email protected]>Acked-by Heiko Schocher<[email protected]>--- drivers/i2c/omap24xx_i2c.c | 5 +++++ include/configs/omap3_beagle.h | 6 ++++++ 2 files changed, 11 insertions(+), 0 deletions(-)drivers/i2c/omap24xx_i2c.c +5
-0@@ -435,3 +435,8 @@ int i2c_set_bus_num(unsigned int bus)return 0 ; } + +int i2c_get_bus_num (void ) +{ +return (int ) current_bus; +}include/configs/omap3_beagle.h +0
-0@@ -100,6 +100,12 @@/* DDR - I use Micron DDR */ #define CONFIG_OMAP3_MICRON_DDR 1Quoted 13 lines
include/configs/omap3_beagle.h line 108
Quoted 6 lines
include/configs/omap3_beagle.h +5
-0+/* Enable Multi Bus support for I2C */ +#define CONFIG_I2C_MULTI_BUS 1 + +/* Probe all devices */ +#define CONFIG_SYS_I2C_NOPROBES {0x0, 0x0}Most/All of the configs I reviewed set the addr element to a valid address. I do not believe 0 is a valid address on omap. If the intent is a double negative
{0, 0} == probe all
Then add a comment.I would fix this, but I have no idea what to add :( Any hint?
Quoted 6 lines
Quoted 4 lines
CONFIG_SYS_I2C_NOPROBESdoesn't have to be defined. It's there as a convenience in case there are devices that you don't want to be included when probing the bus. If there's nothing you want to skip, don't define it.Quoted 1 line
With out this option enabled it fails to compile for Multi bus I2C support
Hmm, I removed CONFIG_SYS_I2C_NOPROBES as proposed by Ben and I haven't observed any warning compiling my three patches
http://lists.denx.de/pipermail/u-boot/2010-February/067541.html
Quoted 1 line
More over, this patch is already accepted and has nothing more to do.
I'm not sure, but there seems to be a compilation warning in 2/7 or 3/7. At least in the unmodified ones. The three patches I sent (see above) are compiling fine now, though.
Best regards
Dirk