Linux v4.14.1
This commit is contained in:
parent
57d23c26c7
commit
dfe29a7e73
|
@ -1,72 +0,0 @@
|
|||
From 0e9df6a74f9573409e5a2fbe29c1389188280bfc Mon Sep 17 00:00:00 2001
|
||||
From: Hans de Goede <hdegoede@redhat.com>
|
||||
Date: Thu, 5 Oct 2017 16:02:33 +0200
|
||||
Subject: [PATCH] platform/x86: peaq-wmi: Add DMI check before binding to the
|
||||
WMI interface
|
||||
|
||||
It seems that the WMI GUID used by the PEAQ 2-in-1 WMI hotkeys is not
|
||||
as unique as a GUID should be and is used on some other devices too.
|
||||
|
||||
This is causing spurious key-press reports on these other devices.
|
||||
|
||||
This commits adds a DMI check to the PEAQ 2-in-1 WMI hotkeys driver to
|
||||
ensure that it is actually running on a PEAQ 2-in-1, fixing the
|
||||
spurious key-presses on these other devices.
|
||||
|
||||
BugLink: https://bugzilla.redhat.com/show_bug.cgi?id=1497861
|
||||
BugLink: https://bugzilla.suse.com/attachment.cgi?id=743182
|
||||
Cc: stable@vger.kernel.org
|
||||
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
|
||||
---
|
||||
drivers/platform/x86/peaq-wmi.c | 18 ++++++++++++++++++
|
||||
1 file changed, 18 insertions(+)
|
||||
|
||||
diff --git a/drivers/platform/x86/peaq-wmi.c b/drivers/platform/x86/peaq-wmi.c
|
||||
index bc98ef95514a..67fa3fa32011 100644
|
||||
--- a/drivers/platform/x86/peaq-wmi.c
|
||||
+++ b/drivers/platform/x86/peaq-wmi.c
|
||||
@@ -8,6 +8,7 @@
|
||||
*/
|
||||
|
||||
#include <linux/acpi.h>
|
||||
+#include <linux/dmi.h>
|
||||
#include <linux/input-polldev.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/module.h>
|
||||
@@ -64,8 +65,23 @@ static void peaq_wmi_poll(struct input_polled_dev *dev)
|
||||
}
|
||||
}
|
||||
|
||||
+/* Some other devices (Shuttle XS35) use the same WMI GUID for other purposes */
|
||||
+static const struct dmi_system_id peaq_dmi_table[] = {
|
||||
+ {
|
||||
+ .matches = {
|
||||
+ DMI_MATCH(DMI_SYS_VENDOR, "PEAQ"),
|
||||
+ DMI_MATCH(DMI_PRODUCT_NAME, "PEAQ PMM C1010 MD99187"),
|
||||
+ },
|
||||
+ },
|
||||
+ {}
|
||||
+};
|
||||
+
|
||||
static int __init peaq_wmi_init(void)
|
||||
{
|
||||
+ /* WMI GUID is not unique, also check for a DMI match */
|
||||
+ if (!dmi_check_system(peaq_dmi_table))
|
||||
+ return -ENODEV;
|
||||
+
|
||||
if (!wmi_has_guid(PEAQ_DOLBY_BUTTON_GUID))
|
||||
return -ENODEV;
|
||||
|
||||
@@ -86,6 +101,9 @@ static int __init peaq_wmi_init(void)
|
||||
|
||||
static void __exit peaq_wmi_exit(void)
|
||||
{
|
||||
+ if (!dmi_check_system(peaq_dmi_table))
|
||||
+ return;
|
||||
+
|
||||
if (!wmi_has_guid(PEAQ_DOLBY_BUTTON_GUID))
|
||||
return;
|
||||
|
||||
--
|
||||
2.14.2
|
||||
|
|
@ -1,118 +0,0 @@
|
|||
From 3b40f521aa2f42862203497a94ae77536f41ade2 Mon Sep 17 00:00:00 2001
|
||||
From: Hans de Goede <hdegoede@redhat.com>
|
||||
Date: Thu, 12 Oct 2017 19:44:48 +0200
|
||||
Subject: [PATCH] staging: vboxvideo: Fix reporting invalid
|
||||
suggested-offset-properties
|
||||
|
||||
The x and y hints receives from the host are unsigned 32 bit integers and
|
||||
they get set to -1 (0xffffffff) when invalid. Before this commit the
|
||||
vboxvideo driver was storing them in an u16 causing the -1 to be truncated
|
||||
to 65535 which, once reported to userspace, was breaking gnome 3.26+
|
||||
in Wayland mode.
|
||||
|
||||
This commit stores the host values in 32 bit variables, removing the
|
||||
truncation and checks for -1, replacing it with 0 as -1 is not a valid
|
||||
suggested-offset-property value. Likewise the properties are now
|
||||
initialized to 0 instead of -1, since -1 is not a valid value.
|
||||
This fixes gnome 3.26+ in Wayland mode not working with the vboxvideo
|
||||
driver.
|
||||
|
||||
Reported-by: Gianfranco Costamagna <locutusofborg@debian.org>
|
||||
Cc: stable@vger.kernel.org
|
||||
Cc: Michael Thayer <michael.thayer@oracle.com>
|
||||
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
|
||||
---
|
||||
drivers/staging/vboxvideo/vbox_drv.h | 8 ++++----
|
||||
drivers/staging/vboxvideo/vbox_irq.c | 4 ++--
|
||||
drivers/staging/vboxvideo/vbox_mode.c | 26 ++++++++++++++++++--------
|
||||
3 files changed, 24 insertions(+), 14 deletions(-)
|
||||
|
||||
diff --git a/drivers/staging/vboxvideo/vbox_drv.h b/drivers/staging/vboxvideo/vbox_drv.h
|
||||
index 4b9302703b36..eeac4f0cb2c6 100644
|
||||
--- a/drivers/staging/vboxvideo/vbox_drv.h
|
||||
+++ b/drivers/staging/vboxvideo/vbox_drv.h
|
||||
@@ -137,8 +137,8 @@ struct vbox_connector {
|
||||
char name[32];
|
||||
struct vbox_crtc *vbox_crtc;
|
||||
struct {
|
||||
- u16 width;
|
||||
- u16 height;
|
||||
+ u32 width;
|
||||
+ u32 height;
|
||||
bool disconnected;
|
||||
} mode_hint;
|
||||
};
|
||||
@@ -150,8 +150,8 @@ struct vbox_crtc {
|
||||
unsigned int crtc_id;
|
||||
u32 fb_offset;
|
||||
bool cursor_enabled;
|
||||
- u16 x_hint;
|
||||
- u16 y_hint;
|
||||
+ u32 x_hint;
|
||||
+ u32 y_hint;
|
||||
};
|
||||
|
||||
struct vbox_encoder {
|
||||
diff --git a/drivers/staging/vboxvideo/vbox_irq.c b/drivers/staging/vboxvideo/vbox_irq.c
|
||||
index 3ca8bec62ac4..74abdf02d9fd 100644
|
||||
--- a/drivers/staging/vboxvideo/vbox_irq.c
|
||||
+++ b/drivers/staging/vboxvideo/vbox_irq.c
|
||||
@@ -150,8 +150,8 @@ static void vbox_update_mode_hints(struct vbox_private *vbox)
|
||||
|
||||
disconnected = !(hints->enabled);
|
||||
crtc_id = vbox_conn->vbox_crtc->crtc_id;
|
||||
- vbox_conn->mode_hint.width = hints->cx & 0x8fff;
|
||||
- vbox_conn->mode_hint.height = hints->cy & 0x8fff;
|
||||
+ vbox_conn->mode_hint.width = hints->cx;
|
||||
+ vbox_conn->mode_hint.height = hints->cy;
|
||||
vbox_conn->vbox_crtc->x_hint = hints->dx;
|
||||
vbox_conn->vbox_crtc->y_hint = hints->dy;
|
||||
vbox_conn->mode_hint.disconnected = disconnected;
|
||||
diff --git a/drivers/staging/vboxvideo/vbox_mode.c b/drivers/staging/vboxvideo/vbox_mode.c
|
||||
index 257a77830410..6f08dc966719 100644
|
||||
--- a/drivers/staging/vboxvideo/vbox_mode.c
|
||||
+++ b/drivers/staging/vboxvideo/vbox_mode.c
|
||||
@@ -553,12 +553,22 @@ static int vbox_get_modes(struct drm_connector *connector)
|
||||
++num_modes;
|
||||
}
|
||||
vbox_set_edid(connector, preferred_width, preferred_height);
|
||||
- drm_object_property_set_value(
|
||||
- &connector->base, vbox->dev->mode_config.suggested_x_property,
|
||||
- vbox_connector->vbox_crtc->x_hint);
|
||||
- drm_object_property_set_value(
|
||||
- &connector->base, vbox->dev->mode_config.suggested_y_property,
|
||||
- vbox_connector->vbox_crtc->y_hint);
|
||||
+
|
||||
+ if (vbox_connector->vbox_crtc->x_hint != -1)
|
||||
+ drm_object_property_set_value(&connector->base,
|
||||
+ vbox->dev->mode_config.suggested_x_property,
|
||||
+ vbox_connector->vbox_crtc->x_hint);
|
||||
+ else
|
||||
+ drm_object_property_set_value(&connector->base,
|
||||
+ vbox->dev->mode_config.suggested_x_property, 0);
|
||||
+
|
||||
+ if (vbox_connector->vbox_crtc->y_hint != -1)
|
||||
+ drm_object_property_set_value(&connector->base,
|
||||
+ vbox->dev->mode_config.suggested_y_property,
|
||||
+ vbox_connector->vbox_crtc->y_hint);
|
||||
+ else
|
||||
+ drm_object_property_set_value(&connector->base,
|
||||
+ vbox->dev->mode_config.suggested_y_property, 0);
|
||||
|
||||
return num_modes;
|
||||
}
|
||||
@@ -640,9 +650,9 @@ static int vbox_connector_init(struct drm_device *dev,
|
||||
|
||||
drm_mode_create_suggested_offset_properties(dev);
|
||||
drm_object_attach_property(&connector->base,
|
||||
- dev->mode_config.suggested_x_property, -1);
|
||||
+ dev->mode_config.suggested_x_property, 0);
|
||||
drm_object_attach_property(&connector->base,
|
||||
- dev->mode_config.suggested_y_property, -1);
|
||||
+ dev->mode_config.suggested_y_property, 0);
|
||||
drm_connector_register(connector);
|
||||
|
||||
drm_mode_connector_attach_encoder(connector, encoder);
|
||||
--
|
||||
2.14.2
|
||||
|
11
kernel.spec
11
kernel.spec
|
@ -54,7 +54,7 @@ Summary: The Linux kernel
|
|||
%if 0%{?released_kernel}
|
||||
|
||||
# Do we have a -stable update to apply?
|
||||
%define stable_update 0
|
||||
%define stable_update 1
|
||||
# Set rpm version accordingly
|
||||
%if 0%{?stable_update}
|
||||
%define stablerev %{stable_update}
|
||||
|
@ -640,15 +640,9 @@ Patch617: Fix-for-module-sig-verification.patch
|
|||
# rhbz 1431375
|
||||
Patch619: input-rmi4-remove-the-need-for-artifical-IRQ.patch
|
||||
|
||||
# fix gnome 3.26+ not working under VirtualBox, submitted upstream, Cc: Stable
|
||||
Patch620: 0001-staging-vboxvideo-Fix-reporting-invalid-suggested-of.patch
|
||||
|
||||
# Headed upstream
|
||||
Patch621: drm-i915-Boost-GPU-clocks-if-we-miss-the-pageflip-s-vblank.patch
|
||||
|
||||
# rhbz 1497861, submitted upstream, Cc: Stable
|
||||
Patch622: 0001-platform-x86-peaq-wmi-Add-DMI-check-before-binding-t.patch
|
||||
|
||||
Patch623: 0001-PATCH-staging-rtl8822be-fix-wrong-dma-unmap-len.patch
|
||||
|
||||
# rhbz 1509461
|
||||
|
@ -2211,6 +2205,9 @@ fi
|
|||
#
|
||||
#
|
||||
%changelog
|
||||
* Tue Nov 21 2017 Justin M. Forbes <jforbes@fedoraproject.org> - 4.14.1-300
|
||||
- Linux v4.14.1
|
||||
|
||||
* Wed Nov 15 2017 Justin M. Forbes <jforbes@fedoraproject.org> - 4.14.0-300
|
||||
- Linux v4.14
|
||||
|
||||
|
|
1
sources
1
sources
|
@ -1,2 +1,3 @@
|
|||
SHA512 (linux-4.14.tar.xz) = 77e43a02d766c3d73b7e25c4aafb2e931d6b16e870510c22cef0cdb05c3acb7952b8908ebad12b10ef982c6efbe286364b1544586e715cf38390e483927904d8
|
||||
SHA512 (perf-man-4.14.tar.gz) = 76a9d8adc284cdffd4b3fbb060e7f9a14109267707ce1d03f4c3239cd70d8d164f697da3a0f90a363fbcac42a61d3c378afbcc2a86f112c501b9cb5ce74ef9f8
|
||||
SHA512 (patch-4.14.1.xz) = 2566d2151cb0e0ad706dda3cb815e293d84ecc804cf2891e511a0f28e359b7714a1732add599a268c98108a63ee40200cf76cbda8181d67d0a64511e815202df
|
||||
|
|
Loading…
Reference in New Issue