platform/x86: ideapad-laptop: rework is_visible() logic
authorBarnabás Pőcze <pobrn@protonmail.com>
Wed, 3 Feb 2021 21:56:10 +0000 (21:56 +0000)
committerHans de Goede <hdegoede@redhat.com>
Thu, 4 Feb 2021 09:21:14 +0000 (10:21 +0100)
commit1c59de4ad24b6024b5d5b78d25486848f2d96c5d
tree9eb5c3ad826656812a8d62e9610549eae5178daa
parentff36b0d953dc4cbc40a72945920ff8e805f1b0da
platform/x86: ideapad-laptop: rework is_visible() logic

Store the supported features in the driver private
data, and modify the is_visible() callback to use it,
and create ideapad_check_features() to populate it.

Signed-off-by: Barnabás Pőcze <pobrn@protonmail.com>
Link: https://lore.kernel.org/r/20210203215403.290792-19-pobrn@protonmail.com
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
drivers/platform/x86/ideapad-laptop.c