Skip to content

Commit 9dc8d07

Browse files
Asad Kamalalexdeucher
authored andcommitted
drm/amd/pm: Remove power2_average node
SOC power consumption is reported by power1_average. power2_cap_default/min/max only represent second level limits and don't represent a different type of power or power consumption by a subsection of the SOC. Therefore power2_average does not serve any purpose and hence removing power2_average sysfs node Signed-off-by: Asad Kamal <asad.kamal@amd.com> Reviewed-by: Lijo Lazar <lijo.lazar@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
1 parent af2e61d commit 9dc8d07

1 file changed

Lines changed: 1 addition & 4 deletions

File tree

drivers/gpu/drm/amd/pm/amdgpu_pm.c

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3579,7 +3579,6 @@ static SENSOR_DEVICE_ATTR(power1_cap_min, S_IRUGO, amdgpu_hwmon_show_power_cap_m
35793579
static SENSOR_DEVICE_ATTR(power1_cap, S_IRUGO | S_IWUSR, amdgpu_hwmon_show_power_cap, amdgpu_hwmon_set_power_cap, 0);
35803580
static SENSOR_DEVICE_ATTR(power1_cap_default, S_IRUGO, amdgpu_hwmon_show_power_cap_default, NULL, 0);
35813581
static SENSOR_DEVICE_ATTR(power1_label, S_IRUGO, amdgpu_hwmon_show_power_label, NULL, 0);
3582-
static SENSOR_DEVICE_ATTR(power2_average, S_IRUGO, amdgpu_hwmon_show_power_avg, NULL, 1);
35833582
static SENSOR_DEVICE_ATTR(power2_cap_max, S_IRUGO, amdgpu_hwmon_show_power_cap_max, NULL, 1);
35843583
static SENSOR_DEVICE_ATTR(power2_cap_min, S_IRUGO, amdgpu_hwmon_show_power_cap_min, NULL, 1);
35853584
static SENSOR_DEVICE_ATTR(power2_cap, S_IRUGO | S_IWUSR, amdgpu_hwmon_show_power_cap, amdgpu_hwmon_set_power_cap, 1);
@@ -3628,7 +3627,6 @@ static struct attribute *hwmon_attributes[] = {
36283627
&sensor_dev_attr_power1_cap.dev_attr.attr,
36293628
&sensor_dev_attr_power1_cap_default.dev_attr.attr,
36303629
&sensor_dev_attr_power1_label.dev_attr.attr,
3631-
&sensor_dev_attr_power2_average.dev_attr.attr,
36323630
&sensor_dev_attr_power2_cap_max.dev_attr.attr,
36333631
&sensor_dev_attr_power2_cap_min.dev_attr.attr,
36343632
&sensor_dev_attr_power2_cap.dev_attr.attr,
@@ -3827,8 +3825,7 @@ static umode_t hwmon_attributes_visible(struct kobject *kobj,
38273825
return 0;
38283826

38293827
/* only Vangogh has fast PPT limit and power labels */
3830-
if ((attr == &sensor_dev_attr_power2_average.dev_attr.attr ||
3831-
attr == &sensor_dev_attr_power2_cap_max.dev_attr.attr ||
3828+
if ((attr == &sensor_dev_attr_power2_cap_max.dev_attr.attr ||
38323829
attr == &sensor_dev_attr_power2_cap_min.dev_attr.attr ||
38333830
attr == &sensor_dev_attr_power2_cap.dev_attr.attr ||
38343831
attr == &sensor_dev_attr_power2_cap_default.dev_attr.attr ||

0 commit comments

Comments
 (0)