diff options
author | Hans de Goede <hdegoede@redhat.com> | 2020-11-18 18:48:43 +0100 |
---|---|---|
committer | Hans de Goede <hdegoede@redhat.com> | 2020-11-18 21:23:34 +0100 |
commit | 276ede07404a802dbde8fc41da07636ec8998340 (patch) | |
tree | 51d7e6629aae4875d4bd5b4db16aa9170bfa63ca /hwdb.d | |
parent | hwdb: Document how to properly set the mount-matrix for the base-acceleromete... (diff) | |
download | systemd-276ede07404a802dbde8fc41da07636ec8998340.tar.xz systemd-276ede07404a802dbde8fc41da07636ec8998340.zip |
hwdb: Add base accelerometer orientation quirk for base sensor of Medion Akoya E* series
The KIOX010A and KIOX02A ACPI hw-ids (HIDs) are used in 360 degree hinges
style 2-in-1s which have 2 accelerometers, 1 in the display (as usual) and
a second accelerometer in the base.
So far 60-sensor.hwdb has only defined a mount-matrix for the
sensor with the KIOX010A HID, which is the sensor in the display
half of the device. The reason for this is that sofar userspace has
only cared actually used the sensor in the display (for automatic
display rotation. Work is underway to make userspace use both sensors:
https://gitlab.freedesktop.org/hadess/iio-sensor-proxy/-/issues/216
Recently an entry was added for the Medion Akoya's E2221T base-sensor,
but that was added to mark it with ACCEL_LOCATION=base and the entry
simply used the identity-matrix for ACCEL_MOUNT_MATRIX since nothing
is using the mount-matrix info for the second accelerometer.
I believe that this entry was added because on some devices the second
accelerometer gets enumerated first and then iio-sensor-proxy will
wrongly use the second sensor for display-rotation, unless it is marked
with ACCEL_LOCATION=base.
Instead of adding info for the second accelerometer on a per device
basis use the same generic dmi matches as used for the first (KIOX010A)
sensor, replacing the special case added for the E2221T and also
update the ACCEL_MOUNT_MATRIX with the actual mount-matrix for the
KIOX020A sensor in the base of these devices.
This was tested on a Medion Akoya E2228T.
Diffstat (limited to '')
-rw-r--r-- | hwdb.d/60-sensor.hwdb | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/hwdb.d/60-sensor.hwdb b/hwdb.d/60-sensor.hwdb index a975abdf04..4a5aeb0c96 100644 --- a/hwdb.d/60-sensor.hwdb +++ b/hwdb.d/60-sensor.hwdb @@ -540,10 +540,12 @@ sensor:modalias:acpi:KIOX010A*:dmi:*:svnMEDION:pnE*:* # Medion Akoya E3222 MD62450 sensor:modalias:acpi:KIOX010A*:dmi:*:svnMEDION:pnMEDION*:* ACCEL_MOUNT_MATRIX=0, -1, 0; -1, 0, 0; 0, 0, 1 + ACCEL_LOCATION=display -# Medion Akoya E2221T MD60691 -sensor:modalias:acpi:KIOX020A*:dmi:*:pnE2221TMD60691*:* - ACCEL_MOUNT_MATRIX=1, 0, 0; 0, 1, 0; 0, 0, 1 +# Same as above, but for base sensor +sensor:modalias:acpi:KIOX020A*:dmi:*:svnMEDION:pnE*:* +sensor:modalias:acpi:KIOX020A*:dmi:*:svnMEDION:pnMEDION*:* + ACCEL_MOUNT_MATRIX=-1, 0, 0; 0, 1, 0; 0, 0, -1 ACCEL_LOCATION=base ######################################### |