Sophie

Sophie

distrib > Mageia > 9 > armv7hl > media > core-release-src > by-pkgid > bf674cbb17361fa8ea6df03dcde9fa67 > files > 6

x11-driver-video-intel-2.99.917-69.mga9.src.rpm

From 1b69012e85bfc1dcc0b4fd32054def9451a3ea4f Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Ville=20Syrj=C3=A4l=C3=A4?= <ville.syrjala@linux.intel.com>
Date: Fri, 28 Oct 2022 08:42:53 +0300
Subject: [PATCH 6/7] sna: Don't redefine NV12 stuff if already defined
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Modern server headers already define NV12 for us. Avoid the
redefine.

Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
---
 src/sna/sna_video.h | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/src/sna/sna_video.h b/src/sna/sna_video.h
index 06d43796..25b97192 100644
--- a/src/sna/sna_video.h
+++ b/src/sna/sna_video.h
@@ -38,7 +38,9 @@ THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 #define FOURCC_XVMC (('C' << 24) + ('M' << 16) + ('V' << 8) + 'X')
 #define FOURCC_RGB565 ((16 << 24) + ('B' << 16) + ('G' << 8) + 'R')
 #define FOURCC_RGB888 ((24 << 24) + ('B' << 16) + ('G' << 8) + 'R')
+#ifndef FOURCC_NV12
 #define FOURCC_NV12 (('2' << 24) + ('1' << 16) + ('V' << 8) + 'N')
+#endif
 #define FOURCC_AYUV (('V' << 24) + ('U' << 16) + ('Y' << 8) + 'A')
 
 /*
@@ -71,7 +73,7 @@ THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 	XvTopToBottom \
 }
 
-/* no standard define for this */
+#ifndef XVIMAGE_NV12
 #define XVIMAGE_NV12 { \
 	FOURCC_NV12, XvYUV, LSBFirst,				\
 	{'N','V','1','2', 0x00,0x00,0x00,0x10,0x80,0x00,0x00,0xAA,0x00,0x38,0x9B,0x71}, \
@@ -79,6 +81,7 @@ THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 	{'Y','U','V', 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, \
 	XvTopToBottom \
 }
+#endif
 
 #define XVIMAGE_AYUV { \
 	FOURCC_AYUV, XvYUV, LSBFirst, \
-- 
2.40.1