1. 22 12月, 2012 2 次提交
    • G
      hwmon: (emc6w201) Fix DIV_ROUND_CLOSEST problem with unsigned divisors · 86266ca0
      Guenter Roeck 提交于
      Result of DIV_ROUND_CLOSEST is undefined for negative dividends if the divisor
      variable type is unsigned. Fix by declaring divisor as signed variable.
      Signed-off-by: NGuenter Roeck <linux@roeck-us.net>
      Acked-by: NJean Delvare <khali@linux-fr.org>
      86266ca0
    • C
      hwmon: (lm73} Detect and report i2c bus errors · 0602934f
      Chris Verges 提交于
      If an LM73 device does not exist on an I2C bus, attempts to communicate
      with the device result in an error code returned from the i2c read/write
      functions.  The current lm73 driver casts that return value from a s32
      type to a s16 type, then converts it to a temperature in celsius.
      Because negative temperatures are valid, it is difficult to distinguish
      between an error code printed to the response buffer and a negative
      temperature recorded by the sensor.
      
      The solution is to evaluate the return value from the i2c functions
      before performing any temperature calculations.  If the i2c function did
      not succeed, the error code should be passed back through the virtual
      file system layer instead of being printed into the response buffer.
      
      Before:
      
         $ cat /sys/class/hwmon/hwmon0/device/temp1_input
         -46
      
      After:
      
         $ cat /sys/class/hwmon/hwmon0/device/temp1_input
         cat: read error: No such device or address
      Signed-off-by: NChris Verges <kg4ysn@gmail.com>
      Cc: stable@vger.kernel.org
      Signed-off-by: NGuenter Roeck <linux@roeck-us.net>
      0602934f
  2. 20 12月, 2012 16 次提交
  3. 17 12月, 2012 1 次提交
  4. 06 12月, 2012 10 次提交
  5. 29 11月, 2012 4 次提交
  6. 06 11月, 2012 2 次提交
  7. 02 11月, 2012 1 次提交
  8. 30 10月, 2012 1 次提交
  9. 17 10月, 2012 1 次提交
  10. 15 10月, 2012 2 次提交