xf86-video-intel: src/sna/sna_display.c
Chris Wilson
ickle at kemper.freedesktop.org
Mon Mar 7 09:29:53 UTC 2016
src/sna/sna_display.c | 2 ++
1 file changed, 2 insertions(+)
New commits:
commit 0204e55b618af285eb31c6eecc3c57b54319a0f4
Author: Ville Syrjälä <ville.syrjala at linux.intel.com>
Date: Mon Mar 7 09:27:50 2016 +0000
sna: Restrict reflected rotations to be rotations
After rolling the bits to the left and the right, ensure that only
rotations remain in the reflection.
Signed-off-by: Chris Wilson <chris at chris-wilson.co.uk>
diff --git a/src/sna/sna_display.c b/src/sna/sna_display.c
index 78338e6..9821c59 100644
--- a/src/sna/sna_display.c
+++ b/src/sna/sna_display.c
@@ -1166,6 +1166,8 @@ rotation_reflect(unsigned rotation)
assert(rotation);
rotation <<= 2; /* RR_Rotate_0 -> RR_Rotate_180 etc */
rotation |= rotation >> 4; /* RR_Rotate_270' to RR_Rotate_90 */
+ rotation &= RR_Rotate_All;
+ assert(rotation);
return rotation | other_bits;
}
More information about the xorg-commit
mailing list