Changeset 4757

Show
Ignore:
Timestamp:
09/05/07 10:13:15 (7 years ago)
Author:
khali
Message:

Rename sensors_feature_data.mode to flags, as we plan to use it to
store non-mode flags soon.

Location:
lm-sensors/branches/lm-sensors-3.0.0
Files:
7 modified

Legend:

Unmodified
Added
Removed
  • lm-sensors/branches/lm-sensors-3.0.0/lib/access.c

    r4736 r4757  
    239239                                        main_feature->data.compute_mapping); 
    240240 
    241         if (!(main_feature->data.mode & SENSORS_MODE_R)) 
     241        if (!(main_feature->data.flags & SENSORS_MODE_R)) 
    242242                return -SENSORS_ERR_ACCESS_R; 
    243243        for (chip = NULL; 
     
    286286                                        main_feature->data.compute_mapping); 
    287287 
    288         if (!(main_feature->data.mode & SENSORS_MODE_W)) 
     288        if (!(main_feature->data.flags & SENSORS_MODE_W)) 
    289289                return -SENSORS_ERR_ACCESS_W; 
    290290        for (chip = NULL; 
  • lm-sensors/branches/lm-sensors-3.0.0/lib/data.h

    r4736 r4757  
    133133     feature whose compute line will be inherited (a group could be fan and 
    134134     fan_max, but not fan_div) 
    135    mode is a bitfield, its value is a combination of SENSORS_MODE_R (readable) 
     135   flags is a bitfield, its value is a combination of SENSORS_MODE_R (readable) 
    136136     and SENSORS_MODE_W (writable). 
    137137   scaling is the number of decimal points to scale by. 
  • lm-sensors/branches/lm-sensors-3.0.0/lib/libsensors.3

    r4733 r4757  
    116116  int compute_mapping; 
    117117.br 
    118   int mode; 
     118  unsigned int flags; 
    119119.br 
    120120} sensors_feature_data;\fP 
    121121.br 
    122 The mode field is a bitfield, its value is a combination of 
     122The flags field is a bitfield, its value is a combination of 
    123123SENSORS_MODE_R (readable) and SENSORS_MODE_W (writable). 
    124124 
  • lm-sensors/branches/lm-sensors-3.0.0/lib/sensors.h

    r4736 r4757  
    113113                                                    *match, int *nr); 
    114114 
    115 /* These defines are used in the mode field of sensors_feature_data */ 
     115/* These defines are used in the flags field of sensors_feature_data */ 
    116116#define SENSORS_MODE_R 1 
    117117#define SENSORS_MODE_W 2 
     
    165165        int mapping; 
    166166        int compute_mapping; 
    167         int mode; 
     167        unsigned int flags; 
    168168} sensors_feature_data; 
    169169 
  • lm-sensors/branches/lm-sensors-3.0.0/lib/sysfs.c

    r4744 r4757  
    154154 
    155155                if (attr->method & SYSFS_METHOD_SHOW) 
    156                         feature.data.mode |= SENSORS_MODE_R; 
     156                        feature.data.flags |= SENSORS_MODE_R; 
    157157                if (attr->method & SYSFS_METHOD_STORE) 
    158                         feature.data.mode |= SENSORS_MODE_W; 
     158                        feature.data.flags |= SENSORS_MODE_W; 
    159159 
    160160                feature.scaling = get_type_scaling(type); 
  • lm-sensors/branches/lm-sensors-3.0.0/prog/sensord/sense.c

    r4709 r4757  
    8989      sensorLog (LOG_ERR, "Error getting sensor label: %s/%s", chip->prefix, sensor->name); 
    9090      ret = 21; 
    91     } else if (!(sensor->mode & SENSORS_MODE_R)) { 
     91    } else if (!(sensor->flags & SENSORS_MODE_R)) { 
    9292      sensorLog (LOG_INFO, "%s: %s", sensor->name, label); 
    9393    } else if ((ret = sensors_get_value (chip, sensor->number, &value))) { 
  • lm-sensors/branches/lm-sensors-3.0.0/prog/sensors/chips.c

    r4730 r4757  
    4242                        continue; 
    4343                } 
    44                 if (data->mode & SENSORS_MODE_R) { 
     44                if (data->flags & SENSORS_MODE_R) { 
    4545                        if (sensors_get_value(name, data->number, &val)) 
    4646                                printf("ERROR: Can't get feature `%s' data!\n",