Home
last modified time | relevance | path

Searched hist:"3 a412d5e4a1c831723d0aaf305f1cf9a78ad9c90" (Results 1 – 1 of 1) sorted by relevance

/openbmc/linux/drivers/hwmon/
H A Dhwmon.cdiff 3a412d5e4a1c831723d0aaf305f1cf9a78ad9c90 Sun Oct 16 12:52:04 CDT 2016 Guenter Roeck <linux@roeck-us.net> hwmon: (core) Simplify sysfs attribute name allocation

Allocating the sysfs attribute name only if needed and only with the
required minimum length looks optimal, but does not take the additional
overhead for both devm_ data structures and the allocation header itself
into account. This also results in unnecessary memory fragmentation.
Move the sysfs name string into struct hwmon_device_attribute and give it
a sufficient length to reduce this overhead.

Signed-off-by: Guenter Roeck <linux@roeck-us.net>