• E
    thermal: core: use dev.groups to manage always present tz attributes · 1c600861
    Eduardo Valentin 提交于
    Thermal zones attributes are all being created using
    device_create_file(). This has the disadvantage of making the code
    complicated and sometimes we may miss the cleanup of them.
    
    This patch starts to move the thermal zone sysfs attributes to the
    dev.groups, so Linux device core manage them for us. For now, this patch
    only moves those attributes are always present regardless of thermal
    zone condition.
    
    This change has also the advantage of cleaning up the thermal zone
    parameters sysfs entries that are left unclean after device
    registration.
    
    Cc: Zhang Rui <rui.zhang@intel.com>
    Cc: linux-pm@vger.kernel.org
    Cc: linux-kernel@vger.kernel.org
    Signed-off-by: NEduardo Valentin <edubezval@gmail.com>
    Signed-off-by: NZhang Rui <rui.zhang@intel.com>
    1c600861
thermal_core.c 60.4 KB