mirror of
git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-08-04 00:06:36 +00:00
platform/x86: ideapad-laptop: use kobj_to_dev()
Use kobj_to_dev() instead of open-coding the container_of() macro. Signed-off-by: Barnabás Pőcze <pobrn@protonmail.com> Link: https://lore.kernel.org/r/20210203215403.290792-9-pobrn@protonmail.com Reviewed-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Hans de Goede <hdegoede@redhat.com>
This commit is contained in:
parent
8782d8d7e8
commit
708086b236
1 changed files with 1 additions and 1 deletions
|
@ -547,7 +547,7 @@ static umode_t ideapad_is_visible(struct kobject *kobj,
|
|||
struct attribute *attr,
|
||||
int idx)
|
||||
{
|
||||
struct device *dev = container_of(kobj, struct device, kobj);
|
||||
struct device *dev = kobj_to_dev(kobj);
|
||||
struct ideapad_private *priv = dev_get_drvdata(dev);
|
||||
bool supported;
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue