This is a note to let you know that I've just added the patch titled
platform/x86: hp-wmi: Fix error value for hp_wmi_tablet_state
to the 4.4-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git%3Ba=su...
The filename of the patch is: platform-x86-hp-wmi-fix-error-value-for-hp_wmi_tablet_state.patch and it can be found in the queue-4.4 subdirectory.
If you, or anyone else, feels it should not be added to the stable tree, please let stable@vger.kernel.org know about it.
From c7dfc2facbd69dad89b75e13c608da709668dcd0 Mon Sep 17 00:00:00 2001
From: Carlo Caione carlo@endlessm.com Date: Sun, 9 Apr 2017 15:56:07 +0200 Subject: platform/x86: hp-wmi: Fix error value for hp_wmi_tablet_state
From: Carlo Caione carlo@endlessm.com
commit c7dfc2facbd69dad89b75e13c608da709668dcd0 upstream.
hp_wmi_tablet_state() fails to return the correct error code when hp_wmi_perform_query() returns the HP WMI query specific error code that is a positive value.
Signed-off-by: Carlo Caione carlo@endlessm.com Signed-off-by: Darren Hart (VMware) dvhart@infradead.org Cc: Philip Müller philm@manjaro.org Signed-off-by: Greg Kroah-Hartman gregkh@linuxfoundation.org
--- drivers/platform/x86/hp-wmi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
--- a/drivers/platform/x86/hp-wmi.c +++ b/drivers/platform/x86/hp-wmi.c @@ -291,7 +291,7 @@ static int hp_wmi_tablet_state(void) int ret = hp_wmi_perform_query(HPWMI_HARDWARE_QUERY, 0, &state, sizeof(state), sizeof(state)); if (ret) - return ret; + return -EINVAL;
return (state & 0x4) ? 1 : 0; }
Patches currently in stable-queue which might be from carlo@endlessm.com are
queue-4.4/platform-x86-hp-wmi-do-not-shadow-error-values.patch queue-4.4/platform-x86-hp-wmi-fix-detection-for-dock-and-tablet-mode.patch queue-4.4/platform-x86-hp-wmi-fix-error-value-for-hp_wmi_tablet_state.patch
linux-stable-mirror@lists.linaro.org