RE: [U-Boot-Users] Using a second I2C interface

On May 12, 2006, at 9:36 AM, Ben Warren wrote:
Hello,
The CPU I'm using (MPC8349) has two hardware I2C interfaces, and I'd like to access the second one in U-boot. Implementing this looks easy to me, but I don't want to reinvent the wheel if it's already been done elsewhere. Has anyone done this? If not, I'll follow up with a proposal.
Depending on what you want to do, you can cheat and just change the pointer to the 2nd interface. If you want something more full featured up to the command level then I think some discussion would be required on how the commands should work for specifying which controller to use.
- kumar
OK, just as a suggestion how about an optional suffix on all the I2C commands. Ex:
iprobe.2 -- discover valid I2C interfaces on controller #2.
imw.0 (or just imw) -- memory write to address on controller #0 (or the only controller in most cases).
Seems like it wouldn't break anything to specify the controller this way.
Marc W. Howard

In message 91B22F93A880FA48879475E134D6F0BE028DDE1C@CA1EXCLV02.adcorp.kla-tencor.com you wrote:
OK, just as a suggestion how about an optional suffix on all the I2C commands. Ex:
No, I don't like this. Please see my previous suggestion. It seems to be more in line with existing commands.
Best regards,
Wolfgang Denk

Marc,
I'm going to implement something similar to what you've suggested, but like this:
iprobe <chip>[.1, .2]...
instead of
iprobe[.1, .2] <chip> ...
This 2-controller support will be conditionally compiled if CONFIG_I2C_2_CTRLS is defined. I should have some code to share this afternoon.
regards, Ben
On Fri, 2006-05-12 at 12:37 -0700, Howard, Marc wrote:
On May 12, 2006, at 9:36 AM, Ben Warren wrote:
Hello,
The CPU I'm using (MPC8349) has two hardware I2C interfaces, and I'd like to access the second one in U-boot. Implementing this looks easy to me, but I don't want to reinvent the wheel if it's already been done elsewhere. Has anyone done this? If not, I'll follow up with a proposal.
Depending on what you want to do, you can cheat and just change the pointer to the 2nd interface. If you want something more full featured up to the command level then I think some discussion would be required on how the commands should work for specifying which controller to use.
- kumar
OK, just as a suggestion how about an optional suffix on all the I2C commands. Ex:
iprobe.2 -- discover valid I2C interfaces on controller #2.
imw.0 (or just imw) -- memory write to address on controller #0 (or the only controller in most cases).
Seems like it wouldn't break anything to specify the controller this way.
Marc W. Howard
Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid%120709&bid&3057&... _______________________________________________ U-Boot-Users mailing list U-Boot-Users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/u-boot-users
participants (3)
-
Ben Warren
-
Howard, Marc
-
Wolfgang Denk