DMI detection
Oh, incidently, I thought I read that Alan's DMI stuff writes stuff to .config? It might be much easier to use DMI if we can read his results instead of doing the horrible copy-and-paste stuff which was done in drivers/char/i8k.c.
Phil
Signature · 3 lines
Philip Edelbrock -- IS Manager -- Edge Design, Corvallis, OR [email protected] -- http://www.netroedge.com/~phil PGP F16: 01 D2 FD 01 B5 46 F4 F0 3A 8B 9D 7E 14 7F FB 7A
Quoted 3 lines
I'm going to work on putting DMI detection in i2c-piix4. Any voluteers for doing the same in perl for sensors-detect? (please!)
I know Perl rather good, I will help as much as I can. If the only thing to do is C-to-Perl translation, I'm on it :)
Signature · 2 lines
Jean "Khali" Delvare http://www.ensicaen.ismra.fr/~delvare/
I haven't seen where doing a 'make' will write DMI stuff to .config. But you never know. Not that you can look in .config from a running kernel anyway...
I don't think we have any choice but to copy what we need from dmi_scan.c and put it in piix4.c.
And copy dmidecode.c (that I found on Alan's server and I sent you) and port it to perl and put it in sensors-detect. Yuck.
Actually I think we should take i8k.c and make it a combination bus/chip driver
for our package. THAT would be a good project.
Quoted 12 lines · [email protected] wrote:
Oh, incidently, I thought I read that Alan's DMI stuff writes stuff to .config? It might be much easier to use DMI if we can read his results instead of doing the horrible copy-and-paste stuff which was done in
drivers/char/i8k.c.Phil
--
Philip Edelbrock -- IS Manager -- Edge Design, Corvallis, OR
[email protected] -- http://www.netroedge.com/~phil
PGP F16: 01 D2 FD 01 B5 46 F4 F0 3A 8B 9D 7E 14 7F FB 7A
I'm going to work on putting DMI detection in i2c-piix4. Any voluteers for doing the same in perl for sensors-detect? (please!)
Quoted 27 lines · Mark D. Studebaker
I haven't seen where doing a 'make' will write DMI stuff to .config. But you never know. Not that you can look in .config from a running kernel anyway...
I don't think we have any choice but to copy what we need from
dmi_scan.cand put it inpiix4.c.
And copydmidecode.c(that I found on Alan's server and I sent you) and port it to perl and put it in sensors-detect. Yuck.Actually I think we should take
i8k.cand make it a combination bus/chip driver
for our package. THAT would be a good project.Quoted 12 lines · [email protected] wrote:
Oh, incidently, I thought I read that Alan's DMI stuff writes stuff to .config? It might be much easier to use DMI if we can read his results instead of doing the horrible copy-and-paste stuff which was done in
drivers/char/i8k.c.Phil
--
Philip Edelbrock -- IS Manager -- Edge Design, Corvallis, OR
[email protected] -- http://www.netroedge.com/~phil
PGP F16: 01 D2 FD 01 B5 46 F4 F0 3A 8B 9D 7E 14 7F FB 7A
Great!
I'm taking the code from drivers/char/i8k.c
(which appears unchanged from at least kernels 2.4.17 through 2.5.28) starting at line 502 through lines 662.
You should look at that code, and also at Alan's userspace program dmidecode.c
http://www.domsch.com/linux/patches/dmi/
and decide which is the best place to start for you.
Quoted 10 lines · Jean Delvare
Quoted 3 lines
I'm going to work on putting DMI detection in i2c-piix4. Any voluteers for doing the same in perl for sensors-detect? (please!)
I know Perl rather good, I will help as much as I can. If the only thing to do is C-to-Perl translation, I'm on it :)
--
Jean "Khali" Delvare
http://www.ensicaen.ismra.fr/~delvare/
I think it was intended that DMI be used and availble to other parts of the kernel. Not much (if anything) seems to use it yet, though. I would think Alan would be pleased to make it available for us to hook into (if there isn't already some method). It's also a much cleaner solution than copy-and-pasting all that code.
Phil
Quoted 54 lines · Mark D. Studebaker
I've reconsidered the changes I put in
i2c-piix4.c, which was essentially
a copy of a portion ofdmi_scan.c.
Duplicating 200 lines of code fromdmi_scanwouldn't be accepted as a patch.If the char* array dmi_ident[] at line 145 of
dmi_scan.cwere un-"static"ed,
and if the enum table just above that were moved to a header file, we could access the strings in the array to get the system vendor. Albert, if you can get this small patch accepted, then we are in good shape
to submit clean sensors code as a patch later.I'll move the code I just put into i2c-piix4 into a new
dmi_scanmodule in our package.
This will be used by people with kernels before 2.5.whatever, but it won't be in Albert's kernel patches.
And this module can export the system vendor string somewhere, so that sensors-detect can just insert this module and get the string. Much easier than recoding the whole thing in perl.Then eventually we can enhance the kernel
dmi_scanto export the sensor information
(the SM Bios table contains information on number and location of voltage, temp, and current sensors, and fans).Agreed???
Quoted 22 lines · Mark D. Studebaker
Great!
I'm taking the code fromdrivers/char/i8k.c
(which appears unchanged from at least kernels 2.4.17 through 2.5.28) starting at line 502 through lines 662.You should look at that code, and also at Alan's userspace program
dmidecode.c
http://www.domsch.com/linux/patches/dmi/
and decide which is the best place to start for you.Quoted 10 lines · Jean Delvare
Quoted 3 lines
I'm going to work on putting DMI detection in i2c-piix4. Any voluteers for doing the same in perl for sensors-detect? (please!)
I know Perl rather good, I will help as much as I can. If the only thing to do is C-to-Perl translation, I'm on it :)
--
Jean "Khali" Delvare
http://www.ensicaen.ismra.fr/~delvare/
Signature · 3 lines
Philip Edelbrock -- IS Manager -- Edge Design, Corvallis, OR [email protected] -- http://www.netroedge.com/~phil PGP F16: 01 D2 FD 01 B5 46 F4 F0 3A 8B 9D 7E 14 7F FB 7A
I've reconsidered the changes I put in i2c-piix4.c, which was essentially
a copy of a portion of dmi_scan.c.
Duplicating 200 lines of code from dmi_scan wouldn't be accepted as a patch.
If the char* array dmi_ident[] at line 145 of dmi_scan.c were un-"static"ed,
and if the enum table just above that were moved to a header file, we could access the strings in the array to get the system vendor. Albert, if you can get this small patch accepted, then we are in good shape
to submit clean sensors code as a patch later.
I'll move the code I just put into i2c-piix4 into a new dmi_scan module in our package.
This will be used by people with kernels before 2.5.whatever, but it won't be in Albert's kernel patches.
And this module can export the system vendor string somewhere, so that sensors-detect can just insert this module and get the string. Much easier than recoding the whole thing in perl.
Then eventually we can enhance the kernel dmi_scan to export the sensor information
(the SM Bios table contains information on number and location of voltage, temp, and current sensors, and fans).
Agreed???
Quoted 22 lines · Mark D. Studebaker
Great!
I'm taking the code fromdrivers/char/i8k.c
(which appears unchanged from at least kernels 2.4.17 through 2.5.28) starting at line 502 through lines 662.You should look at that code, and also at Alan's userspace program
dmidecode.c
http://www.domsch.com/linux/patches/dmi/
and decide which is the best place to start for you.Quoted 10 lines · Jean Delvare
Quoted 3 lines
I'm going to work on putting DMI detection in i2c-piix4. Any voluteers for doing the same in perl for sensors-detect? (please!)
I know Perl rather good, I will help as much as I can. If the only thing to do is C-to-Perl translation, I'm on it :)
--
Jean "Khali" Delvare
http://www.ensicaen.ismra.fr/~delvare/