diff options
author | Geliang Tang <geliangtang@163.com> | 2016-01-13 09:48:43 -0500 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2016-01-13 12:15:53 -0500 |
commit | e3837b00b6bb2b0344dd28c601edda8eba42de7f (patch) | |
tree | f9c93f9085c734caf300393a6228a7c8eabe3f89 | |
parent | cc29ec874b3727e3f5a606bd1875e34f6e3f1593 (diff) |
drm/radeon: use kobj_to_dev()
Use kobj_to_dev() instead of open-coding it.
Signed-off-by: Geliang Tang <geliangtang@163.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
-rw-r--r-- | drivers/gpu/drm/radeon/radeon_pm.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/radeon/radeon_pm.c b/drivers/gpu/drm/radeon/radeon_pm.c index 59abebd6b5dc..460c8f2989da 100644 --- a/drivers/gpu/drm/radeon/radeon_pm.c +++ b/drivers/gpu/drm/radeon/radeon_pm.c | |||
@@ -713,7 +713,7 @@ static struct attribute *hwmon_attributes[] = { | |||
713 | static umode_t hwmon_attributes_visible(struct kobject *kobj, | 713 | static umode_t hwmon_attributes_visible(struct kobject *kobj, |
714 | struct attribute *attr, int index) | 714 | struct attribute *attr, int index) |
715 | { | 715 | { |
716 | struct device *dev = container_of(kobj, struct device, kobj); | 716 | struct device *dev = kobj_to_dev(kobj); |
717 | struct radeon_device *rdev = dev_get_drvdata(dev); | 717 | struct radeon_device *rdev = dev_get_drvdata(dev); |
718 | umode_t effective_mode = attr->mode; | 718 | umode_t effective_mode = attr->mode; |
719 | 719 | ||