Lines Matching refs:fps
21 struct acpi_fan_fps *fps = container_of(attr, struct acpi_fan_fps, dev_attr); in show_state() local
24 if (fps->control == 0xFFFFFFFF || fps->control > 100) in show_state()
27 count = scnprintf(buf, PAGE_SIZE, "%lld:", fps->control); in show_state()
29 if (fps->trip_point == 0xFFFFFFFF || fps->trip_point > 9) in show_state()
32 count += sysfs_emit_at(buf, count, "%lld:", fps->trip_point); in show_state()
34 if (fps->speed == 0xFFFFFFFF) in show_state()
37 count += sysfs_emit_at(buf, count, "%lld:", fps->speed); in show_state()
39 if (fps->noise_level == 0xFFFFFFFF) in show_state()
42 count += sysfs_emit_at(buf, count, "%lld:", fps->noise_level * 100); in show_state()
44 if (fps->power == 0xFFFFFFFF) in show_state()
47 count += sysfs_emit_at(buf, count, "%lld\n", fps->power); in show_state()
98 struct acpi_fan_fps *fps = &fan->fps[i]; in acpi_fan_create_attributes() local
100 snprintf(fps->name, ACPI_FPS_NAME_LEN, "state%d", i); in acpi_fan_create_attributes()
101 sysfs_attr_init(&fps->dev_attr.attr); in acpi_fan_create_attributes()
102 fps->dev_attr.show = show_state; in acpi_fan_create_attributes()
103 fps->dev_attr.store = NULL; in acpi_fan_create_attributes()
104 fps->dev_attr.attr.name = fps->name; in acpi_fan_create_attributes()
105 fps->dev_attr.attr.mode = 0444; in acpi_fan_create_attributes()
106 status = sysfs_create_file(&device->dev.kobj, &fps->dev_attr.attr); in acpi_fan_create_attributes()
111 sysfs_remove_file(&device->dev.kobj, &fan->fps[j].dev_attr.attr); in acpi_fan_create_attributes()
133 sysfs_remove_file(&device->dev.kobj, &fan->fps[i].dev_attr.attr); in acpi_fan_delete_attributes()