* [lm-sensors] i2c -dev and i2c bus driver
@ 2005-11-03 20:57 Howard Wang
2005-11-04 20:40 ` Rudolf Marek
` (8 more replies)
0 siblings, 9 replies; 10+ messages in thread
From: Howard Wang @ 2005-11-03 20:57 UTC (permalink / raw)
To: lm-sensors
Hi All,
I have got a question about i2c:
is it possible for one i2c bus driver to be used for two i2c busses ?
if yes, then how ?
currently I am using scx200_i2c bus driver and i2c-dev device driver, it
can only detect one bus. the i2c device is microchip 24C04.
thanks for the help.
howard
^ permalink raw reply [flat|nested] 10+ messages in thread
* [lm-sensors] i2c -dev and i2c bus driver
2005-11-03 20:57 [lm-sensors] i2c -dev and i2c bus driver Howard Wang
@ 2005-11-04 20:40 ` Rudolf Marek
2005-11-04 23:55 ` Rudolf Marek
` (7 subsequent siblings)
8 siblings, 0 replies; 10+ messages in thread
From: Rudolf Marek @ 2005-11-04 20:40 UTC (permalink / raw)
To: lm-sensors
Howard Wang wrote:
> Hi All,
>
> I have got a question about i2c:
>
> is it possible for one i2c bus driver to be used for two i2c busses ?
> if yes, then how ?
Yes, all you need to register it to the subsystem. (They can share common functions). Please have a look to i2c-nvidia.c
If you have more questions, just write.
Thanks,
Regards
Rudolf
^ permalink raw reply [flat|nested] 10+ messages in thread
* [lm-sensors] i2c -dev and i2c bus driver
2005-11-03 20:57 [lm-sensors] i2c -dev and i2c bus driver Howard Wang
2005-11-04 20:40 ` Rudolf Marek
@ 2005-11-04 23:55 ` Rudolf Marek
2005-11-07 17:49 ` Howard Wang
` (6 subsequent siblings)
8 siblings, 0 replies; 10+ messages in thread
From: Rudolf Marek @ 2005-11-04 23:55 UTC (permalink / raw)
To: lm-sensors
> Yes, all you need to register it to the subsystem. (They can share common functions). Please have a look to i2c-nvidia.c
> If you have more questions, just write.
I mean i2c-nforce2.c
Sorry,
Rudolf
^ permalink raw reply [flat|nested] 10+ messages in thread
* [lm-sensors] i2c -dev and i2c bus driver
2005-11-03 20:57 [lm-sensors] i2c -dev and i2c bus driver Howard Wang
2005-11-04 20:40 ` Rudolf Marek
2005-11-04 23:55 ` Rudolf Marek
@ 2005-11-07 17:49 ` Howard Wang
2005-11-07 18:00 ` Rudolf Marek
` (5 subsequent siblings)
8 siblings, 0 replies; 10+ messages in thread
From: Howard Wang @ 2005-11-07 17:49 UTC (permalink / raw)
To: lm-sensors
appreciate your help. the i2c bus driver of my system is sc1200 from AMD,
there is i2c bus driver scx200_i2c, I just wonder whether this driver supports
two buses, currently it only talks to one bus on my system. I dont know how
I can make it to talk to the second bus.
regards
howard
-----Original Message-----
From: Rudolf Marek [mailto:r.marek@sh.cvut.cz]
Sent: Fri 11/4/2005 5:55 PM
To: Howard Wang
Cc: lm-sensors@lm-sensors.org
Subject: Re: [lm-sensors] i2c -dev and i2c bus driver
> Yes, all you need to register it to the subsystem. (They can share common functions). Please have a look to i2c-nvidia.c
> If you have more questions, just write.
I mean i2c-nforce2.c
Sorry,
Rudolf
^ permalink raw reply [flat|nested] 10+ messages in thread
* [lm-sensors] i2c -dev and i2c bus driver
2005-11-03 20:57 [lm-sensors] i2c -dev and i2c bus driver Howard Wang
` (2 preceding siblings ...)
2005-11-07 17:49 ` Howard Wang
@ 2005-11-07 18:00 ` Rudolf Marek
2005-11-08 0:55 ` Howard Wang
` (4 subsequent siblings)
8 siblings, 0 replies; 10+ messages in thread
From: Rudolf Marek @ 2005-11-07 18:00 UTC (permalink / raw)
To: lm-sensors
Howard Wang wrote:
> appreciate your help. the i2c bus driver of my system is sc1200 from AMD,
> there is i2c bus driver scx200_i2c, I just wonder whether this driver supports
> two buses, currently it only talks to one bus on my system. I dont know how
> I can make it to talk to the second bus.
Well I dont know the architecture (and today have no time to look deeper) but I can see (in kernel 2.6.14) second i2c driver:
scx200_acb.c
scx200_i2c.c
Maybe it is what you want?
Regards
Rudolf
^ permalink raw reply [flat|nested] 10+ messages in thread
* [lm-sensors] i2c -dev and i2c bus driver
2005-11-03 20:57 [lm-sensors] i2c -dev and i2c bus driver Howard Wang
` (3 preceding siblings ...)
2005-11-07 18:00 ` Rudolf Marek
@ 2005-11-08 0:55 ` Howard Wang
2005-11-08 16:47 ` Rudolf Marek
` (3 subsequent siblings)
8 siblings, 0 replies; 10+ messages in thread
From: Howard Wang @ 2005-11-08 0:55 UTC (permalink / raw)
To: lm-sensors
-----Original Message-----
From: Howard Wang
Sent: Mon 11/7/2005 12:31 PM
To: lm-sensors@lm-sensors.org
Cc:
Subject: RE: [lm-sensors] i2c -dev and i2c bus driver
Hi,
Well I dont know the architecture (and today have no time to look deeper) but I can see (in kernel 2.6.14) second i2c driver:
scx200_acb.c
scx200_i2c.c
Maybe it is what you want?
yes, that's what I loaded after booing and using i2c-dev driver to talk to
our i2c device, for the devices connnected to the ACB 2 of superIO from the
microporcessor, every thing works. however, for the device, connected to
ACB 1 of superIO, I won't be able to talk to them.
any suggestions.
really appreciate your help.
howard
Regards
Rudolf
^ permalink raw reply [flat|nested] 10+ messages in thread
* [lm-sensors] i2c -dev and i2c bus driver
2005-11-03 20:57 [lm-sensors] i2c -dev and i2c bus driver Howard Wang
` (4 preceding siblings ...)
2005-11-08 0:55 ` Howard Wang
@ 2005-11-08 16:47 ` Rudolf Marek
2005-11-09 15:34 ` Howard Wang
` (2 subsequent siblings)
8 siblings, 0 replies; 10+ messages in thread
From: Rudolf Marek @ 2005-11-08 16:47 UTC (permalink / raw)
To: lm-sensors
> yes, that's what I loaded after booing and using i2c-dev driver to talk to
> our i2c device, for the devices connnected to the ACB 2 of superIO from the
> microporcessor, every thing works. however, for the device, connected to
> ACB 1 of superIO, I won't be able to talk to them.
Hmm bad is that I dont know the hardware.
But from the driver i can see:
for (i = 0; i < MAX_DEVICES; ++i) {
if (base[i] > 0)
rc = scx200_acb_create(base[i], i);
}
And there are two base defined.
So this could create two busses.
When you modprobe i2c-dev and the scx driver you should see
in
i2cdump -l
Listed two ACB busses
Do you see them?
If so I would suggest:
1) plug your device to ACB 2 where it works
do: i2cdetect (put acb2 bus number here)
i2cdump (put acb2 bus number here) 0xyourdeviceaddr
2) repeat with plugged to ACB1
Please post results here. Also, please point me to some documenattion of ACCESS bus... I'm really very short with my time...
Thanks
Regards
Rudolf
^ permalink raw reply [flat|nested] 10+ messages in thread
* [lm-sensors] i2c -dev and i2c bus driver
2005-11-03 20:57 [lm-sensors] i2c -dev and i2c bus driver Howard Wang
` (5 preceding siblings ...)
2005-11-08 16:47 ` Rudolf Marek
@ 2005-11-09 15:34 ` Howard Wang
2005-11-11 0:43 ` Howard Wang
2005-11-11 13:02 ` Rudolf Marek
8 siblings, 0 replies; 10+ messages in thread
From: Howard Wang @ 2005-11-09 15:34 UTC (permalink / raw)
To: lm-sensors
I sent you an email with the sc1200 datasheet attached, unfortunately, it bounced back due to large
size. since I don't have access to the target today, I just briefly reply answer your questions and
tomorrow I'll try to post more detailed info from the target as well as the datasheet.
>Hmm bad is that I dont know the hardware.
But from the driver i can see:
for (i = 0; i < MAX_DEVICES; ++i) {
if (base[i] > 0)
rc = scx200_acb_create(base[i], i);
}
And there are two base defined.
So this could create two busses.
When you modprobe i2c-dev and the scx driver you should see
in
i2cdump -l
Listed two ACB busses
Do you see them?
No. I only saw one: i2c-0 with the bus type of unknown. but this doesn't matter. the smbus just works fine
with i2cdump 0 0x50 and 0x51.
i2cdump -l
Installed I2C busses:
i2c-0 unknown netSemi sc1200
>
If so I would suggest:
1) plug your device to ACB 2 where it works
do: i2cdetect (put acb2 bus number here)
i2cdump (put acb2 bus number here) 0xyourdeviceaddr
this works fine. no problem.
>
2) repeat with plugged to ACB1
i2cdump 1 0x57 ( a same type of device is connected to bus 1 with A0,A1,A2 pulled to high )
return with open error. no such device. for i2c-1. ( the i2c node: 0 to32 under /dev/ do exist).
Error: Could not open file '/dev/i2c-1': No such device
one question for you: if let's say:
the acb1 has been configured to use different protocol other than acb2, how can I find out and reconfigure
the acb1 to be the same as acb2 ?
appreciated your help.
howard
^ permalink raw reply [flat|nested] 10+ messages in thread
* [lm-sensors] i2c -dev and i2c bus driver
2005-11-03 20:57 [lm-sensors] i2c -dev and i2c bus driver Howard Wang
` (6 preceding siblings ...)
2005-11-09 15:34 ` Howard Wang
@ 2005-11-11 0:43 ` Howard Wang
2005-11-11 13:02 ` Rudolf Marek
8 siblings, 0 replies; 10+ messages in thread
From: Howard Wang @ 2005-11-11 0:43 UTC (permalink / raw)
To: lm-sensors
Hi Rudolf,
I got the scx200_i2c driver working on the second i2c bus, which is acb1,
however, when I use i2cset and i2cdump, it seems that only 128 bytes is
accessible, it repeats after 128 bytes, while my device is:
microchip 24AA128 which is 128K bits (16K bytes). see attached log:
in fact, I just set the first 10 bytes and it repeats after 128 bytes.
any suggestions ?
thanks
howard
*** ***
/usr/test # i2cdump -y 0 0x57
No size specified (using byte-data access)
0 1 2 3 4 5 6 7 8 9 a b c d e f 0123456789abcdef
00: 43 69 72 ff 45 45 50 52 4f 4d ff ff ff ff ff 42 Cir.EEPROM.....B
10: ff ff ff ff ff ff 01 ff ff ff ff ff ff ff ff ff ......?.........
20: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ................
30: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ................
40: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ................
50: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ................
60: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ................
70: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ................
80: 43 69 72 ff 45 45 50 52 4f 4d ff ff ff ff ff 42 Cir.EEPROM.....B
90: ff ff ff ff ff ff 01 ff ff ff ff ff ff ff ff ff ......?.........
a0: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ................
b0: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ................
c0: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ................
d0: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ................
e0: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ................
f0: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ................
*** ***
-----Original Message-----
From: Rudolf Marek [mailto:r.marek@sh.cvut.cz]
Sent: Tue 11/8/2005 10:47 AM
To: Howard Wang
Cc: lm-sensors@lm-sensors.org
Subject: Re: [lm-sensors] i2c -dev and i2c bus driver
> yes, that's what I loaded after booing and using i2c-dev driver to talk to
> our i2c device, for the devices connnected to the ACB 2 of superIO from the
> microporcessor, every thing works. however, for the device, connected to
> ACB 1 of superIO, I won't be able to talk to them.
Hmm bad is that I dont know the hardware.
But from the driver i can see:
for (i = 0; i < MAX_DEVICES; ++i) {
if (base[i] > 0)
rc = scx200_acb_create(base[i], i);
}
And there are two base defined.
So this could create two busses.
When you modprobe i2c-dev and the scx driver you should see
in
i2cdump -l
Listed two ACB busses
Do you see them?
If so I would suggest:
1) plug your device to ACB 2 where it works
do: i2cdetect (put acb2 bus number here)
i2cdump (put acb2 bus number here) 0xyourdeviceaddr
2) repeat with plugged to ACB1
Please post results here. Also, please point me to some documenattion of ACCESS bus... I'm really very short with my time...
Thanks
Regards
Rudolf
^ permalink raw reply [flat|nested] 10+ messages in thread
* [lm-sensors] i2c -dev and i2c bus driver
2005-11-03 20:57 [lm-sensors] i2c -dev and i2c bus driver Howard Wang
` (7 preceding siblings ...)
2005-11-11 0:43 ` Howard Wang
@ 2005-11-11 13:02 ` Rudolf Marek
8 siblings, 0 replies; 10+ messages in thread
From: Rudolf Marek @ 2005-11-11 13:02 UTC (permalink / raw)
To: lm-sensors
Howard Wang wrote:
> Hi Rudolf,
>
> I got the scx200_i2c driver working on the second i2c bus, which is acb1,
> however, when I use i2cset and i2cdump, it seems that only 128 bytes is
> accessible, it repeats after 128 bytes, while my device is:
> microchip 24AA128 which is 128K bits (16K bytes). see attached log:
> in fact, I just set the first 10 bytes and it repeats after 128 bytes.
>
> any suggestions ?
I'm in hury, must go back to my hometown, so just quick note before I leave:
Perhaps it uses two bytes addressing. You will need special driver for it
Hoever some driver that works for 16KBit eeproms is here.
(somewhere in this thread)
http://lists.lm-sensors.org/pipermail/lm-sensors/2005-July/012987.html
Maybe you can take a look and extend it to your needs. I can take a look ttoday in evening or
at weekend.
Regards
Rudolf
^ permalink raw reply [flat|nested] 10+ messages in thread
end of thread, other threads:[~2005-11-11 13:02 UTC | newest]
Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-11-03 20:57 [lm-sensors] i2c -dev and i2c bus driver Howard Wang
2005-11-04 20:40 ` Rudolf Marek
2005-11-04 23:55 ` Rudolf Marek
2005-11-07 17:49 ` Howard Wang
2005-11-07 18:00 ` Rudolf Marek
2005-11-08 0:55 ` Howard Wang
2005-11-08 16:47 ` Rudolf Marek
2005-11-09 15:34 ` Howard Wang
2005-11-11 0:43 ` Howard Wang
2005-11-11 13:02 ` Rudolf Marek
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.