From af2432322ba1d561057c34ab185561a8e799e8cd Mon Sep 17 00:00:00 2001 From: Eric Anholt Date: Fri, 12 May 2006 13:32:38 -0700 Subject: First pass of integrating the Tungsten Graphics driver for Broadwater. This patch is based off of diffing from the branchpoint to the supplied code, but with many chunks containing reversions of commits removed. Won't work yet. --- src/common.h | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'src/common.h') diff --git a/src/common.h b/src/common.h index a6e4ca3e..70f58a94 100644 --- a/src/common.h +++ b/src/common.h @@ -272,6 +272,11 @@ extern int I810_DEBUG; #define PCI_CHIP_I945_GM_BRIDGE 0x27A0 #endif +#ifndef PCI_CHIP_BROADWATER +#define PCI_CHIP_BROADWATER 0x2982 +#define PCI_CHIP_BROADWATER_BRIDGE 0x2980 +#endif + #define IS_I810(pI810) (pI810->PciInfo->chipType == PCI_CHIP_I810 || \ pI810->PciInfo->chipType == PCI_CHIP_I810_DC100 || \ pI810->PciInfo->chipType == PCI_CHIP_I810_E) @@ -287,7 +292,8 @@ extern int I810_DEBUG; #define IS_I915GM(pI810) (pI810->PciInfo->chipType == PCI_CHIP_I915_GM) #define IS_I945G(pI810) (pI810->PciInfo->chipType == PCI_CHIP_I945_G) #define IS_I945GM(pI810) (pI810->PciInfo->chipType == PCI_CHIP_I945_GM) -#define IS_I9XX(pI810) (IS_I915G(pI810) || IS_I915GM(pI810) || IS_I945G(pI810) || IS_I945GM(pI810)) +#define IS_BROADWATER(pI810) (pI810->PciInfo->chipType == PCI_CHIP_BROADWATER) +#define IS_I9XX(pI810) (IS_I915G(pI810) || IS_I915GM(pI810) || IS_I945G(pI810) || IS_I945GM(pI810) || IS_BROADWATER(pI810)) #define IS_MOBILE(pI810) (IS_I830(pI810) || IS_I85X(pI810) || IS_I915GM(pI810) || IS_I945GM(pI810)) -- cgit v1.2.3 From eec5e996ec9361099bf81d8d3b66933d5981c5a8 Mon Sep 17 00:00:00 2001 From: Eric Anholt Date: Thu, 11 May 2006 20:26:26 -0700 Subject: Merge textured-video-wip to textured-video-planar-full. --- src/common.h | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'src/common.h') diff --git a/src/common.h b/src/common.h index a6e4ca3e..76509d41 100644 --- a/src/common.h +++ b/src/common.h @@ -125,13 +125,17 @@ extern void I830DPRINTF_stub(const char *filename, int line, #define ADVANCE_LP_RING() do { \ if (ringused > needed) \ - ErrorF("%s: ADVANCE_LP_RING: exceeded allocation %d/%d\n ", \ - __FUNCTION__, ringused, needed); \ + FatalError("%s: ADVANCE_LP_RING: exceeded allocation %d/%d\n ", \ + __FUNCTION__, ringused, needed); \ + else if (ringused < needed) \ + FatalError("%s: ADVANCE_LP_RING: under-used allocation %d/%d\n ", \ + __FUNCTION__, ringused, needed); \ RecPtr->LpRing->tail = outring; \ RecPtr->LpRing->space -= ringused; \ if (outring & 0x07) \ - ErrorF("ADVANCE_LP_RING: " \ - "outring (0x%x) isn't on a QWord boundary\n", outring); \ + FatalError("%s: ADVANCE_LP_RING: " \ + "outring (0x%x) isn't on a QWord boundary\n", \ + __FUNCTION__, outring); \ OUTREG(LP_RING + RING_TAIL, outring); \ } while (0) -- cgit v1.2.3 From dae9cb7712d5d8f88697ca83808c59af08364c0e Mon Sep 17 00:00:00 2001 From: Alan Coopersmith Date: Thu, 22 Jun 2006 15:07:16 -0700 Subject: Provide definitions of __FUNCTION__ for non-gcc compilers --- src/common.h | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) (limited to 'src/common.h') diff --git a/src/common.h b/src/common.h index a6e4ca3e..31e67b90 100644 --- a/src/common.h +++ b/src/common.h @@ -39,13 +39,18 @@ SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. #ifndef _INTEL_COMMON_H_ #define _INTEL_COMMON_H_ -#ifdef __GNUC__ +/* Provide substitutes for gcc's __FUNCTION__ on other compilers */ +#ifndef __GNUC__ +# if defined(__STDC__) && (__STDC_VERSION__>=199901L) /* C99 */ +# define __FUNCTION__ __func__ +# else +# define __FUNCTION__ "" +# endif +#endif + + #define PFX __FILE__,__LINE__,__FUNCTION__ #define FUNCTION_NAME __FUNCTION__ -#else -#define PFX __FILE__,__LINE__,"" -#define FUNCTION_NAME "" -#endif #ifdef I830DEBUG #define MARKER() ErrorF("\n### %s:%d: >>> %s <<< ###\n\n", \ -- cgit v1.2.3 From 760021e3983f7783900075b8c9603bd4fbe7e0a2 Mon Sep 17 00:00:00 2001 From: Alan Hourihane Date: Thu, 3 Aug 2006 17:08:39 -0700 Subject: Add current Tungsten Graphics code drop for i965 support. --- src/common.h | 23 ++++++++++++++++++++++- 1 file changed, 22 insertions(+), 1 deletion(-) (limited to 'src/common.h') diff --git a/src/common.h b/src/common.h index 31e67b90..1e3327c6 100644 --- a/src/common.h +++ b/src/common.h @@ -277,6 +277,26 @@ extern int I810_DEBUG; #define PCI_CHIP_I945_GM_BRIDGE 0x27A0 #endif +#ifndef PCI_CHIP_I965_G_1 +#define PCI_CHIP_I965_G_1 0x2982 +#define PCI_CHIP_I965_G_1_BRIDGE 0x2980 +#endif + +#ifndef PCI_CHIP_I965_Q +#define PCI_CHIP_I965_Q 0x2992 +#define PCI_CHIP_I965_Q_BRIDGE 0x2990 +#endif + +#ifndef PCI_CHIP_I965_G +#define PCI_CHIP_I965_G 0x29A2 +#define PCI_CHIP_I965_G_BRIDGE 0x29A0 +#endif + +#ifndef PCI_CHIP_I946_GZ +#define PCI_CHIP_I946_GZ 0x2972 +#define PCI_CHIP_I946_GZ_BRIDGE 0x2970 +#endif + #define IS_I810(pI810) (pI810->PciInfo->chipType == PCI_CHIP_I810 || \ pI810->PciInfo->chipType == PCI_CHIP_I810_DC100 || \ pI810->PciInfo->chipType == PCI_CHIP_I810_E) @@ -292,7 +312,8 @@ extern int I810_DEBUG; #define IS_I915GM(pI810) (pI810->PciInfo->chipType == PCI_CHIP_I915_GM) #define IS_I945G(pI810) (pI810->PciInfo->chipType == PCI_CHIP_I945_G) #define IS_I945GM(pI810) (pI810->PciInfo->chipType == PCI_CHIP_I945_GM) -#define IS_I9XX(pI810) (IS_I915G(pI810) || IS_I915GM(pI810) || IS_I945G(pI810) || IS_I945GM(pI810)) +#define IS_I965G(pI810) (pI810->PciInfo->chipType == PCI_CHIP_I965_G || pI810->PciInfo->chipType == PCI_CHIP_I965_G_1 || pI810->PciInfo->chipType == PCI_CHIP_I965_Q || pI810->PciInfo->chipType == PCI_CHIP_I946_GZ) +#define IS_I9XX(pI810) (IS_I915G(pI810) || IS_I915GM(pI810) || IS_I945G(pI810) || IS_I945GM(pI810) || IS_I965G(pI810)) #define IS_MOBILE(pI810) (IS_I830(pI810) || IS_I85X(pI810) || IS_I915GM(pI810) || IS_I945GM(pI810)) -- cgit v1.2.3