Skip to content

Commit ad06219

Browse files
committed
Merge tag 'platform-drivers-x86-v5.4-1' of git://git.infradead.org/linux-platform-drivers-x86
Pull x86 platform-drivers updates from Andy Shevchenko: - ASUS WMI driver got a couple of updates, i.e. support of FAN is fixed for recent products and the charge threshold support has been added - Two uknown key events for Dell laptops are being ignored now to avoid spamming users with harmless messages - HP ZBook 17 G5 and ASUS Zenbook UX430UNR got accelerometer support. - Intel CherryTrail platforms had a regression with wake up. Now it's fixed - Intel PMC driver got fixed in order to work nicely in Xen environment - Intel Speed Select driver provides bucket vs core count relationship. Besides that the tools has been updated for better output - The PrivacyGuard is enabled on Lenovo ThinkPad laptops - Three tablets - Trekstor Primebook C11B 2-in-1, Irbis TW90 and Chuwi Surbook Mini - got touchscreen support * tag 'platform-drivers-x86-v5.4-1' of git://git.infradead.org/linux-platform-drivers-x86: (53 commits) MAINTAINERS: Switch PDx86 subsystem status to Odd Fixes platform/x86: asus-wmi: Refactor charge threshold to use the battery hooking API platform/x86: asus-wmi: Rename CHARGE_THRESHOLD to RSOC platform/x86: asus-wmi: Reorder ASUS_WMI_CHARGE_THRESHOLD tools/power/x86/intel-speed-select: Display core count for bucket platform/x86: ISST: Allow additional TRL MSRs tools/power/x86/intel-speed-select: Fix memory leak tools/power/x86/intel-speed-select: Output success/failed for command output tools/power/x86/intel-speed-select: Output human readable CPU list tools/power/x86/intel-speed-select: Change turbo ratio output to maximum turbo frequency tools/power/x86/intel-speed-select: Switch output to MHz tools/power/x86/intel-speed-select: Simplify output for turbo-freq and base-freq tools/power/x86/intel-speed-select: Fix cpu-count output tools/power/x86/intel-speed-select: Fix help option typo tools/power/x86/intel-speed-select: Fix package typo tools/power/x86/intel-speed-select: Fix a read overflow in isst_set_tdp_level_msr() platform/x86: intel_int0002_vgpio: Use device_init_wakeup platform/x86: intel_int0002_vgpio: Fix wakeups not working on Cherry Trail platform/x86: compal-laptop: Initialize "value" in ec_read_u8() platform/x86: touchscreen_dmi: Add info for the Trekstor Primebook C11B 2-in-1 ...
2 parents 7ac63f6 + f690790 commit ad06219

27 files changed

+728
-349
lines changed

Documentation/admin-guide/laptops/thinkpad-acpi.rst

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,7 @@ detailed description):
4949
- Fan control and monitoring: fan speed, fan enable/disable
5050
- WAN enable and disable
5151
- UWB enable and disable
52+
- LCD Shadow (PrivacyGuard) enable and disable
5253

5354
A compatibility table by model and feature is maintained on the web
5455
site, http://ibm-acpi.sf.net/. I appreciate any success or failure
@@ -1409,6 +1410,28 @@ Sysfs notes
14091410
Documentation/driver-api/rfkill.rst for details.
14101411

14111412

1413+
LCD Shadow control
1414+
------------------
1415+
1416+
procfs: /proc/acpi/ibm/lcdshadow
1417+
1418+
Some newer T480s and T490s ThinkPads provide a feature called
1419+
PrivacyGuard. By turning this feature on, the usable vertical and
1420+
horizontal viewing angles of the LCD can be limited (as if some privacy
1421+
screen was applied manually in front of the display).
1422+
1423+
procfs notes
1424+
^^^^^^^^^^^^
1425+
1426+
The available commands are::
1427+
1428+
echo '0' >/proc/acpi/ibm/lcdshadow
1429+
echo '1' >/proc/acpi/ibm/lcdshadow
1430+
1431+
The first command ensures the best viewing angle and the latter one turns
1432+
on the feature, restricting the viewing angles.
1433+
1434+
14121435
EXPERIMENTAL: UWB
14131436
-----------------
14141437

MAINTAINERS

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17512,7 +17512,7 @@ M: Darren Hart <[email protected]>
1751217512
M: Andy Shevchenko <[email protected]>
1751317513
1751417514
T: git git://git.infradead.org/linux-platform-drivers-x86.git
17515-
S: Maintained
17515+
S: Odd Fixes
1751617516
F: drivers/platform/x86/
1751717517
F: drivers/platform/olpc/
1751817518

drivers/platform/mellanox/mlxreg-hotplug.c

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -642,11 +642,8 @@ static int mlxreg_hotplug_probe(struct platform_device *pdev)
642642
priv->irq = pdata->irq;
643643
} else {
644644
priv->irq = platform_get_irq(pdev, 0);
645-
if (priv->irq < 0) {
646-
dev_err(&pdev->dev, "Failed to get platform irq: %d\n",
647-
priv->irq);
645+
if (priv->irq < 0)
648646
return priv->irq;
649-
}
650647
}
651648

652649
priv->regmap = pdata->regmap;

drivers/platform/x86/acer-wmi.c

Lines changed: 7 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -1881,52 +1881,17 @@ static int __init acer_wmi_enable_rf_button(void)
18811881
return status;
18821882
}
18831883

1884-
#define ACER_WMID_ACCEL_HID "BST0001"
1885-
1886-
static acpi_status __init acer_wmi_get_handle_cb(acpi_handle ah, u32 level,
1887-
void *ctx, void **retval)
1888-
{
1889-
struct acpi_device *dev;
1890-
1891-
if (!strcmp(ctx, "SENR")) {
1892-
if (acpi_bus_get_device(ah, &dev))
1893-
return AE_OK;
1894-
if (strcmp(ACER_WMID_ACCEL_HID, acpi_device_hid(dev)))
1895-
return AE_OK;
1896-
} else
1897-
return AE_OK;
1898-
1899-
*(acpi_handle *)retval = ah;
1900-
1901-
return AE_CTRL_TERMINATE;
1902-
}
1903-
1904-
static int __init acer_wmi_get_handle(const char *name, const char *prop,
1905-
acpi_handle *ah)
1906-
{
1907-
acpi_status status;
1908-
acpi_handle handle;
1909-
1910-
BUG_ON(!name || !ah);
1911-
1912-
handle = NULL;
1913-
status = acpi_get_devices(prop, acer_wmi_get_handle_cb,
1914-
(void *)name, &handle);
1915-
if (ACPI_SUCCESS(status) && handle) {
1916-
*ah = handle;
1917-
return 0;
1918-
} else {
1919-
return -ENODEV;
1920-
}
1921-
}
1922-
19231884
static int __init acer_wmi_accel_setup(void)
19241885
{
1886+
struct acpi_device *adev;
19251887
int err;
19261888

1927-
err = acer_wmi_get_handle("SENR", ACER_WMID_ACCEL_HID, &gsensor_handle);
1928-
if (err)
1929-
return err;
1889+
adev = acpi_dev_get_first_match_dev("BST0001", NULL, -1);
1890+
if (!adev)
1891+
return -ENODEV;
1892+
1893+
gsensor_handle = acpi_device_handle(adev);
1894+
acpi_dev_put(adev);
19301895

19311896
interface->capability |= ACER_CAP_ACCEL;
19321897

drivers/platform/x86/asus-nb-wmi.c

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -402,6 +402,15 @@ static const struct dmi_system_id asus_quirks[] = {
402402
},
403403
.driver_data = &quirk_asus_forceals,
404404
},
405+
{
406+
.callback = dmi_matched,
407+
.ident = "ASUSTeK COMPUTER INC. UX430UNR",
408+
.matches = {
409+
DMI_MATCH(DMI_SYS_VENDOR, "ASUSTeK COMPUTER INC."),
410+
DMI_MATCH(DMI_PRODUCT_NAME, "UX430UNR"),
411+
},
412+
.driver_data = &quirk_asus_forceals,
413+
},
405414
{},
406415
};
407416

0 commit comments

Comments
 (0)