Changeset 1126
- Timestamp:
- 06/09/01 01:57:26 (12 years ago)
- Files:
-
- 1 modified
-
lm-sensors/trunk/prog/sensors/main.c (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
lm-sensors/trunk/prog/sensors/main.c
r1112 r1126 208 208 209 209 if ((res = sensors_init(config_file))) { 210 if (res == SENSORS_ERR_PROC) 210 fprintf(stderr,"%s\n",sensors_strerror(res)); 211 if (res == -SENSORS_ERR_PROC) 211 212 fprintf(stderr, 212 "/proc/sys/dev/sensors/chips or /proc/bus/i2c unreadable:\n" 213 "Make sure you have inserted modules sensors.o and i2c-proc.o!"); 214 else 215 fprintf(stderr,"%s\n",sensors_strerror(res)); 213 "/proc/sys/dev/sensors/chips or /proc/bus/i2c unreadable;\n" 214 "Make sure you have done 'modprobe i2c-proc'!\n"); 216 215 exit(1); 217 216 } … … 251 250 { 252 251 int res; 253 if ((res = sensors_do_chip_sets(name))) 254 fprintf(stderr,"%s: %s\n",sprintf_chip_name(name),sensors_strerror(res)); 252 if ((res = sensors_do_chip_sets(name))) { 253 if (res == -SENSORS_ERR_PROC) { 254 fprintf(stderr,"%s: %s for writing;\n",sprintf_chip_name(name), 255 sensors_strerror(res)); 256 fprintf(stderr,"Run as root?\n"); 257 } else { 258 fprintf(stderr,"%s: %s\n",sprintf_chip_name(name), 259 sensors_strerror(res)); 260 } 261 } 255 262 } 256 263 … … 321 328 else if (!strncmp(name.prefix,"maxilife-", 9)) 322 329 print_maxilife(&name); 330 else if (!strcmp(name.prefix,"it87")) 331 print_it87(&name); 323 332 else if (!strcmp(name.prefix,"ddcmon")) 324 333 print_ddcmon(&name); 325 334 else if (!strcmp(name.prefix,"eeprom")) 326 335 print_eeprom(&name); 327 else if (!strcmp(name.prefix,"it87"))328 print_it87(&name);329 336 else 330 337 print_unknown_chip(&name);
