]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
platform/x86: think-lmi: Fix attribute name usage for non-compliant items
authorMark Pearson <mpearson-lenovo@squebb.ca>
Tue, 20 May 2025 00:50:18 +0000 (20:50 -0400)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 29 May 2025 09:14:07 +0000 (11:14 +0200)
commit3d4fe1fb9739bae778032896084bc770e3325dc1
tree2ecebeeb859d984c8966741c221de72661195418
parentff7fdc2e282534aac04650b8cca5dcdf7682c67f
platform/x86: think-lmi: Fix attribute name usage for non-compliant items

[ Upstream commit 8508427a6e21c1ef01ae4c9f4e2675fc99deb949 ]

A few, quite rare, WMI attributes have names that are not compatible with
filenames, e.g. "Intel VT for Directed I/O (VT-d)".
For these cases the '/' gets replaced with '\' for display, but doesn't
get switched again when doing the WMI access.

Fix this by keeping the original attribute name and using that for sending
commands to the BIOS

Fixes: a40cd7ef22fb ("platform/x86: think-lmi: Add WMI interface support on Lenovo platforms")
Signed-off-by: Mark Pearson <mpearson-lenovo@squebb.ca>
Link: https://lore.kernel.org/r/20250520005027.3840705-1-mpearson-lenovo@squebb.ca
Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/platform/x86/think-lmi.c
drivers/platform/x86/think-lmi.h