summaryrefslogtreecommitdiffstats
path: root/drivers/platform
Commit message (Collapse)AuthorAgeFilesLines
* sched/headers: Prepare for new header dependencies before moving code to ↵Ingo Molnar2017-03-021-0/+1
| | | | | | | | | | | | | | | | | | | | <linux/sched/loadavg.h> We are going to split <linux/sched/loadavg.h> out of <linux/sched.h>, which will have to be picked up from a couple of .c files. Create a trivial placeholder <linux/sched/topology.h> file that just maps to <linux/sched.h> to make this patch obviously correct and bisectable. Include the new header in the files that are going to need it. Acked-by: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: linux-kernel@vger.kernel.org Signed-off-by: Ingo Molnar <mingo@kernel.org>
* Merge tag 'platform-drivers-x86-v4.11-1' of ↵Linus Torvalds2017-02-2517-320/+951
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://git.infradead.org/linux-platform-drivers-x86 Pull x86 platform driver updates from Darren Hart: "Big picture: - New intel_turbo_max_3 driver, providing max core frequency information to the scheduler. Intel PMC APL support, s0ix read API, and fixes. - New Silead touchscreen platform touchscreen descriptions. Additional hotkey support for the intel-hid driver. - New model support for dell-laptop and hp_accel. - Several cleanups, especially to the fujitsu-laptop and intel_mid_powerbtn drivers. Detail summary: platorm/x86: - silead depends on I2C being built-in - add support for devices with Silead touchscreens - Support Turbo Boost Max 3.0 for non HWP systems intel_turbo_max_3: - make it explicitly non-modular dell-laptop: - Add Latitude 7480 and others to the DMI whitelist intel-hid: - Support 5 button array thinkpad_acpi: - Call led_classdev_notify_brightness_hw_changed on kbd brightness change - Use brightness_set_blocking callback for LEDs - Stop setting led_classdev brightness directly acer-wmi: - add another KEY_WLAN keycode - Inform firmware that RF Button Driver is active - setup accelerometer when machine has appropriate notify event asus-wireless: - Fix indentation - Use per-HID HSWC parameters intel_pmc_ipc: - Add APL PMC PCI Id - read s0ix residency API - Remove unused iTCO_version variable alienware-wmi: - Remove header duplicate intel_pmc_core: - fix out-of-bounds accesses on stack intel_mid_powerbtn: - Use SCU IPC directly - Unify IRQ acknowledgment - Move comment to where it belongs - Unify PBSTATUS access - Remove snail address - Sort headers alphabetically - Join string literals - Enable driver for Merrifield - Acknowledge interrupts - Factor out mfld_ack() - Introduce driver data - Substitute mfld by mid - Convert to use devm_*() fujitsu-laptop: - make hotkey handling functions more similar - break up complex loop condition - move keycode processing to separate functions - decrease indentation in acpi_fujitsu_hotkey_notify() - simplify logolamp_get() - rework logolamp_set() to properly handle errors - set default trigger for radio LED to rfkill-any dell-smbios: - Auto-select as needed intel_mid_thermal: - Fix module autoload - Remove duplicated platform device ID mlx-platform: - mlxcpld-hotplug driver style fixes hp_accel: - Add support for HP ZBook 17" * tag 'platform-drivers-x86-v4.11-1' of git://git.infradead.org/linux-platform-drivers-x86: (45 commits) platform/x86: intel_turbo_max_3: make it explicitly non-modular platform/x86: dell-laptop: Add Latitude 7480 and others to the DMI whitelist platform/x86: intel-hid: Support 5 button array platform/x86: thinkpad_acpi: Call led_classdev_notify_brightness_hw_changed on kbd brightness change platform/x86: thinkpad_acpi: Use brightness_set_blocking callback for LEDs platform/x86: thinkpad_acpi: Stop setting led_classdev brightness directly leds: class: Add new optional brightness_hw_changed attribute platform/x86: acer-wmi: add another KEY_WLAN keycode platform/x86: acer-wmi: Inform firmware that RF Button Driver is active platform/x86: asus-wireless: Fix indentation platform/x86: asus-wireless: Use per-HID HSWC parameters platform/x86: intel_pmc_ipc: Add APL PMC PCI Id platform/x86: intel_pmc_ipc: read s0ix residency API platform/x86: alienware-wmi: Remove header duplicate platform/x86: intel_mid_powerbtn: Use SCU IPC directly platform/x86: intel_mid_powerbtn: Unify IRQ acknowledgment platform/x86: intel_mid_powerbtn: Move comment to where it belongs platform/x86: intel_mid_powerbtn: Unify PBSTATUS access platform/x86: intel_pmc_core: fix out-of-bounds accesses on stack platform/x86: silead depends on I2C being built-in ...
| * platform/x86: intel_turbo_max_3: make it explicitly non-modularPaul Gortmaker2017-02-241-6/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The Kconfig currently controlling compilation of this code is: drivers/platform/x86/Kconfig:config INTEL_TURBO_MAX_3 drivers/platform/x86/Kconfig: bool "Intel Turbo Boost Max Technology 3.0 enumeration driver" ...meaning that it currently is not being built as a module by anyone. Lets remove the couple traces of modular infrastructure use, so that when reading the driver there is no doubt it is builtin-only. Also note that MODULE_DEVICE_TABLE is a no-op for non-modular code. We also delete the MODULE_LICENSE tag etc. since all that information was (or is now) contained at the top of the file in the comments. We do uncover some implicit includes during build coverage that were hidden behind the module.h which pulls in a lot of dependants. Cc: Andy Shevchenko <andy@infradead.org> Cc: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> Cc: platform-driver-x86@vger.kernel.org Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Darren Hart <dvhart@linux.intel.com>
| * platform/x86: dell-laptop: Add Latitude 7480 and others to the DMI whitelistAlex Hung2017-02-241-0/+6
| | | | | | | | | | | | | | | | This is to support Latitude 7480 and many other newer Dell laptops. Signed-off-by: Alex Hung <alex.hung@canonical.com> Reviewed-by: Pali Rohár <pali.rohar@gmail.com> Signed-off-by: Darren Hart <dvhart@linux.intel.com>
| * platform/x86: intel-hid: Support 5 button arrayAlex Hung2017-02-241-5/+91
| | | | | | | | | | | | | | | | | | | | | | | | | | New firmwares include a feature called 5 button array that supports super key, volume up/down, rotation lock and power button. Support for this feature is required to fix power button on some recent systems. This patch was tested on a Dell Latitude 7480. Signed-off-by: Alex Hung <alex.hung@canonical.com> Reviewed-by: Michał Kępień <kernel@kempniu.pl> Signed-off-by: Darren Hart <dvhart@linux.intel.com>
| * platform/x86: thinkpad_acpi: Call led_classdev_notify_brightness_hw_changed ↵Hans de Goede2017-02-241-4/+38
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | on kbd brightness change Make thinkpad_acpi call led_classdev_notify_brightness_hw_changed on the kbd_led led_classdev registered by thinkpad_acpi when the kbd backlight brightness is changed through the hotkey. This will allow userspace to monitor (poll) for brightness changes on these LEDs caused by the hotkey. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Acked-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Acked-by: Pavel Machek <pavel@ucw.cz>
| * platform/x86: thinkpad_acpi: Use brightness_set_blocking callback for LEDsHans de Goede2017-02-241-64/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Now a days the LED core can take care of executing brightness_set from a workqueue if it needs to sleep, make use of this and remove a bunch of DIY code for this. Since this commit removes the workqueue usage for LEDs, the led_sysfs_blink_set callback may now also sleep, this is fine. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Acked-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Acked-by: Pavel Machek <pavel@ucw.cz>
| * platform/x86: thinkpad_acpi: Stop setting led_classdev brightness directlyHans de Goede2017-02-241-3/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There is no need to set the led_classdev's brightness value from its set_brightness callback, this is taken care of by the led-core and thinkpad_acpi really should not be mucking with it. Note that kbdlight_set_level_and_update() is still used by the old thinpad_acpi specific sysfs interface for the led, so we cannot remove it. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Acked-by: Henrique de Moraes Holschuh <hmh@hmh.eng.br> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Acked-by: Pavel Machek <pavel@ucw.cz>
| * platform/x86: acer-wmi: add another KEY_WLAN keycodeChris Chiu2017-02-241-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Now that we have informed the firmware that the RF Button driver is active, laptops such as the Acer TravelMate P238-M will generate a WMI key event with code 0x86 when the Fn+F3 airplane mode key is pressed. Add this keycode to the table so that it is converted to an appropriate input event. Signed-off-by: Chris Chiu <chiu@endlessm.com> Signed-off-by: Daniel Drake <drake@endlessm.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
| * platform/x86: acer-wmi: Inform firmware that RF Button Driver is activeChris Chiu2017-02-241-16/+58
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The same method to activate LM(Launch Manager) can also be used to activate the RF Button driver with different bit toggled in the same lm_status. To express that many functions this byte field can achieve, rename the lm_status to app_status. And also the app_mask is the bit mask which specifically indicate which bits are going to be changed. This solves a problem where the AR9565 wifi included in the Acer Aspire ES1-421 is permanently hard blocked according to the rfkill GPIO read by ath9k. Signed-off-by: Chris Chiu <chiu@endlessm.com> Signed-off-by: Daniel Drake <drake@endlessm.com> Reviewed-by: Lee, Chun-Yi <jlee@suse.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
| * platform/x86: asus-wireless: Fix indentationJoão Paulo Rechi Vita2017-02-241-2/+1
| | | | | | | | | | | | | | | | Fix indentation problem introduced when this driver was first merged into the kernel. Signed-off-by: João Paulo Rechi Vita <jprvita@endlessm.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
| * platform/x86: asus-wireless: Use per-HID HSWC parametersJoão Paulo Rechi Vita2017-02-241-15/+42
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Some Asus machines use 0x4/0x5 as their LED on/off values, while others use 0x0/0x1, as shown in the DSDT excerpts below. Luckily it seems this behavior is tied to different HIDs, after looking at 44 DSDTs from different Asus models. Another small difference is that a few of them call GWBL instead of OWGS, and SWBL instead of OWGD. That does not seem to make a difference for asus-wireless, and is additional reasoning to not try to call these methods directly. Device (ASHS) | Device (ASHS) { | { Name (_HID, "ATK4002") | Name (_HID, "ATK4001") Method (HSWC, 1, Serialized) | Method (HSWC, 1, Serialized) { | { If ((Arg0 < 0x02)) | If ((Arg0 < 0x02)) { | { OWGD (Arg0) | OWGD (Arg0) Return (One) | Return (One) } | } If ((Arg0 == 0x02)) | { | If ((Arg0 == 0x02)) Local0 = OWGS () | { If (Local0) | Return (OWGS ()) { | } Return (0x05) | } | If ((Arg0 == 0x03)) Else | { { | Return (0xFF) Return (0x04) | } } | } | If ((Arg0 == 0x80)) If ((Arg0 == 0x03)) | { { | Return (One) Return (0xFF) | } } | } If ((Arg0 == 0x04)) | Method (_STA, 0, NotSerialized) { | { OWGD (Zero) | If ((MSOS () >= OSW8)) Return (One) | { } | Return (0x0F) If ((Arg0 == 0x05)) | } { | Else OWGD (One) | { Return (One) | Return (Zero) } | } If ((Arg0 == 0x80)) | } { | } Return (One) | } | } | Method (_STA, 0, NotSerialized) | { | If ((MSOS () >= OSW8)) | { | Return (0x0F) | } | Else | { | Return (Zero) | } | } | } | Signed-off-by: João Paulo Rechi Vita <jprvita@endlessm.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
| * platform/x86: intel_pmc_ipc: Add APL PMC PCI IdRajneesh Bhardwaj2017-02-241-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch adds the PCI Device id for Power Management Controller on Intel Apollo Lake platforms. Intel PMC IPC Driver loads as a platform driver on Apollo Lake platforms since Intel BIOS hides the PCI Configuration space for 0:13:1 and re-enumerates it as ACPI device (INT34D2). The correct PCI Device ID should be added if some platform firmware choses to enumerate the device via PCI space. Signed-off-by: Rajneesh Bhardwaj <rajneesh.bhardwaj@intel.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
| * platform/x86: intel_pmc_ipc: read s0ix residency APIShanth Murthy2017-02-241-6/+58
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch adds a new API to indicate S0ix residency in usec. It utilizes the PMC Global Control Registers (GCR) to read deep and shallow S0ix residency. PMC MMIO resources: o Lower 4kB: IPC1 (PMC inter-processor communication) interface o Upper 4kB: GCR (Global Control Registers) This enables the power management framework to take corrective actions when the platform fails to enter S0ix after kernel freeze as part of the suspend to idle flow. (echo freeze > /sys/power/state). This is expected to be used with a S0ix failsafe framework such as: <https://lwn.net/Articles/689505/> [rajneesh: folded in "fix division in 32-bit case" from Andy Shevchenko] Signed-off-by: Rajneesh Bhardwaj <rajneesh.bhardwaj@intel.com> Signed-off-by: Shanth Murthy <shanth.murthy@intel.com> [andy: fixed kbuild error, removed "total" from variables, fixed macro] Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
| * platform/x86: alienware-wmi: Remove header duplicateAndy Shevchenko2017-02-241-1/+0
| | | | | | | | | | | | No need to #include <linux/acpi.h> twice. Remove second occurrence. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
| * platform/x86: intel_mid_powerbtn: Use SCU IPC directlyAndy Shevchenko2017-02-241-2/+2
| | | | | | | | | | | | | | | | | | | | On older Intel MID platforms is using SCU IPC library beneath MSIC calls. To make access unified between old and new platforms use SCU IPC library directly. It's safe since serialization is done in the library. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
| * platform/x86: intel_mid_powerbtn: Unify IRQ acknowledgmentAndy Shevchenko2017-02-241-12/+7
| | | | | | | | | | | | | | The IRQ on Intel Merrifield can be acknowledged in the similar way it's done for previous MID platforms. Unify acknowledgment via SCU IPC. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
| * platform/x86: intel_mid_powerbtn: Move comment to where it belongsAndy Shevchenko2017-02-141-10/+10
| | | | | | | | | | | | | | The comments is about initial interrupt acknowledgment only. So, move it back to where it belongs. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
| * platform/x86: intel_mid_powerbtn: Unify PBSTATUS accessAndy Shevchenko2017-02-141-28/+13
| | | | | | | | | | | | | | | | The status register on Intel Merrifield can be read in the similar way it's done for previous MID platforms. Unify access to PBSTATUS register via SCU IPC. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
| * platform/x86: intel_pmc_core: fix out-of-bounds accesses on stackAndrey Ryabinin2017-02-141-4/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | pmc_core_mtpmc_link_status() an pmc_core_check_read_lock_bit() use test_bit() on local 32-bit variable. This causes out-of-bounds access since test_bit() expects object at least of 'unsigned long' size: BUG: KASAN: stack-out-of-bounds in pmc_core_probe+0x3aa/0x3b0 Call Trace: __asan_report_load_n_noabort+0x5c/0x80 pmc_core_probe+0x3aa/0x3b0 local_pci_probe+0xf9/0x1e0 pci_device_probe+0x27b/0x350 driver_probe_device+0x419/0x830 __driver_attach+0x15f/0x1d0 bus_for_each_dev+0x129/0x1d0 driver_attach+0x42/0x70 bus_add_driver+0x385/0x690 driver_register+0x1a9/0x3d0 __pci_register_driver+0x1a2/0x290 intel_pmc_core_driver_init+0x19/0x1b do_one_initcall+0x12e/0x280 kernel_init_freeable+0x57c/0x623 kernel_init+0x13/0x140 ret_from_fork+0x2e/0x40 Fix this by open coding bit test. While at it, also refactor this code a little bit. Fixes: 173943b3dae5 ("platform/x86: intel_pmc_core: ModPhy core lanes pg status") Signed-off-by: Andrey Ryabinin <aryabinin@virtuozzo.com> [andy: reverted not related changes, used BIT() macro] Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
| * platform/x86: silead depends on I2C being built-inArnd Bergmann2017-02-141-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The new driver cannot be a loadable module, so if I2C is loadable, we get this link error: drivers/platform/built-in.o: In function `silead_ts_dmi_init': silead_dmi.c:(.init.text+0x2ef): undefined reference to `i2c_bus_type' This makes the Kconfig dependency stricter to require I2C=y. Fixes: 9eeda3897a85 ("platform/x86: add support for devices with Silead touchscreens") Signed-off-by: Arnd Bergmann <arnd@arndb.de> Acked-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
| * platform/x86: add support for devices with Silead touchscreensHans de Goede2017-02-143-0/+148
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On ACPI based tablets, the ACPI touchscreen node only contains info on the gpio and the irq, and is missing any info on the axis. This info is expected to be built into the tablet model specific version of the driver shipped with the os-image for the device. Add support for getting the missing info from a table built into the driver, using dmi data to identify which entry of the table to use and add info for the CUBE iwork8 Air and Jumper EZpad mini3 tablets on which this code was tested / developed. BugLink: https://bugzilla.kernel.org/show_bug.cgi?id=187531 Signed-off-by: Hans de Goede <hdegoede@redhat.com> [dmitry.torokhov@gmail.com: Move to platform/x86] Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com> Acked-by: Andy Shevchenko <andy.shevchenko@gmail.com> [andy: fixed merge conflict] Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
| * platform/x86: intel_mid_powerbtn: Remove snail addressAndy Shevchenko2017-02-041-5/+4
| | | | | | | | | | | | | | | | | | | | The snail address is subject to change. This already happened once. Remove the address completely from the file to avoid potential noise when update. While here, adjust copyright years and list authors. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
| * platform/x86: intel_mid_powerbtn: Sort headers alphabeticallyAndy Shevchenko2017-02-041-4/+4
| | | | | | | | | | | | Sort header inclusion block in alphabetical order. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
| * platform/x86: intel_mid_powerbtn: Join string literalsAndy Shevchenko2017-02-041-8/+9
| | | | | | | | | | | | | | There is no need and bad practice for debugging to split string literals. Join them back. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
| * platform/x86: intel_mid_powerbtn: Enable driver for MerrifieldAndy Shevchenko2017-02-041-0/+56
| | | | | | | | | | | | | | Enable this driver to handle events from Basin Cove PMIC, which is installed on Intel Merrifield platform. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
| * platform/x86: intel_mid_powerbtn: Acknowledge interruptsAndy Shevchenko2017-02-041-0/+1
| | | | | | | | | | | | | | Some platforms require interrupt to be acknowledged by clearing MSIC_PWRBTNM bit in interrupt level 1 mask register. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
| * platform/x86: intel_mid_powerbtn: Factor out mfld_ack()Andy Shevchenko2017-02-041-11/+18
| | | | | | | | | | | | | | Move Intel Medfield specific code to another callback, which will be used later. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
| * platform/x86: intel_mid_powerbtn: Introduce driver dataAndy Shevchenko2017-02-041-6/+56
| | | | | | | | | | | | | | | | | | | | This is preparatory patch to extend the driver in order to support other Intel MID platform. Here the new driver data structure is introduced with split of ->pbstat() callback. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
| * platform/x86: intel_mid_powerbtn: Substitute mfld by midAndy Shevchenko2017-02-041-11/+11
| | | | | | | | | | | | | | Replace all occurrences of mfld by mid to emphasize that driver is used for Intel MID platforms. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
| * platform/x86: intel_mid_powerbtn: Convert to use devm_*()Andy Shevchenko2017-02-041-20/+9
| | | | | | | | | | | | | | Convert driver to use managed resources. This eliminates error path boilerplate and makes code neat. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
| * platform/x86: Support Turbo Boost Max 3.0 for non HWP systemsSrinivas Pandruvada2017-02-043-0/+163
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On platforms supporting Intel Turbo Boost Max Technology 3.0, the maximum turbo frequencies (turbo ratio) of some cores in a CPU package may be higher than the other cores in the same package. In that case, better performance can be achieved by making the scheduler prefer to run tasks on the CPUs with higher max turbo frequencies. On Intel® Broadwell Xeon systems, it is optional to turn on HWP (Hardware P-States). When HWP is not turned on, the BIOS doesn't present required CPPC (Collaborative Processor Performance Control) tables. This table is used to get the per CPU core maximum performance ratio and inform scheduler (in cpufreq/intel_pstate driver). On such systems the maximum performance ratio can be read via over clocking (OC) mailbox interface for each CPU. This interface is not architectural and can change for every model of processors. This driver reads maximum performance ratio of each CPU and set up the scheduler priority metrics. In this way scheduler can prefer CPU with higher performance to schedule tasks. Signed-off-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> Signed-off-by: Darren Hart <dvhart@linux.intel.com>
| * platform/x86: fujitsu-laptop: make hotkey handling functions more similarMichał Kępień2017-02-041-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | Make two minor tweaks to acpi_fujitsu_hotkey_press() to make it more similar to acpi_fujitsu_hotkey_release(): * call vdbg_printk() after reporting the input event, * return immediately when kfifo_in_locked() fails. Signed-off-by: Michał Kępień <kernel@kempniu.pl> Acked-by: Jonathan Woithe <jwoithe@just42.net> Signed-off-by: Darren Hart <dvhart@linux.intel.com>
| * platform/x86: fujitsu-laptop: break up complex loop conditionMichał Kępień2017-02-041-3/+5
| | | | | | | | | | | | | | | | | | | | | | The loop condition in acpi_fujitsu_hotkey_release() includes an assignment, a four-argument function call and a comparison, making it hard to read. Separate the assignment from the comparison to improve readability. Signed-off-by: Michał Kępień <kernel@kempniu.pl> Acked-by: Jonathan Woithe <jwoithe@just42.net> Signed-off-by: Darren Hart <dvhart@linux.intel.com>
| * platform/x86: fujitsu-laptop: move keycode processing to separate functionsMichał Kępień2017-02-041-33/+43
| | | | | | | | | | | | | | | | | | | | | | | | | | acpi_fujitsu_hotkey_notify() is pretty deeply nested, which hurts readability. Move the keycode processing part to two separate functions to make the code easier to understand and save a few line breaks. Rename variable keycode_r to keycode as there is no longer any need to differentiate between the two. Tweak indentations to make checkpatch happy. Signed-off-by: Michał Kępień <kernel@kempniu.pl> Acked-by: Jonathan Woithe <jwoithe@just42.net> Signed-off-by: Darren Hart <dvhart@linux.intel.com>
| * platform/x86: fujitsu-laptop: decrease indentation in ↵Michał Kępień2017-02-041-77/+75
| | | | | | | | | | | | | | | | | | | | | | | | acpi_fujitsu_hotkey_notify() acpi_fujitsu_hotkey_notify() is pretty deeply nested, which hurts readability. Strip off one level of indentation by returning early when the event code supplied as argument is not ACPI_FUJITSU_NOTIFY_CODE1. Signed-off-by: Michał Kępień <kernel@kempniu.pl> Acked-by: Jonathan Woithe <jwoithe@just42.net> Signed-off-by: Darren Hart <dvhart@linux.intel.com>
| * platform/x86: fujitsu-laptop: simplify logolamp_get()Michał Kępień2017-02-041-11/+11
| | | | | | | | | | | | | | | | | | | | | | Now that call_fext_func() is invoked by logolamp_set() for both LOGOLAMP_POWERON and LOGOLAMP_ALWAYS for every brightness value, logolamp_get() can be simplified to decrease indentation and number of local variables. Signed-off-by: Michał Kępień <kernel@kempniu.pl> Acked-by: Jonathan Woithe <jwoithe@just42.net> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
| * platform/x86: fujitsu-laptop: rework logolamp_set() to properly handle errorsMichał Kępień2017-02-041-9/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | Potential errors returned by some call_fext_func() calls inside logolamp_set() are currently ignored. Rework logolamp_set() to properly handle them. This causes one more call_fext_func() call to be made in the LED_OFF case, though one could argue that this is logically the right thing to do (even though the extra call is not needed to shut the LED off). Signed-off-by: Michał Kępień <kernel@kempniu.pl> Acked-by: Jonathan Woithe <jwoithe@just42.net> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
| * platform/x86: dell-smbios: Auto-select as neededJean Delvare2017-02-031-6/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Dell-smbios is a helper module, it serves no purpose on its own, so do not present it as an option to the user. Instead, select it automatically whenever a driver which needs it is selected. Also select DCDBAS as needed, instead of depending on it, so that the Dell driver options are always visible. As a clean-up, I removed the "default n" statements as they are not needed (n is the default default.) Signed-off-by: Jean Delvare <jdelvare@suse.de> Cc: Michał Kępień <kernel@kempniu.pl> Cc: Pali Rohár <pali.rohar@gmail.com> Cc: Darren Hart <dvhart@infradead.org> Cc: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
| * platform/x86: intel_pmc_ipc: Remove unused iTCO_version variableGuenter Roeck2017-02-031-2/+0
| | | | | | | | | | | | | | | | iTCO_version was there since the driver was introduced but never used. Drop it. Signed-off-by: Guenter Roeck <linux@roeck-us.net> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
| * platform/x86: intel_mid_thermal: Fix module autoloadJavier Martinez Canillas2017-02-031-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If the driver is built as a module, autoload won't work because the module alias information is not filled. So user-space can't match the registered device with the corresponding module. Export the module alias information using the MODULE_DEVICE_TABLE() macro. Before this patch: $ modinfo drivers/platform/x86/intel_mid_thermal.ko | grep alias $ After this patch: $ modinfo drivers/platform/x86/intel_mid_thermal.ko | grep alias alias: platform:msic_thermal Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
| * platform/x86: intel_mid_thermal: Remove duplicated platform device IDJavier Martinez Canillas2017-02-031-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Commit 3fca3d3d5075 ("platform-x86: intel_mid_thermal: add msic_thermal alias") added a "msic_thermal" entry to the driver's platform device ID table since that was the platform dev name registered in some platforms and the only dev in the platform table was "msic_sensor" (DRIVER_NAME). But then commit 634830704d80 ("x86/mid/thermal: Add msic_thermal alias") changed DRIVER_NAME from "msic_sensor" to "msic_thermal", and so there's now duplicated entries in the platform device ID table. Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
| * platform/x86: mlx-platform: mlxcpld-hotplug driver style fixesVadim Pasternak2017-02-031-34/+50
| | | | | | | | | | | | | | | | | | | | | | The patch contains several styling fixes: - Make names of hotplug devices shorter; - Change register offset assignment to defines; - Add defines for the all event masks; - Use PLATFORM_DEVID_NONE instead of -1; Signed-off-by: Vadim Pasternak <vadimp@mellanox.com> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
| * platform/x86: hp_accel: Add support for HP ZBook 17Ladislav Michl2017-02-031-0/+1
| | | | | | | | | | | | | | HP ZBook 17 laptop needs a non-standard mapping (xy_swap_yz_inverted). Signed-off-by: Ladislav Michl <ladis@linux-mips.org> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
| * platform/x86: acer-wmi: setup accelerometer when machine has appropriate ↵Lee, Chun-Yi2017-02-031-4/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | notify event The accelerometer event relies on the ACERWMID_EVENT_GUID notify. So, this patch changes the codes to setup accelerometer input device when detected ACERWMID_EVENT_GUID. It avoids that the accel input device created on every Acer machines. In addition, patch adds a clearly parsing logic of accelerometer hid to acer_wmi_get_handle_cb callback function. It is positive matching the "SENR" name with "BST0001" device to avoid non-supported hardware. Reported-by: Bjørn Mork <bjorn@mork.no> Cc: Darren Hart <dvhart@infradead.org> Signed-off-by: Lee, Chun-Yi <jlee@suse.com> [andy: slightly massage commit message] Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
| * platform/x86: fujitsu-laptop: set default trigger for radio LED to rfkill-anyMicha? K?pie?2017-02-031-0/+1
| | | | | | | | | | | | | | | | | | | | The "radio components indicator" LED present in Lifebook E734/E744/E754 should be lit when any radio transmitter is enabled, so set its default trigger to rfkill-any. Signed-off-by: Michał Kępień <kernel@kempniu.pl> Acked-by: Jonathan Woithe <jwoithe@just42.net> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
* | Merge tag 'clk-for-linus' of ↵Linus Torvalds2017-02-253-0/+538
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/clk/linux Pull clk updates from Stephen Boyd: "The usual collection of new drivers, non-critical fixes, and updates to existing clk drivers. The bulk of the work is on Allwinner and Rockchip SoCs, but there's also an Intel Atom driver in here too. New Drivers: - Tegra BPMP firmware - Hisilicon hi3660 SoCs - Rockchip rk3328 SoCs - Intel Atom PMC - STM32F746 - IDT VersaClock 5P49V5923 and 5P49V5933 - Marvell mv98dx3236 SoCs - Allwinner V3s SoCs Removed Drivers: - Samsung Exynos4415 SoCs Updates: - Migrate ABx500 to OF - Qualcomm IPQ4019 CPU clks and general PLL support - Qualcomm MSM8974 RPM - Rockchip non-critical fixes and clk id additions - Samsung Exynos4412 CPUs - Socionext UniPhier NAND and eMMC support - ZTE zx296718 i2s and other audio clks - Renesas CAN and MSIOF clks for R-Car M3-W - Renesas resets for R-Car Gen2 and Gen3 and RZ/G1 - TI CDCE913, CDCE937, and CDCE949 clk generators - Marvell Armada ap806 CPU frequencies - STM32F4* I2S/SAI support - Broadcom BCM2835 DSI support - Allwinner sun5i and A80 conversion to new style clk bindings" * tag 'clk-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/clk/linux: (130 commits) clk: renesas: mstp: ensure register writes complete clk: qcom: Do not drop device node twice clk: mvebu: adjust clock handling for the CP110 system controller clk: mvebu: Expand mv98dx3236-core-clock support clk: zte: add i2s clocks for zx296718 clk: sunxi-ng: sun9i-a80: Fix wrong pointer passed to PTR_ERR() clk: sunxi-ng: select SUNXI_CCU_MULT for sun5i clk: sunxi-ng: Check kzalloc() for errors and cleanup error path clk: tegra: Add BPMP clock driver clk: uniphier: add eMMC clock for LD11 and LD20 SoCs clk: uniphier: add NAND clock for all UniPhier SoCs ARM: dts: sun9i: Switch to new clock bindings clk: sunxi-ng: Add A80 Display Engine CCU clk: sunxi-ng: Add A80 USB CCU clk: sunxi-ng: Add A80 CCU clk: sunxi-ng: Support separately grouped PLL lock status register clk: sunxi-ng: mux: Get closest parent rate possible with CLK_SET_RATE_PARENT clk: sunxi-ng: mux: honor CLK_SET_RATE_NO_REPARENT flag clk: sunxi-ng: mux: Fix determine_rate for mux clocks with pre-dividers clk: qcom: SDHCI enablement on Nexus 5X / 6P ...
| * | platform/x86: Enable Atom PMC platform clocksIrina Tirdea2017-01-262-3/+77
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The BayTrail and CherryTrail platforms provide platform clocks through their Power Management Controller (PMC). The SoC supports up to 6 clocks (PMC_PLT_CLK[0..5]) with a frequency of either 19.2 MHz (PLL) or 25 MHz (XTAL) for BayTrail and a frequency of 19.2 MHz (XTAL) for CherryTrail. These clocks are available for general system use, where appropriate. For example, the usage for platform clocks suggested in the datasheet is the following: PLT_CLK[0..2] - Camera PLT_CLK[3] - Audio Codec PLT_CLK[4] - PLT_CLK[5] - COMMs Signed-off-by: Irina Tirdea <irina.tirdea@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Acked-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
| * | arch/x86/platform/atom: Move pmc_atom to drivers/platform/x86Irina Tirdea2017-01-263-0/+464
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The pmc_atom driver does not contain any architecture specific code. It only enables the SoC Power Management Controller driver for BayTrail and CherryTrail platforms. Move the pmc_atom driver from arch/x86/platform/atom to drivers/platform/x86. Also clean-up and reorder include files by alphabetical order in pmc_atom.h Signed-off-by: Irina Tirdea <irina.tirdea@intel.com> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Acked-by: Thomas Gleixner <tglx@linutronix.de> Acked-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
* | | Merge tag 'mfd-for-linus-4.11' of ↵Linus Torvalds2017-02-231-0/+5
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd Pull MFD updates from Lee Jones: "Core Frameworks: - Add new !TOUCHSCREEN_SUN4I dependency for SUN4I_GPADC - List include/dt-bindings/mfd/* to files supported in MAINTAINERS New Drivers: - Intel Apollo Lake SPI NOR - ST STM32 Timers (Advanced, Basic and PWM) - Motorola 6556002 CPCAP (PMIC) New Device Support: - Add support for AXP221 to axp20x - Add support for Intel Gemini Lake to intel-lpss-pci - Add support for MT6323 LED to mt6397-core - Add support for COMe-bBD#, COMe-bSL6, COMe-bKL6, COMe-cAL6 and COMe-cKL6 to kempld-core New Functionality: - Add support for Analog CODAC to sun6i-prcm - Add support for Watchdog to lpc_ich Fix-ups: - Error handling improvements; axp288_charger, axp20x, ab8500-sysctrl - Adapt platform data handling; axp20x - IRQ handling improvements; arizona, axp20x - Remove superfluous code; arizona, axp20x, lpc_ich - Trivial coding style/spelling fixes; axp20x, abx500, mfd.txt - Regmap fix-ups; axp20x - DT changes; mfd.txt, aspeed-lpc, aspeed-gfx, ab8500-core, tps65912, mt6397 - Use new I2C probing mechanism; max77686 - Constification; rk808 Bug Fixes: - Stop data transfer whilst suspended; cros_ec" * tag 'mfd-for-linus-4.11' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd: (43 commits) mfd: lpc_ich: Enable watchdog on Intel Apollo Lake PCH mfd: lpc_ich: Remove useless comments in core part mfd: Add support for several boards to Kontron PLD driver mfd: constify regmap_irq_chip structures MAINTAINERS: Add include/dt-bindings/mfd to MFD entry mfd: cpcap: Add minimal support mfd: mt6397: Add MT6323 LED support into MT6397 driver Documentation: devicetree: Add LED subnode binding for MT6323 PMIC mfd: tps65912: Export OF device ID table as module aliases mfd: ab8500-core: Rename clock device and compatible mfd: cros_ec: Send correct suspend/resume event to EC mfd: max77686: Remove I2C device ID table mfd: max77686: Use the struct i2c_driver .probe_new instead of .probe mfd: max77686: Use of_device_get_match_data() helper mfd: max77686: Don't attempt to get i2c_device_id .data mfd: ab8500-sysctrl: Handle probe deferral mfd: intel-lpss: Add Intel Gemini Lake PCI IDs mfd: axp20x: Fix AXP806 access errors on cold boot mfd: cros_ec: Send suspend state notification to EC mfd: cros_ec: Prevent data transfer while device is suspended ...
OpenPOWER on IntegriCloud