logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

sysfs.conf, sysfs.d/*.conf - Linux sysfs attributes setting configuration files

Description

These configuration files are used to set sysfs attribute values and modify their file mode or owner, during the system boot. Note that these configuration files are concerned with the /sys filesystem and should not be confused with the /etc/sysctl.conf configuration which is concerned with the /proc/sys filesystem instead.

Examples

Always use the powersave CPU frequency governor. devices/system/cpu/cpu0/cpufreq/scaling_governor = powersave Use userspace CPU frequency governor and set initial speed. devices/system/cpu/cpu0/cpufreq/scaling_governor = userspace devices/system/cpu/cpu0/cpufreq/scaling_setspeed = 600000 Set permissions of suspend control file. mode power/state = 0660 owner power/state = root:power

Files

/etc/sysfs.conf The main configuration file. It gets loaded first if readable. /etc/sysfs.d/*.conf The optional configuration fragment files. These get loaded after the main configuration file, if readable, in glob order.

Format

The syntax consists on a series of line based directives for sysfs attributes, those being pathnames within that filesystem, with the following format: attribute = value Set value for the sysfsattribute. modeattribute = mode Set the mode for the sysfsattribute. Where mode is any mode accepted by chmod(1). ownerattribute = owner[:group] Set the owner (and/or group) for the sysfsattribute. Where owner (and/or group) are any specification accepted by chown(1). Leading and trailing whitespace (SPACE, TAB), and whitespace around the = character are ignored. Comments start with a # character until the end of line. Empty or whitespace-only lines are also ignored. The attribute paths support glob(7) wildcard patterns. Any attribute that does not exist will be warned about, but will not cause the loading to fail.

Name

sysfs.conf, sysfs.d/*.conf - Linux sysfs attributes setting configuration files

See Also

sysfs(5), <https://www.kernel.org/doc/Documentation/filesystems/sysfs.txt>, <https://www.kernel.org/doc/Documentation/ABI/stable/>. 2.1.1-7 2025-03-28 sysfs.conf(5)

See Also