struct sensor_device_attribute *sensor_attr = to_sensor_dev_attr(attr); int nr = sensor_attr->index;
static ssize_t show_temp(struct device *dev, char *buf, int nr){	struct it87_data *data = it87_update_device(dev);	return sprintf(buf, "%d\n", TEMP_FROM_REG(data->temp[nr]));}