Changeset 4326

Show
Ignore:
Timestamp:
02/15/07 12:58:53 (2 years ago)
Author:
khali
Message:

libsensors: Do not skip i2c adapters with only a class device and no
physical device. This change is required to survive the planned struct
class_dev removal from future 2.6 kernels.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • lm-sensors/trunk/CHANGES

    r4325 r4326  
    33 
    44SVN HEAD 
     5  Library: Do not skip i2c adapters with only a class device and no 
     6            physical device. This change is required to survive the 
     7            planned struct class_dev removal from future 2.6 kernels. 
    58  Man page i2cdetect.8: Scanning range can be restricted 
    69  Module bmcsensors: Fix debugging messages 
  • lm-sensors/trunk/lib/sysfs.c

    r4267 r4326  
    196196                struct sysfs_attribute *attr; 
    197197 
    198                 if (!(dev = sysfs_get_classdev_device(clsdev))) 
    199                         continue; 
    200198                /* Get the adapter name from the classdev "name" attribute 
    201199                 * (Linux 2.6.20 and later). If it fails, fall back to 
    202200                 * the device "name" attribute (for older kernels). */ 
    203201                if (!(attr = sysfs_get_classdev_attr(clsdev, "name")) 
    204                  && !(attr = sysfs_get_device_attr(dev, "name"))) 
     202                 && !((dev = sysfs_get_classdev_device(clsdev)) && 
     203                      (attr = sysfs_get_device_attr(dev, "name")))) 
    205204                        continue; 
    206205