[Intel-gfx] [PATCH 3/5]mesa patch

Shaohua Li shaohua.li at intel.com
Mon Feb 23 08:19:21 CET 2009


This is the mesa patch for a new chip, which is G33-like. Basically add
the pci id.

Signed-off-by: Shaohua Li <shaohua.li at intel.com>
---
 src/mesa/drivers/dri/intel/intel_chipset.h |   11 +++++++++--
 src/mesa/drivers/dri/intel/intel_context.c |    4 ++++
 2 files changed, 13 insertions(+), 2 deletions(-)

Index: mesa/src/mesa/drivers/dri/intel/intel_chipset.h
===================================================================
--- mesa.orig/src/mesa/drivers/dri/intel/intel_chipset.h	2009-02-05 11:22:08.000000000 +0800
+++ mesa/src/mesa/drivers/dri/intel/intel_chipset.h	2009-02-05 11:23:08.000000000 +0800
@@ -46,6 +46,13 @@
 #define PCI_CHIP_G33_G			0x29C2
 #define PCI_CHIP_Q33_G			0x29D2
 
+#define PCI_CHIP_IGD_GM			0xA011
+#define PCI_CHIP_IGD_G			0xA001
+
+#define IS_IGDGM(devid)	(devid == PCI_CHIP_IGD_GM)
+#define IS_IGDG(devid)	(devid == PCI_CHIP_IGD_G)
+#define IS_IGD(devid) (IS_IGDG(devid) || IS_IGDGM(devid))
+
 #define PCI_CHIP_I965_G			0x29A2
 #define PCI_CHIP_I965_Q			0x2992
 #define PCI_CHIP_I965_G_1		0x2982
@@ -66,7 +73,7 @@
 				 devid == PCI_CHIP_I945_GME || \
 				 devid == PCI_CHIP_I965_GM || \
 				 devid == PCI_CHIP_I965_GME || \
-				 devid == PCI_CHIP_GM45_GM)
+				 devid == PCI_CHIP_GM45_GM || IS_IGD(devid))
 
 #define IS_G45(devid)           (devid == PCI_CHIP_IGD_E_G || \
                                  devid == PCI_CHIP_Q45_G || \
@@ -84,7 +91,7 @@
 				 devid == PCI_CHIP_I945_GME || \
 				 devid == PCI_CHIP_G33_G || \
 				 devid == PCI_CHIP_Q33_G || \
-				 devid == PCI_CHIP_Q35_G)
+				 devid == PCI_CHIP_Q35_G || IS_IGD(devid))
 
 #define IS_965(devid)		(devid == PCI_CHIP_I965_G || \
 				 devid == PCI_CHIP_I965_Q || \
Index: mesa/src/mesa/drivers/dri/intel/intel_context.c
===================================================================
--- mesa.orig/src/mesa/drivers/dri/intel/intel_context.c	2009-02-05 11:22:54.000000000 +0800
+++ mesa/src/mesa/drivers/dri/intel/intel_context.c	2009-02-05 11:23:08.000000000 +0800
@@ -123,6 +123,10 @@ intelGetString(GLcontext * ctx, GLenum n
       case PCI_CHIP_Q33_G:
 	 chipset = "Intel(R) Q33";
 	 break;
+      case PCI_CHIP_IGD_GM:
+      case PCI_CHIP_IGD_G:
+	 chipset = "Intel(R) IGD";
+	 break;
       case PCI_CHIP_I965_Q:
 	 chipset = "Intel(R) 965Q";
 	 break;





More information about the Intel-gfx mailing list