Jean Delvare
8afee51d60
prog/dump/*: More robust user input handling.
...
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@4256 7894878c-1315-0410-8ee3-d5d059ff63e0
2006-12-09 19:20:00 +00:00
Jean Delvare
91c0a32585
Less confusing algorithm names. We'll drop this field soon anyway.
...
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@4240 7894878c-1315-0410-8ee3-d5d059ff63e0
2006-11-14 13:06:35 +00:00
Jean Delvare
7e11801913
The I2C_FUNCS ioctl expects an unsigned long.
...
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@4230 7894878c-1315-0410-8ee3-d5d059ff63e0
2006-11-10 09:22:12 +00:00
Rudolf Marek
c9bd83748b
Fix the homepage address
...
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@4157 7894878c-1315-0410-8ee3-d5d059ff63e0
2006-09-17 21:01:35 +00:00
Jean Delvare
e5d21141d6
Increase max bank (or logical device) number from 15 to 31, as 20 was seen
...
in some chips (PC87427.)
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@4151 7894878c-1315-0410-8ee3-d5d059ff63e0
2006-09-06 15:51:26 +00:00
Jean Delvare
e554f90d33
Rewrite the bank switching code in a slightly different way to keep
...
some compilers quiet.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@4094 7894878c-1315-0410-8ee3-d5d059ff63e0
2006-08-12 21:02:54 +00:00
Jean Delvare
4c211d81d9
prog/dump/*.c, prog/detect/*.c: Handle possible error in fgets().
...
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@4080 7894878c-1315-0410-8ee3-d5d059ff63e0
2006-08-01 09:46:50 +00:00
Jean Delvare
49a745af33
Add a new mode W. It uses SMBus Read Word transactions as mode w
...
does, but it only triggers a transaction on even register addresses,
relying on the target chip to increment its internal register pointer
between the high and low byte of the word. EEPROMs behave that way, so
this mode makes it possible to dump an EEPROM contents faster. I2C Block
Read is still faster but it isn't available on all busses, while SMBus
Read Word is very popular. This mode also makes it possible to test
SMBus Read Word transactions on a given adapter using common EEPROMs.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@3286 7894878c-1315-0410-8ee3-d5d059ff63e0
2006-04-16 14:01:32 +00:00
Jean Delvare
c94e355e0a
Restore bank register value after bank switching.
...
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@3284 7894878c-1315-0410-8ee3-d5d059ff63e0
2006-04-15 10:34:28 +00:00
Jean Delvare
c12c82c13d
Backport SMBus PEC support rewrite from Linux 2.6:
...
Discard I2C_FUNC_SMBUS_*_PEC defines. i2c clients are not supposed to
check for PEC support of i2c bus drivers on individual SMBus
transactions, and i2c bus drivers are not supposed to advertise them.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@3176 7894878c-1315-0410-8ee3-d5d059ff63e0
2005-11-05 12:24:30 +00:00
Jean Delvare
eabdfe8b94
Display the real addresses (rather than offsets thereto) in flat
...
mode.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@3111 7894878c-1315-0410-8ee3-d5d059ff63e0
2005-09-30 17:30:55 +00:00
Jean Delvare
40a778e313
Continuous byte mode needs not only read byte capability but also
...
write byte capability.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@3110 7894878c-1315-0410-8ee3-d5d059ff63e0
2005-09-30 17:25:38 +00:00
Jean Delvare
d9927a5a5e
Fix a bug in argc check.
...
Only use PEC on the register write, not the readback, as it has proven to
cause trouble on some chips. Reads with PEC can be tested using i2cget.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@3109 7894878c-1315-0410-8ee3-d5d059ff63e0
2005-09-30 17:16:24 +00:00
Jean Delvare
47a3cc59c0
New helper program to read a single register from an I2C/SMBus
...
chip. It has byte data and word data read support as well as byte
write/byte read, and supports PEC too. Beware that byte write with PEC
enabled can write random values to registers on non-PEC-aware chips.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@3108 7894878c-1315-0410-8ee3-d5d059ff63e0
2005-09-29 20:59:22 +00:00
Jean Delvare
86a438a263
Add PEC support. This should help debugging PEC support and use
...
in the kernel drivers.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@3106 7894878c-1315-0410-8ee3-d5d059ff63e0
2005-09-28 21:05:03 +00:00
Jean Delvare
5c70989fe9
Drop now useless #ifdef tests. i2c-dev.h defines everything we
...
need, and is part of this package (lm_sensors2) so it is always
up-to-date.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@3102 7894878c-1315-0410-8ee3-d5d059ff63e0
2005-09-25 18:57:42 +00:00
Jean Delvare
2cc8929c9e
Stop printing the algorithm name unless /proc compatibility format
...
is requested. Print the correct bus type if bus functionality can be
queried (will work if i2c-dev is loaded and user has write access to
/dev/i2c*).
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@3078 7894878c-1315-0410-8ee3-d5d059ff63e0
2005-09-10 12:03:14 +00:00
Jean Delvare
32fbdf8ba4
Add a "quiet" parameter to open_i2c_dev() to prevent it from
...
displaying error messages.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@3077 7894878c-1315-0410-8ee3-d5d059ff63e0
2005-09-10 11:38:32 +00:00
Jean Delvare
00e07cfde1
Prevent possible (but harmless and unlikely) buffer overflow.
...
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@3050 7894878c-1315-0410-8ee3-d5d059ff63e0
2005-08-08 19:44:52 +00:00
Jean Delvare
4da4861017
Properly handle short i2c block reads.
...
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@3048 7894878c-1315-0410-8ee3-d5d059ff63e0
2005-08-08 19:09:32 +00:00
Jean Delvare
9a50485742
Fix synopsis line (patch from Sergey Vlasov). Fix typo. Update
...
date.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2985 7894878c-1315-0410-8ee3-d5d059ff63e0
2005-05-01 16:52:21 +00:00
Jean Delvare
8b7f315fd8
Update to mention the new -k option.
...
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2900 7894878c-1315-0410-8ee3-d5d059ff63e0
2005-02-09 22:01:43 +00:00
Jean Delvare
4943663301
Handle keys/passwords needed to access most Super-I/O chips.
...
This should let us dump Winbond Super-I/O chips past the few first
dozens registers.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2899 7894878c-1315-0410-8ee3-d5d059ff63e0
2005-02-09 21:08:17 +00:00
Jean Delvare
3eb8495004
Written value can be masked, preserving unmasked bits at the
...
written location. Similar to what I did for i2cset some times
ago.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2739 7894878c-1315-0410-8ee3-d5d059ff63e0
2004-10-16 14:24:55 +00:00
Jean Delvare
2a73d0fd71
Written byte/word can be masked.
...
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2721 7894878c-1315-0410-8ee3-d5d059ff63e0
2004-10-10 15:58:47 +00:00
Jean Delvare
f9fe027586
Nicer output. Refactor code a little.
...
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2712 7894878c-1315-0410-8ee3-d5d059ff63e0
2004-10-08 18:40:03 +00:00
Jean Delvare
49526b087e
Showing the version is not an error.
...
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2697 7894878c-1315-0410-8ee3-d5d059ff63e0
2004-09-22 20:41:26 +00:00
Jean Delvare
657ffe4e9c
Wait for user input to continue (as opposed to 5 sec delay).
...
Can be skipped using -y.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2680 7894878c-1315-0410-8ee3-d5d059ff63e0
2004-08-30 19:31:46 +00:00
Jean Delvare
eb8ced91c4
Trivial fixes (typo...)
...
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2678 7894878c-1315-0410-8ee3-d5d059ff63e0
2004-08-30 19:19:52 +00:00
Jean Delvare
043d2bb261
New header file, for functions shared among i2c command line
...
tools (i2cdetect, i2cdump, i2cset).
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2677 7894878c-1315-0410-8ee3-d5d059ff63e0
2004-08-30 18:43:12 +00:00
Jean Delvare
e594f08271
Wait for user input to continue (as opposed to 5 sec delay).
...
Can be skipped using -y.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2676 7894878c-1315-0410-8ee3-d5d059ff63e0
2004-08-29 21:22:00 +00:00
Jean Delvare
1cc6544e2b
Refactor i2c device opening.
...
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2675 7894878c-1315-0410-8ee3-d5d059ff63e0
2004-08-28 20:42:49 +00:00
Jean Delvare
2f3df5d0cb
Mass reindent.
...
Drop /dev/i2cN support.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2673 7894878c-1315-0410-8ee3-d5d059ff63e0
2004-08-26 21:01:40 +00:00
Jean Delvare
89deecca35
Wait for user input to continue (as opposed to 5 sec delay).
...
Can be skipped using -y.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2663 7894878c-1315-0410-8ee3-d5d059ff63e0
2004-08-16 18:55:39 +00:00
Jean Delvare
e7f4222ccb
Mass coding-style update.
...
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2661 7894878c-1315-0410-8ee3-d5d059ff63e0
2004-08-15 12:23:14 +00:00
Mark D. Studebaker
86e0a5ef92
cleanups - remove parens in synopsis (docbook doesn't like);
...
replace I\u2\dC with I2C since man2html doesn't translate it
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2647 7894878c-1315-0410-8ee3-d5d059ff63e0
2004-07-24 19:00:21 +00:00
Jean Delvare
e7e4c799da
Implement "make user_uninstall". Original patch contributed by
...
Rudolf Marek.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2604 7894878c-1315-0410-8ee3-d5d059ff63e0
2004-06-20 14:18:28 +00:00
Jean Delvare
0d9f6417d5
Cut long line properly.
...
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2584 7894878c-1315-0410-8ee3-d5d059ff63e0
2004-06-05 19:04:02 +00:00
Jean Delvare
4d095e0921
New manual page for isaset.
...
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2490 7894878c-1315-0410-8ee3-d5d059ff63e0
2004-04-29 17:43:50 +00:00
Jean Delvare
62b7916019
Add missing include.
...
Discard unused hexchar function.
Massive reindent.
Rework the command line parameters handling.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2489 7894878c-1315-0410-8ee3-d5d059ff63e0
2004-04-29 17:24:45 +00:00
Mark D. Studebaker
6f821d2ad8
new isaset program. Warning - lightly tested.
...
Please test and improve as necessary.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2488 7894878c-1315-0410-8ee3-d5d059ff63e0
2004-04-28 23:54:09 +00:00
Jean Delvare
0738cd0915
Document the new flat address options.
...
Add a few notes.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2476 7894878c-1315-0410-8ee3-d5d059ff63e0
2004-04-25 13:30:21 +00:00
Jean Delvare
ad91c909d8
Add bank support to flat address space mode.
...
Default to bank register 0x07 for Super-I/O chips.
Move default bank register selection to a separate function.
Move setting/restoring bank to a separate function.
Allow dumping of shorter ranges (flat address space mode).
Limit I2C-like dumps to addresses up to 0x3fff.
Print expected ranges on range errors.
This should allow us to work with the PC87360 family of chips.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2475 7894878c-1315-0410-8ee3-d5d059ff63e0
2004-04-25 13:26:45 +00:00
Jean Delvare
d832ee135d
More detail on how i2cdump can write to a chip.
...
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2462 7894878c-1315-0410-8ee3-d5d059ff63e0
2004-04-20 19:34:10 +00:00
Mark D. Studebaker
379a2143d3
add code authors to man pages
...
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2456 7894878c-1315-0410-8ee3-d5d059ff63e0
2004-04-20 01:25:22 +00:00
Jean Delvare
0c01cd9544
Stop being Winbond-specific about banks: don't mask high bit.
...
Allow forcing of bank 0. Restore bank after dump.
This allows proper operation on Super-I/O chips.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2452 7894878c-1315-0410-8ee3-d5d059ff63e0
2004-04-19 18:02:10 +00:00
Jean Delvare
80618f354d
Trivial fixes.
...
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2389 7894878c-1315-0410-8ee3-d5d059ff63e0
2004-03-22 19:55:12 +00:00
Jean Delvare
67a0c882aa
Skip isadump on non-x86 architectures. Patch by Aurelien Jarno.
...
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2382 7894878c-1315-0410-8ee3-d5d059ff63e0
2004-03-21 13:10:26 +00:00
Jean Delvare
45940855fd
Manual pages for dump tools, originally written by David Z Maze
...
for the Debian distribution. Original patch by Aurelien Jarno.
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2380 7894878c-1315-0410-8ee3-d5d059ff63e0
2004-03-21 10:28:48 +00:00
Mark D. Studebaker
36c7305e78
use /sys/class/i2c-dev/i2c-x/name file if available;
...
solves problem with drivers that have multiple busses;
requires Greg's patch (for kernel 2.6.5?)
git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2341 7894878c-1315-0410-8ee3-d5d059ff63e0
2004-03-06 20:27:41 +00:00