summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog138
-rw-r--r--src/i810_dri.h2
-rw-r--r--src/i830_dri.h2
-rw-r--r--src/i830_driver.c54
-rw-r--r--src/i830_video.c16
-rw-r--r--src/xvmc/Makefile.am3
6 files changed, 56 insertions, 159 deletions
diff --git a/ChangeLog b/ChangeLog
deleted file mode 100644
index d77176bb..00000000
--- a/ChangeLog
+++ /dev/null
@@ -1,138 +0,0 @@
-2006-05-01 Matthieu Herrb <matthieu.herrb@laas.fr>
-
- * src/common.h:
- Fix build on non-dri systems.
-
-2006-04-07 Adam Jackson <ajax@freedesktop.org>
-
- * configure.ac:
- * src/i810.h:
- Bump to 1.6.0.
-
-2006-04-07 Aaron Plattner <aplattner@nvidia.com>
-
- * src/i810_video.c: (I810PutImage):
- * src/i830_video.c: (I830PutImage):
- Add a DrawablePtr argument to the XV functions to pave the way for
- redirected video.
-
-2006-04-05 Dave Airlie <airlied@linux.ie>
-
- * src/i810_hwmc.c: (I810XvMCCreateContext),
- (I810XvMCCreateSurface), (I810XvMCCreateSubpicture):
- * src/i810_memory.c: (I810SetTiledMemory):
- * src/i830_memory.c: (SetFence):
- Fix some argument inversions in xf86DrvMsg function calls
-
-2006-04-04 Kristian Høgsberg <krh@redhat.com>
-
- * src/i810_dri.c:
- * src/i810_driver.c:
- * src/i830_dri.c:
- * src/i830_driver.c: Add more missing #include's, in particular
- assert.h.
-
-2006-03-22 Kristian Høgsberg <krh@redhat.com>
-
- * src/*.c: Drop libc wrapper; don't include xf86_ansic.h and add
- includes now missing.
-
-2006-03-10 Alan Hourihane <alanh@fairlite.demon.co.uk>
-
- * src/i830_cursor.c: (I830InitHWCursor), (I830ShowCursor),
- (I830HideCursor):
- Enable gamma for hw cursor when ARGB cursor in use (Lukas Hejtmanek)
-
-2006-03-03 Alan Hourihane <alanh@fairlite.demon.co.uk>
-
- * configure.ac:
- * src/i810.h:
- * src/i830.h:
- * src/i830_dri.h:
- * src/i830_driver.c: (I830BIOSPreInit), (I830BIOSScreenInit),
- (I830BIOSCloseScreen):
- * src/i830_video.c:
- Check the version of shadow being used and turn off rotation if
- it isn't the right one.
- Bump the Xvideo resolution support from 1920x1080 to 1920x1088.
-
-2006-02-20 Alan Hourihane <alanh@fairlite.demon.co.uk>
-
- * src/i830_rotate.c: (I915UpdateRotate), (I830UpdateRotate):
- Fix a rotation problem when DRI is disabled
-
-2005-01-25 Alan Hourihane <alanh@fairlite.demon.co.uk>
-
- * src/i830_driver.c: When going dual head only take a portion of
- memory for the second head instead of doubling the requirements.
-
-2005-01-25 Alan Hourihane <alanh@fairlite.demon.co.uk>
-
- * src/i830_driver.c: Fix a glitch in a dual head fix from #3105
-
-2005-01-24 Alan Hourihane <alanh@fairlite.demon.co.uk>
-
- * configure.ac, man/i810.man, src/Makefile.am, src/common.h,
- src/i810.h, src/i810_dri.c, src/i810_driver.c, src/i830.h,
- src/i830_common.h, src/i830_cursor.c, src/i830_dga.c,
- src/i830_dri.c, src/i830_dri.h, src/i830_driver.c,
- src/i830_memory.c, src/i830_modes.c, src/i830_randr.c,
- src/i830_rotate.c, src/i830_shadow.c, src/i830_video.c:
- Bump version to 1.5.0.0
- Add Intel 945GM support
- Add RandR rotation support (full 3D acceleration, HWcursor &
- Xvideo rotated too)
- Remove older shadow framebuffer rotation code
- Add a new LinearAlloc option to allow more offscreen memory
- to be allocated for XVideo applications. This allows HDTV movies
- to be played via Xvideo.
-
-2005-12-20 Kevin E. Martin <kem-at-freedesktop-dot-org>
-
- * configure.ac:
- Update package version for X11R7 release.
-
-2005-12-14 Kevin E. Martin <kem-at-freedesktop-dot-org>
-
- * configure.ac:
- Update package version number for final X11R7 release candidate.
-
-2005-12-06 Kevin E. Martin <kem-at-freedesktop-dot-org>
-
- * man/Makefile.am:
- Change *man_SOURCES ==> *man_PRE to fix autotools warnings.
-
-2005-12-03 Kevin E. Martin <kem-at-freedesktop-dot-org>
-
- * configure.ac:
- Update package version number for X11R7 RC3 release.
-
-2005-12-01 Kevin E. Martin <kem-at-freedesktop-dot-org>
-
- * configure.ac:
- Remove extraneous AC_MSG_RESULT.
-
-2005-11-30 Adam Jackson <ajax@freedesktop.org>
-
- * configure.ac:
- Bump libdrm dep to 2.0.
-
-2005-11-29 Adam Jackson <ajax@freedesktop.org>
-
- * configure.ac:
- Only build dlloader modules by default.
-
-2005-11-19 Kevin E. Martin <kem-at-freedesktop-dot-org>
-
- * configure.ac:
- Update dependencies to work with separate build roots.
-
-2005-11-09 Kevin E. Martin <kem-at-freedesktop-dot-org>
-
- * configure.ac:
- Update package version number for X11R7 RC2 release.
-
-2005-11-01 Kevin E. Martin <kem-at-freedesktop-dot-org>
-
- * configure.ac:
- Update pkgcheck dependencies to work with separate build roots.
diff --git a/src/i810_dri.h b/src/i810_dri.h
index f090b923..5aa43383 100644
--- a/src/i810_dri.h
+++ b/src/i810_dri.h
@@ -10,7 +10,7 @@
#define I810_MAJOR_VERSION 1
#define I810_MINOR_VERSION 7
-#define I810_PATCHLEVEL 2
+#define I810_PATCHLEVEL 4
typedef struct {
drm_handle_t regs;
diff --git a/src/i830_dri.h b/src/i830_dri.h
index a1404978..91891a58 100644
--- a/src/i830_dri.h
+++ b/src/i830_dri.h
@@ -10,7 +10,7 @@
#define I830_MAJOR_VERSION 1
#define I830_MINOR_VERSION 7
-#define I830_PATCHLEVEL 2
+#define I830_PATCHLEVEL 4
#define I830_REG_SIZE 0x80000
diff --git a/src/i830_driver.c b/src/i830_driver.c
index d8924cfc..7ab2cdc8 100644
--- a/src/i830_driver.c
+++ b/src/i830_driver.c
@@ -272,8 +272,10 @@ typedef enum {
OPTION_COLOR_KEY,
OPTION_CHECKDEVICES,
OPTION_LINEARALLOC,
+#ifdef XF86DRI_MM
OPTION_INTELTEXPOOL,
OPTION_INTELMMSIZE
+#endif
} I830Opts;
static OptionInfoRec I830Options[] = {
@@ -290,8 +292,10 @@ static OptionInfoRec I830Options[] = {
{OPTION_VIDEO_KEY, "VideoKey", OPTV_INTEGER, {0}, FALSE},
{OPTION_CHECKDEVICES, "CheckDevices",OPTV_BOOLEAN, {0}, FALSE},
{OPTION_LINEARALLOC, "LinearAlloc", OPTV_INTEGER, {0}, FALSE},
+#ifdef XF86DRI_MM
{OPTION_INTELTEXPOOL,"Legacy3D", OPTV_BOOLEAN, {0}, FALSE},
{OPTION_INTELMMSIZE, "AperTexSize", OPTV_INTEGER, {0}, FALSE},
+#endif
{-1, NULL, OPTV_NONE, {0}, FALSE}
};
/* *INDENT-ON* */
@@ -1230,30 +1234,38 @@ I830PreInit(ScrnInfoPtr pScrn, int flags)
pI830->mmModeFlags = 0;
if (!pI830->directRenderingDisabled) {
+#ifdef XF86DRI_MM
Bool tmp = FALSE;
- pI830->mmModeFlags |= I830_KERNEL_TEX;
-#ifdef XF86DRI_MM
if (!IS_I965G(pI830))
pI830->mmModeFlags |= I830_KERNEL_MM;
+ else
#endif
+ pI830->mmModeFlags |= I830_KERNEL_TEX;
from = X_PROBED;
+
+#ifdef XF86DRI_MM
if (xf86GetOptValBool(pI830->Options,
OPTION_INTELTEXPOOL, &tmp)) {
from = X_CONFIG;
if (tmp) {
pI830->mmModeFlags |= I830_KERNEL_TEX;
+ pI830->mmModeFlags &= ~I830_KERNEL_MM;
} else {
pI830->mmModeFlags &= ~I830_KERNEL_TEX;
+ pI830->mmModeFlags |= I830_KERNEL_MM;
}
}
+#endif
+
xf86DrvMsg(pScrn->scrnIndex, from,
"Will %stry to allocate texture pool "
"for old Mesa 3D driver.\n",
(pI830->mmModeFlags & I830_KERNEL_TEX) ?
"" : "not ");
+#ifdef XF86DRI_MM
pI830->mmSize = I830_MM_MAXSIZE;
from = X_INFO;
if (xf86GetOptValInteger(pI830->Options, OPTION_INTELMMSIZE,
@@ -1266,6 +1278,7 @@ I830PreInit(ScrnInfoPtr pScrn, int flags)
pI830->mmSize);
}
}
+#endif
#endif
@@ -2005,7 +2018,7 @@ IntelEmitInvarientState(ScrnInfoPtr pScrn)
drmI830Sarea *sarea;
#endif
- if (pI830->noAccel)
+ if (pI830->noAccel || !I830IsPrimary(pScrn))
return;
#ifdef XF86DRI
@@ -2129,8 +2142,10 @@ I830ScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
MessageType from;
#ifdef XF86DRI
Bool driDisabled;
+#ifdef XF86DRI_MM
unsigned long savedMMSize;
#endif
+#endif
pScrn = xf86Screens[pScreen->myNum];
pI830 = I830PTR(pScrn);
@@ -2257,7 +2272,9 @@ I830ScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
if (!I830CheckDRIAvailable(pScrn)) {
pI830->directRenderingDisabled = TRUE;
+#ifdef XF86DRI_MM
pI830->mmSize = 0;
+#endif
}
if (!pI830->directRenderingDisabled) {
@@ -2307,18 +2324,24 @@ I830ScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
*/
pI830->disableTiling = FALSE;
+#ifdef XF86DRI_MM
savedMMSize = pI830->mmSize;
- for (i = 0; i < 4; i++) {
+#define MM_TURNS 4
+#else
+#define MM_TURNS 2
+#endif
+ for (i = 0; i < MM_TURNS; i++) {
if (!tiled && i < 2)
continue;
- if (i >= 2) {
+ if (i >= MM_TURNS/2) {
/* For further allocations, disable tiling */
pI830->disableTiling = TRUE;
pScrn->displayWidth = savedDisplayWidth;
pI830->allowPageFlip = FALSE;
}
+#ifdef XF86DRI_MM
if (i & 1) {
/* For this allocation, switch to a smaller DRI memory manager
* size.
@@ -2333,6 +2356,11 @@ I830ScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
"\t %s DRI memory manager reservation:\n",
(i & 2) ? "untiled" : "tiled",
(i & 1) ? "small" : "large");
+#else
+ xf86DrvMsg(pScrn->scrnIndex, X_INFO,
+ "Attempting memory allocation with %s buffers:\n",
+ (i & 1) ? "untiled" : "tiled");
+#endif
if (i830_allocate_2d_memory(pScrn) &&
i830_allocate_3d_memory(pScrn))
@@ -2351,10 +2379,12 @@ I830ScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
i830_reset_allocations(pScrn);
}
- if (i == 4) {
+ if (i == MM_TURNS) {
xf86DrvMsg(pScrn->scrnIndex, X_WARNING,
"Not enough video memory. Disabling DRI.\n");
+#ifdef XF86DRI_MM
pI830->mmSize = 0;
+#endif
pI830->directRenderingDisabled = TRUE;
}
} else
@@ -2734,13 +2764,17 @@ I830ScreenInit(int scrnIndex, ScreenPtr pScreen, int argc, char **argv)
I830DRICloseScreen(pScreen);
pI830->directRenderingEnabled = FALSE;
} else {
+ unsigned long aperEnd = ROUND_DOWN_TO(pI830->memory_manager->offset +
+ pI830->memory_manager->size,
+ GTT_PAGE_SIZE) / GTT_PAGE_SIZE;
+ unsigned long aperStart = ROUND_TO(pI830->memory_manager->offset,
+ GTT_PAGE_SIZE) / GTT_PAGE_SIZE;
+
#ifndef XSERVER_LIBDRM_MM
- if (I830DrmMMInit(pI830->drmSubFD, pI830->memory_manager->offset,
- pI830->memory_manager->size,
+ if (I830DrmMMInit(pI830->drmSubFD, aperStart, aperEnd - aperStart,
DRM_BO_MEM_TT)) {
#else
- if (drmMMInit(pI830->drmSubFD, pI830->memory_manager->offset,
- pI830->memory_manager->size,
+ if (drmMMInit(pI830->drmSubFD, aperStart, aperEnd - aperStart,
DRM_BO_MEM_TT)) {
#endif
xf86DrvMsg(pScrn->scrnIndex, X_ERROR,
diff --git a/src/i830_video.c b/src/i830_video.c
index e580dab5..d2f97243 100644
--- a/src/i830_video.c
+++ b/src/i830_video.c
@@ -944,6 +944,8 @@ I830SetPortAttribute(ScrnInfoPtr pScrn,
return BadValue;
pPriv->brightness = value;
overlay->OCLRC0 = (pPriv->contrast << 18) | (pPriv->brightness & 0xff);
+ if (*pI830->overlayOn)
+ OVERLAY_UPDATE;
OVERLAY_DEBUG("BRIGHTNESS\n");
OVERLAY_UPDATE;
} else if (attribute == xvContrast) {
@@ -952,7 +954,8 @@ I830SetPortAttribute(ScrnInfoPtr pScrn,
pPriv->contrast = value;
overlay->OCLRC0 = (pPriv->contrast << 18) | (pPriv->brightness & 0xff);
OVERLAY_DEBUG("CONTRAST\n");
- OVERLAY_UPDATE;
+ if (*pI830->overlayOn)
+ OVERLAY_UPDATE;
} else if (attribute == xvSaturation) {
if ((value < 0) || (value > 1023))
return BadValue;
@@ -973,7 +976,8 @@ I830SetPortAttribute(ScrnInfoPtr pScrn,
else
overlay->OCONFIG |= OVERLAY_PIPE_B;
OVERLAY_DEBUG("PIPE CHANGE\n");
- OVERLAY_UPDATE;
+ if (*pI830->overlayOn)
+ OVERLAY_UPDATE;
} else if (attribute == xvGamma0 && (IS_I9XX(pI830))) {
pPriv->gamma0 = value;
} else if (attribute == xvGamma1 && (IS_I9XX(pI830))) {
@@ -1000,7 +1004,8 @@ I830SetPortAttribute(ScrnInfoPtr pScrn,
break;
}
OVERLAY_DEBUG("COLORKEY\n");
- OVERLAY_UPDATE;
+ if (*pI830->overlayOn)
+ OVERLAY_UPDATE;
REGION_EMPTY(pScrn->pScreen, &pPriv->clip);
} else if(attribute == xvDoubleBuffer) {
if ((value < 0) || (value > 1))
@@ -1018,13 +1023,8 @@ I830SetPortAttribute(ScrnInfoPtr pScrn,
attribute == xvGamma3 ||
attribute == xvGamma4 ||
attribute == xvGamma5) && (IS_I9XX(pI830))) {
- CARD32 r = overlay->OCMD & OVERLAY_ENABLE;
OVERLAY_DEBUG("GAMMA\n");
- overlay->OCMD &= ~OVERLAY_ENABLE;
- OVERLAY_UPDATE;
I830UpdateGamma(pScrn);
- overlay->OCMD |= r;
- OVERLAY_UPDATE;
}
return Success;
diff --git a/src/xvmc/Makefile.am b/src/xvmc/Makefile.am
index 5cd5b25c..a9ea9d1f 100644
--- a/src/xvmc/Makefile.am
+++ b/src/xvmc/Makefile.am
@@ -5,4 +5,5 @@ libI810XvMC_la_SOURCES = I810XvMC.c \
libI810XvMC_la_CFLAGS = @XORG_CFLAGS@ @DRI_CFLAGS@ -I$(top_srcdir)/src -DTRUE=1 -DFALSE=0
libI810XvMC_la_LDFLAGS = -version-number 1:0:0
-endif \ No newline at end of file
+libI810XvMC_la_LIBADD = @DRI_LIBS@
+endif