Lines Matching defs:value
68 const char *value;
70 value = udev_device_get_sysattr_value(parent, "class");
71 if (value) {
74 if (safe_atolu(value, &class) < 0) {
76 value, subsystem, sysname);
235 static void clamp_brightness(struct udev_device *device, char **value, unsigned max_brightness) {
240 r = safe_atou(*value, &brightness);
242 log_warning_errno(r, "Failed to parse brightness \"%s\": %m", *value);
254 char *old_value = *value;
256 r = asprintf(value, "%u", new_brightness);
265 *value);
379 _cleanup_free_ char *value = NULL;
388 r = read_one_line_file(saved, &value);
400 clamp_brightness(device, &value, max_brightness);
402 r = udev_device_set_sysattr_value(device, "brightness", value);
409 const char *value;
416 value = udev_device_get_sysattr_value(device, "brightness");
417 if (!value) {
422 r = write_string_file(saved, value, WRITE_STRING_FILE_CREATE);