mirror of
https://github.com/torvalds/linux.git
synced 2024-11-17 01:22:07 +00:00
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>
This commit is contained in:
parent
cc29ec874b
commit
e3837b00b6
@ -713,7 +713,7 @@ static struct attribute *hwmon_attributes[] = {
|
||||
static umode_t hwmon_attributes_visible(struct kobject *kobj,
|
||||
struct attribute *attr, int index)
|
||||
{
|
||||
struct device *dev = container_of(kobj, struct device, kobj);
|
||||
struct device *dev = kobj_to_dev(kobj);
|
||||
struct radeon_device *rdev = dev_get_drvdata(dev);
|
||||
umode_t effective_mode = attr->mode;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user