Commit graph

184 commits

Author SHA1 Message Date
Hans de Goede
06ffe5b25e platform/x86: lenovo-yogabook: Rename lenovo-yogabook-wmi to lenovo-yogabook
The lenovo-yogabook-wmi.c code now consists of both a platform and a WMI
driver and it does not use WMI at all when used on the Android model.

Rename the module from lenovo-yogabook-wmi to lenovo-yogabook to
reflect this.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Link: https://lore.kernel.org/r/20230430165807.472798-20-hdegoede@redhat.com
2023-05-09 12:36:09 +02:00
Gergo Koteles
e82882cdd2 platform/x86: Add driver for Yoga Tablet Mode switch
This WMI driver for the tablet mode control switch for Lenovo Yoga
notebooks was originally written by Gergo Koteles. The mode is mapped to
a SW_TABLET_MODE switch capable input device.

Andrew followed the suggestions that were posted in reply to Gergo's RFC
patch, and on the v1 & v2 versions of this patch to follow-up and get it
merged.

Changes from Gergo's RFC:

 - Refactored obtaining a reference to the EC ACPI device needed for the
   quirk implementation as suggested by Hans de Goede
 - Applied small fixes and switched to always registering handles with
   the driver for automatic cleanup as suggested by Barnabás Pőcze.
 - Merged the lenovo_ymc_trigger_ec function with the
   ideapad_trigger_ymc_next_read function since it was no longer
   external.
 - Added the word "Tablet" to the driver description to hopefully make
   it more clear.
 - Fixed the LENOVO_YMC_QUERY_METHOD ID and the name string for the EC
   APCI device trigged for the quirk
 - Triggered the input event on probe so that the initial tablet mode
   state when the driver is loaded is reported to userspace as suggested
   by Armin Wolf.
 - Restricted the permissions of the ec_trigger parameter as suggested
   by Armin Wolf. Also updated the description.

We have tested this on the Yoga 7 14AIL7 for the non-quirk path and on
the Yoga 7 14ARB7 which has the firmware bug that requires triggering
the embedded controller to send the mode change events. This workaround
is also used by the Windows drivers.

According to reports at https://github.com/lukas-w/yoga-usage-mode,
which uses the same WMI devices, the following models should also work:
Yoga C940, Ideapad flex 14API, Yoga 9 14IAP7, Yoga 7 14ARB7, etc.

Signed-off-by: Gergo Koteles <soyer@irl.hu>
Co-developed-by: Andrew Kallmeyer <kallmeyeras@gmail.com>
Signed-off-by: Andrew Kallmeyer <kallmeyeras@gmail.com>
Link: https://lore.kernel.org/r/20221004214332.35934-1-soyer@irl.hu/
Link: https://lore.kernel.org/r/20230310041726.217447-1-kallmeyeras@gmail.com/
Link: https://lore.kernel.org/r/20230323025200.5462-1-kallmeyeras@gmail.com/
Tested-by: André Apitzsch <git@apitzsch.eu>
Link: https://lore.kernel.org/r/20230329014559.44494-3-kallmeyeras@gmail.com
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2023-04-06 12:33:34 +02:00
Nikita Kravets
392cacf2aa platform/x86: Add new msi-ec driver
Add a new driver to allow various MSI laptops' functionalities to be
controlled from userspace. This includes such features as power
profiles (aka shift modes), fan speed, charge thresholds, LEDs, etc.

This driver contains EC memory configurations for different firmware
versions and exports battery charge thresholds to userspace (note,
that start and end thresholds control the same EC parameter
and are always 10% apart).

Link: https://github.com/BeardOverflow/msi-ec/
Link: https://github.com/BeardOverflow/msi-ec/pull/13
Cc: Aakash Singh <mail@singhaakash.dev>
Cc: Jose Angel Pastrana <japp0005@red.ujaen.es>
Signed-off-by: Nikita Kravets <teackot@gmail.com>
Link: https://lore.kernel.org/r/20230320225509.3559-1-teackot@gmail.com
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2023-03-27 16:10:20 +02:00
Hans de Goede
772cbba5a8 platform/x86: x86-android-tablets: Add support for the Dolby button on Peaq C1010
The Peaq C1010 tablet has a special "Dolby" button. This button has
a WMI interface, but this is broken in several ways:

1. It only supports polling
2. The value read on polling goes from 0 -> 1 for one poll on both edges
   of the button, with no way to tell which edge causes the poll to
   return 1.
3. It uses a non unique GUID (it uses the Microsoft docs WMI example GUID).

There currently is a WMI driver for this, but it uses several kludges
to work around these issues and is not entirely reliable due to 2.

Replace the unreliable WMI driver by using the x86-android-tablets code
to instantiate a gpio_keys device for this.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Link: https://lore.kernel.org/r/20230301092331.7038-11-hdegoede@redhat.com
2023-03-07 12:08:31 +01:00
Hans de Goede
afdcb5353f platform/x86: x86-android-tablets: Move into its own subdir
Move the x86-android-tablets code into its own subdir, this is
a preparation patch for splitting the somewhat large file into
multiple smaller files.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Link: https://lore.kernel.org/r/20230301092331.7038-3-hdegoede@redhat.com
2023-03-07 12:08:30 +01:00
Jorge Lopez
6e9b8992b1 platform/x86: Move existing HP drivers to a new hp subdir
The purpose of this patch is to provide a central location where all
HP related drivers are found. HP drivers will recide under
drivers/platform/x86/hp directory.

Introduce changes to Kconfig file to list all HP driver under "HP X86
Platform Specific Device Drivers" menu option. Additional changes
include update MAINTAINERS file to indicate hp related drivers new
path.

Signed-off-by: Jorge Lopez <jorge.lopez2@hp.com>
Link: https://lore.kernel.org/r/20221020201033.12790-2-jorge.lopez2@hp.com
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2022-11-16 08:48:19 +01:00
Andy Shevchenko
42d0d4232a platform/x86: p2sb: Move out of X86_PLATFORM_DEVICES dependency
The P2SB library is used for various drivers, including server
platforms. That's why the dependency on X86_PLATFORM_DEVICES
seems superfluous.

Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Link: https://lore.kernel.org/r/20220718145328.14374-1-andriy.shevchenko@linux.intel.com
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2022-08-01 16:26:38 +02:00
Shyam Sundar S K
ef233eafe5 platform/x86: Move AMD platform drivers to separate directory
Currently, AMD supported platform drivers are grouped under generic "x86"
folder structure. Move the current drivers (amd-pmc and amd_hsmp) to a
separate directory. This would also mean the newer driver submissions to
pdx86 subsystem in the future will also land in AMD specific directory.

Reviewed-by: Naveen Krishna Chatradhi <NaveenKrishna.Chatradhi@amd.com>
Tested-by: Suma Hegde <suma.hegde@amd.com>
Signed-off-by: Shyam Sundar S K <Shyam-sundar.S-k@amd.com>
Link: https://lore.kernel.org/r/20220608193212.2827257-1-Shyam-sundar.S-k@amd.com
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2022-06-22 11:57:55 +02:00
Hans de Goede
3cd8cc98d6 platform/x86: Drop the PMC_ATOM Kconfig option
The def_bool y PMC_ATOM Kconfig option provides a couple of symbols used
by the code enabled by the X86_INTEL_LPSS option and it registers some
clocks. These clocks are only registered on Bay Trail, Cherry Trail and
Brasswell Intel SoCs and kernels targeting these SoCs must always have
the X86_INTEL_LPSS option enabled otherwise many things will not work.

Building the PMC_ATOM code on kernels which are not targeting the
mentioned SoCs and which do not have the X86_INTEL_LPSS enabled is
not useful.

This means that we can simplify things by replacing the PMC_ATOM Kconfig
option in Makefiles with X86_INTEL_LPSS and then drop the option.

Cc: Paul Gortmaker <paul.gortmaker@windriver.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Acked-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Acked-by: Stephen Boyd <sboyd@kernel.org>
Link: https://lore.kernel.org/r/20220503140207.101218-2-hdegoede@redhat.com
2022-06-12 14:41:22 +02:00
Daniel Beer
34354476f0 platform/x86: winmate-fm07-keys: Winmate FM07/FM07P buttons
Winmate FM07 and FM07P in-vehicle computers have a row of five buttons
below the display. This module adds an input device that delivers key
events when these buttons are pressed.

Signed-off-by: Daniel Beer <daniel.beer@tirotech.co.nz>
Link: https://lore.kernel.org/r/623a110a.1c69fb81.64f39.0118@mx.google.com
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2022-04-13 13:49:48 +02:00
Suma Hegde
91f410aa67 platform/x86: Add AMD system management interface
Recent Fam19h EPYC server line of processors from AMD support system
management functionality via HSMP (Host System Management Port) interface.

The Host System Management Port (HSMP) is an interface to provide
OS-level software with access to system management functions via a
set of mailbox registers.

More details on the interface can be found in chapter
"7 Host System Management Port (HSMP)" of the following PPR
https://www.amd.com/system/files/TechDocs/55898_B1_pub_0.50.zip

This patch adds new amd_hsmp module under the drivers/platforms/x86/
which creates miscdevice with an IOCTL interface to the user space.
/dev/hsmp is for running the hsmp mailbox commands.

Signed-off-by: Suma Hegde <suma.hegde@amd.com>
Signed-off-by: Naveen Krishna Chatradhi <nchatrad@amd.com>
Reviewed-by: Carlos Bilbao <carlos.bilbao@amd.com>
Acked-by: Song Liu <song@kernel.org>
Reviewed-by: Nathan Fontenot <nathan.fontenot@amd.com>
Link: https://lore.kernel.org/r/20220222050501.18789-1-nchatrad@amd.com
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2022-03-02 11:42:36 +01:00
Lucas Tanure
5e63b2ea3d platform/x86: i2c-multi-instantiate: Rename it for a generic serial driver name
Rename I2C multi instantiate driver to serial-multi-instantiate for
upcoming addition of SPI support

Signed-off-by: Lucas Tanure <tanureal@opensource.cirrus.com>
Signed-off-by: Stefan Binding <sbinding@opensource.cirrus.com>
Link: https://lore.kernel.org/r/20220121172431.6876-6-sbinding@opensource.cirrus.com
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2022-02-02 18:10:02 +01:00
Hans de Goede
0a6509b092 platform/x86: Add Asus TF103C dock driver
Add a driver for the keyboard, touchpad and USB port of
the keyboard dock for the Asus TF103C 2-in-1 tablet.

This keyboard dock has its own I2C attached embedded controller
and the keyboard and touchpad are also connected over I2C,
instead of using the usual USB connection. This means that the
keyboard dock requires this special driver to function.

Cc: Michał Mirosław <mirq-linux@rere.qmqm.pl>
Cc: Ion Agorria <ion@agorria.com>
Cc: Svyatoslav Ryhel <clamor95@gmail.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Link: https://lore.kernel.org/r/20211226141849.156407-1-hdegoede@redhat.com
2022-01-05 12:06:19 +01:00
Hans de Goede
55fa3c9665 platform/x86: x86-android-tablets: New driver for x86 Android tablets
x86 tablets which ship with Android as (part of) the factory image
typically have various problems with their DSDTs. The factory kernels
shipped on these devices typically have device addresses and GPIOs
hardcoded in the kernel, rather then specified in their DSDT.

With the DSDT containing a random collection of devices which may or
may not actually be present as well as missing devices which are
actually present.

This driver, which loads only on affected models based on DMI matching,
adds DMI based instantiating of kernel devices for devices which are
missing from the DSDT, fixing e.g. battery monitoring, touchpads and/or
accelerometers not working.

Note the Kconfig help text also refers to "various fixes" ATM there are
no such fixes, but there are also known cases where entries are present
in the DSDT but they contain bugs, such as missing/wrong GPIOs. The plan
is to also add fixes for things like this here in the future.

This is the least ugly option to get these devices to fully work and to
do so without adding any extra code to the main kernel image (vmlinuz)
when built as a module.

Link: https://lore.kernel.org/platform-driver-x86/20211031162428.22368-1-hdegoede@redhat.com/
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Link: https://lore.kernel.org/r/20211223190750.397487-1-hdegoede@redhat.com
2021-12-25 12:41:06 +01:00
Henning Schild
dd123e62bd platform/x86: simatic-ipc: add main driver for Siemens devices
This mainly implements detection of these devices and will allow
secondary drivers to work on such machines.

The identification is DMI-based with a vendor specific way to tell them
apart in a reliable way.

Drivers for LEDs and Watchdogs will follow to make use of that platform
detection.

There is also some code to allow secondary drivers to find GPIO memory,
that needs to be in place because the pinctrl drivers do not come up.

Signed-off-by: Henning Schild <henning.schild@siemens.com>
Link: https://lore.kernel.org/r/20211213120502.20661-2-henning.schild@siemens.com
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-12-23 18:09:06 +01:00
Andy Shevchenko
c0518b21fb platform/x86/intel: Remove X86_PLATFORM_DRIVERS_INTEL
While introduction of this menu brings a nice view in the configuration tools,
it brought more issues than solves, i.e. it prevents to locate files in the
intel/ subfolder without touching non-related Kconfig dependencies elsewhere.
Drop X86_PLATFORM_DRIVERS_INTEL altogether.

Note, on x86 it's enabled by default and it's quite unlikely anybody wants to
disable all of the modules in this submenu.

Fixes: 8bd836feb6 ("platform/x86: intel_skl_int3472: Move to intel/ subfolder")
Suggested-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20211222194941.76054-1-andriy.shevchenko@linux.intel.com
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-12-23 17:21:58 +01:00
Yauhen Kharuzhy
c0549b72d9 platform/x86: lenovo-yogabook-wmi: Add driver for Lenovo Yoga Book
Add driver to handle WMI events, control the keyboard backlight and
bind/unbind the keyboard-touch / digitizer driver so that only one
is active at a time.

It may seem a bit weird to handle the toggling of the modes in the
kernel, but the hw actually expects only 1 device to be active
at a time.

Changes by Hans de Goede:
- Whole bunch of cleanups
- Make the kernel do the driver bind/unbind itself instead of
  sending events to userspace and requiring a special userspace
  daemon to deal with this

Signed-off-by: Yauhen Kharuzhy <jekhor@gmail.com>
Co-developed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Link: https://lore.kernel.org/r/20211128190031.405620-4-hdegoede@redhat.com
2021-12-07 12:21:00 +01:00
Santosh Kumar Yadav
86af1d02d4 platform/x86: Support for EC-connected GPIOs for identify LED/button on Barco P50 board
Add a driver providing access to the GPIOs for the identify button and led
present on Barco P50 board, based on the pcengines-apuv2.c driver.

There is unfortunately no suitable ACPI entry for the EC communication
interface, so instead bind to boards with "P50" as their DMI product family
and hard code the I/O port number (0x299).

The driver also hooks up the leds-gpio and gpio-keys-polled drivers to the
GPIOs, so they are finally exposed as:

LED:
/sys/class/leds/identify

Button: (/proc/bus/input/devices)
I: Bus=0019 Vendor=0001 Product=0001 Version=0100
N: Name="identify"
P: Phys=gpio-keys-polled/input0
S: Sysfs=/devices/platform/barco-p50-gpio/gpio-keys-polled/input/input10
U: Uniq=
H: Handlers=event10
B: PROP=0
B: EV=3
B: KEY=1000000 0 0 0 0 0 0

Signed-off-by: Santosh Kumar Yadav <santoshkumar.yadav@barco.com>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
Link: https://lore.kernel.org/r/20211020123634.2638-1-peter@korsgaard.com
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-10-20 16:38:57 +02:00
Daniel Dadap
ca16d33bd8 platform/x86: Rename wmaa-backlight-wmi to nvidia-wmi-ec-backlight
Rename the wmaa-backlight-wmi driver and associated KConfig option to
remove the remaining references to the "WMAA" ACPI handle which was
used in the previous name. The driver has already been updated to
remove internal references to "WMAA". As part of the renaming, the
components in the name have been rearranged to reflect the standard
vendor_wmi_feature pattern.

Signed-off-by: Daniel Dadap <ddadap@nvidia.com>
Link: https://lore.kernel.org/r/20210927202359.13684-2-ddadap@nvidia.com
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-10-11 14:59:45 +02:00
Daniel Dadap
ad62cd9319 platform/x86: Add driver for ACPI WMAA EC-based backlight control
A number of upcoming notebook computer designs drive the internal
display panel's backlight PWM through the Embedded Controller (EC).
This EC-based backlight control can be plumbed through to an ACPI
"WMAA" method interface, which in turn can be wrapped by WMI with
the GUID handle 603E9613-EF25-4338-A3D0-C46177516DB7.

Add a new driver, aliased to the WMAA WMI GUID, to expose a sysfs
backlight class driver to control backlight levels on systems with
EC-driven backlights.

Signed-off-by: Daniel Dadap <ddadap@nvidia.com>
Reviewed-by: Thomas Weißschuh <linux@weissschuh.net>
Link: https://lore.kernel.org/r/20210903003838.15797-1-ddadap@nvidia.com
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-09-14 12:26:00 +02:00
Kate Hsuan
95c3e4b428 platform/x86: intel-wmi-thunderbolt: Move to intel sub-directory
Move Intel WMI Thunderbolt driver to intel sub-directory
to improve readability.

Signed-off-by: Kate Hsuan <hpa@redhat.com>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20210820110458.73018-21-andriy.shevchenko@linux.intel.com
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-08-20 20:11:23 +02:00
Kate Hsuan
bd5b4fb47d platform/x86: intel-wmi-sbl-fw-update: Move to intel sub-directory
Move Intel WMI Slim Bootloader FW update driver to intel sub-directory
to improve readability.

Signed-off-by: Kate Hsuan <hpa@redhat.com>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20210820110458.73018-20-andriy.shevchenko@linux.intel.com
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-08-20 20:11:23 +02:00
Kate Hsuan
3afeacfd39 platform/x86: intel-vbtn: Move to intel sub-directory
Move Intel vButton driver to intel sub-directory to improve readability.

Signed-off-by: Kate Hsuan <hpa@redhat.com>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20210820110458.73018-19-andriy.shevchenko@linux.intel.com
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-08-20 20:11:23 +02:00
Kate Hsuan
cdbb8f5e79 platform/x86: intel_oaktrail: Move to intel sub-directory
Move Intel Oaktrail driver to intel sub-directory to improve readability.

Signed-off-by: Kate Hsuan <hpa@redhat.com>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20210820110458.73018-18-andriy.shevchenko@linux.intel.com
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-08-20 20:11:23 +02:00
Kate Hsuan
daef4c5a04 platform/x86: intel_int0002_vgpio: Move to intel sub-directory
Move Intel vGPIO (INT0002) driver to intel sub-directory
to improve readability.

Signed-off-by: Kate Hsuan <hpa@redhat.com>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20210820110458.73018-17-andriy.shevchenko@linux.intel.com
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-08-20 20:11:23 +02:00
Kate Hsuan
c3d3586d12 platform/x86: intel-hid: Move to intel sub-directory
Move Intel HID driver to intel sub-directory to improve readability.

Signed-off-by: Kate Hsuan <hpa@redhat.com>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20210820110458.73018-16-andriy.shevchenko@linux.intel.com
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-08-20 20:11:23 +02:00
Kate Hsuan
76693f5705 platform/x86: intel_atomisp2: Move to intel sub-directory
Move Intel AtomISP v2 drivers to intel sub-directory
to improve readability.

Signed-off-by: Kate Hsuan <hpa@redhat.com>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20210820110458.73018-15-andriy.shevchenko@linux.intel.com
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-08-20 20:11:23 +02:00
Kate Hsuan
6b1e482898 platform/x86: intel_speed_select_if: Move to intel sub-directory
Move Intel Speed Select interface driver to intel sub-directory to improve
readability and rename it from intel_speed_select_if to speed_select_if.

Signed-off-by: Kate Hsuan <hpa@redhat.com>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20210820110458.73018-14-andriy.shevchenko@linux.intel.com
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-08-20 20:11:22 +02:00
Kate Hsuan
075b559829 platform/x86: intel-uncore-frequency: Move to intel sub-directory
Move Intel Uncore frequency driver to intel sub-directory to improve
readability and rename it from intel-uncore-frequency.c to
uncore-frequency.c.

Signed-off-by: Kate Hsuan <hpa@redhat.com>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20210820110458.73018-13-andriy.shevchenko@linux.intel.com
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-08-20 20:11:22 +02:00
Kate Hsuan
1fef1c047b platform/x86: intel_turbo_max_3: Move to intel sub-directory
Move Intel Turbo Max 3 driver to intel sub-directory to improve readability
and rename it from intel_turbo_max_3.c to turbo_max_3.c.

Signed-off-by: Kate Hsuan <hpa@redhat.com>
Acked-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20210820110458.73018-12-andriy.shevchenko@linux.intel.com
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-08-20 20:11:22 +02:00
Kate Hsuan
47bbe03eaf platform/x86: intel-smartconnect: Move to intel sub-directory
Move Intel Smart Connect driver to intel sub-directory to improve
readability and rename it from intel-smartconnect.c to smartconnect.c.

Signed-off-by: Kate Hsuan <hpa@redhat.com>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20210820110458.73018-11-andriy.shevchenko@linux.intel.com
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-08-20 20:11:12 +02:00
Kate Hsuan
e6596c2274 platform/x86: intel-rst: Move to intel sub-directory
Move Intel RST driver to intel sub-directory to improve readability
and rename it from intel-rst.c to rst.c.

Signed-off-by: Kate Hsuan <hpa@redhat.com>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20210820110458.73018-10-andriy.shevchenko@linux.intel.com
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-08-20 20:09:43 +02:00
Kate Hsuan
2b6cb8f2e8 platform/x86: intel_telemetry: Move to intel sub-directory
Move Intel telemetry driver to intel sub-directory to improve readability.

While at it, spell APL fully in the Kconfig.

Signed-off-by: Kate Hsuan <hpa@redhat.com>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Reviewed-by: Rajneesh Bhardwaj <irenic.rajneesh@gmail.com>
Link: https://lore.kernel.org/r/20210820110458.73018-9-andriy.shevchenko@linux.intel.com
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-08-20 20:08:09 +02:00
Kate Hsuan
fa082a7cf5 platform/x86: intel_pmc_core: Move to intel sub-directory
Move Intel PMC core driver to intel sub-directory to improve readability.

Signed-off-by: Kate Hsuan <hpa@redhat.com>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Reviewed-by: Rajneesh Bhardwaj <irenic.rajneesh@gmail.com>
Link: https://lore.kernel.org/r/20210820110458.73018-7-andriy.shevchenko@linux.intel.com
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-08-20 20:00:21 +02:00
Kate Hsuan
386d17b22e platform/x86: intel_punit_ipc: Move to intel sub-directory
Move Intel P-Unit IPC driver to intel sub-directory to improve readability.

Signed-off-by: Kate Hsuan <hpa@redhat.com>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20210820110458.73018-6-andriy.shevchenko@linux.intel.com
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-08-20 20:00:02 +02:00
Kate Hsuan
f51c108d36 platform/x86: intel_mrfld_pwrbtn: Move to intel sub-directory
Move Intel Merrifield power button driver to intel sub-directory
to improve readability.

Signed-off-by: Kate Hsuan <hpa@redhat.com>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20210820110458.73018-5-andriy.shevchenko@linux.intel.com
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-08-20 20:00:02 +02:00
Kate Hsuan
2e4355e4c1 platform/x86: intel_chtdc_ti_pwrbtn: Move to intel sub-directory
Move Intel Cherry Trail Dollar Cove TI power button driver
to intel sub-directory to improve readability.

Signed-off-by: Kate Hsuan <hpa@redhat.com>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20210820110458.73018-4-andriy.shevchenko@linux.intel.com
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-08-20 20:00:02 +02:00
Kate Hsuan
9ed10052b5 platform/x86: intel_bxtwc_tmu: Move to intel sub-directory
Move Intel Broxton Whiskey Cove TMU driver to intel sub-directory
to improve readability.

While at it, spell BXT fully in the Kconfig and switch to select REGMAP.

Signed-off-by: Kate Hsuan <hpa@redhat.com>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20210820110458.73018-3-andriy.shevchenko@linux.intel.com
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-08-20 20:00:02 +02:00
Srinivas Pandruvada
2010319b3c thermal/drivers/intel: Move intel_menlow to thermal drivers
Moved drivers/platform/x86/intel_menlow.c to drivers/thermal/intel.

Signed-off-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>
Acked-by: Daniel Lezcano <daniel.lezcano@linaro.org>
Acked-by: Zhang Rui <rui.zhang@intel.com>
Link: https://lore.kernel.org/r/20210816035356.1955982-1-srinivas.pandruvada@linux.intel.com
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-08-17 14:11:48 +02:00
Chris Blake
636a1e6975 platform/x86: add meraki-mx100 platform driver
This adds platform support for the Cisco Meraki MX100 (Tinkerbell)
network appliance. This sets up the network LEDs and Reset
button.

Depends-on: ef0eea5b15 ("mfd: lpc_ich: Enable GPIO driver for DH89xxCC")
Co-developed-by: Christian Lamparter <chunkeey@gmail.com>
Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
Signed-off-by: Chris Blake <chrisrblake93@gmail.com>
Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Link: https://lore.kernel.org/r/20210810004021.2538308-1-chrisrblake93@gmail.com
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-08-12 09:26:28 +02:00
David E. Box
e184b1e589 platform/x86/intel: Move Intel PMT drivers to new subfolder
Move all Intel Platform Monitoring Technology drivers to
drivers/platform/x86/intel/pmt.

Signed-off-by: David E. Box <david.e.box@linux.intel.com>
Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20210727164928.3171521-1-david.e.box@linux.intel.com
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-08-06 14:04:43 +02:00
Andy Shevchenko
72fbcac2f4 platform/x86: intel_cht_int33fe: Move to its own subfolder
Since we have started collecting Intel x86 specific drivers in their own
folder, move intel_cht_int33fe to its own subfolder there.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20210618125516.53510-8-andriy.shevchenko@linux.intel.com
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-06-22 11:32:30 +02:00
Andy Shevchenko
8bd836feb6 platform/x86: intel_skl_int3472: Move to intel/ subfolder
Start collecting Intel x86 related drivers in its own subfolder.
Move intel_skl_int3472 first.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20210618125516.53510-7-andriy.shevchenko@linux.intel.com
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-06-22 11:32:02 +02:00
Daniel Scally
5de691bffe platform/x86: Add intel_skl_int3472 driver
ACPI devices with _HID INT3472 are currently matched to the tps68470
driver, however this does not cover all situations in which that _HID
occurs. We've encountered three possibilities:

1. On Chrome OS devices, an ACPI device with _HID INT3472 (representing
a physical TPS68470 device) that requires a GPIO and OpRegion driver
2. On devices designed for Windows, an ACPI device with _HID INT3472
(again representing a physical TPS68470 device) which requires GPIO,
Clock and Regulator drivers.
3. On other devices designed for Windows, an ACPI device with _HID
INT3472 which does **not** represent a physical TPS68470, and is instead
used as a dummy device to group some system GPIO lines which are meant
to be consumed by the sensor that is dependent on this entry.

This commit adds a new module, registering a platform driver to deal
with the 3rd scenario plus an i2c driver to deal with #1 and #2, by
querying the CLDB buffer found against INT3472 entries to determine
which is most appropriate.

Suggested-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Daniel Scally <djrscally@gmail.com>
Link: https://lore.kernel.org/r/20210603224007.120560-6-djrscally@gmail.com
[hdegoede@redhat.com Make skl_int3472_tps68470_calc_type() static]
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-06-16 17:49:53 +02:00
Mark Pearson
a40cd7ef22 platform/x86: think-lmi: Add WMI interface support on Lenovo platforms
For Lenovo platforms that support a WMI interface to the BIOS add
support, using the firmware-attributes class, to allow users to access
and modify various BIOS related settings.

Signed-off-by: Mark Pearson <markpearson@lenovo.com>
Link: https://lore.kernel.org/r/20210530223111.25929-3-markpearson@lenovo.com
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-06-16 17:47:52 +02:00
Mark Pearson
17b707fe5f platform/x86: firmware_attributes_class: Create helper file for handling firmware-attributes class registration events
This offers shared code for registering the firmware_attributes_class,
which is used by the Dell and Lenovo WMI management drivers.

Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Mark Pearson <markpearson@lenovo.com>
Link: https://lore.kernel.org/r/20210530223111.25929-1-markpearson@lenovo.com
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-06-16 17:47:51 +02:00
Mario Limonciello
a558ea42c0 platform/x86: Rename hp-wireless to wireless-hotkey
This driver was originally intended to support some HP laptops, but
later support was added for Xioami and AMD laptops.

Rename it to make it clear that it supports a larger variety of
systems.

Signed-off-by: Mario Limonciello <mario.limonciello@amd.com>
Link: https://lore.kernel.org/r/20210519174405.30155-1-mario.limonciello@amd.com
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-06-16 17:47:49 +02:00
Thomas Weißschuh
572931972c platform/x86: add Gigabyte WMI temperature driver
Tested with
* X570 I Aorus Pro Wifi (rev 1.0)
* B550M DS3H
* B550 Gaming X V2 (rev.1.x)
* Z390 I AORUS PRO WIFI (rev. 1.0)

Those mainboards contain an ITE chips for management and
monitoring.

They could also be handled by drivers/hwmon/i87.c.
But the SuperIO range used by i87 is already claimed and used by the
firmware.

The following warning is printed at boot:

kernel: ACPI Warning: SystemIO range 0x0000000000000A45-0x0000000000000A46 conflicts with OpRegion 0x0000000000000A45-0x0000000000000A46 (\GSA1.SIO1) (20200528/utaddress-204)
kernel: ACPI: This conflict may cause random problems and system instability
kernel: ACPI: If an ACPI driver is available for this device, you should use it instead of the native driver

This driver implements such an ACPI driver.

Unfortunately not all sensor registers are handled by the firmware and even
less are exposed via WMI.

Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
Reviewed-by: Guenter Roeck <linux@roeck-us.net>
Link: https://lore.kernel.org/r/20210412123513.628901-1-linux@weissschuh.net
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-04-13 10:13:49 +02:00
Andrea.Ho
3d904005f6 platform/x86: add support for Advantech software defined button
Advantech sw_button is a ACPI event trigger button.

With this driver, we can report KEY_PROG1 on the
Advantech Tabletop Network Appliances products and it has been
tested in FWA1112VC.

Add the software define button support to report EV_REP key_event
(KEY_PROG1) by pressing button that could be get on user
interface and trigger the customized actions.

Signed-off-by: Andrea.Ho <Andrea.Ho@advantech.com.tw>
Link: https://lore.kernel.org/r/20210319034427.23222-1-andrea.cs97g@nctu.edu.tw
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-04-07 19:46:56 +02:00
Mario Limonciello
f1e1ea5167 platform/x86: Move all dell drivers to their own subdirectory
A user without a Dell system doesn't need to pick any of these
drivers.

Users with a Dell system can enable this submenu and all drivers
behind it will be enabled.

Suggested-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Mario Limonciello <mario.limonciello@dell.com>
Link: https://lore.kernel.org/r/20210203195832.2950605-1-mario.limonciello@dell.com
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2021-02-04 13:23:55 +01:00