diff options
author | Matthieu Herrb <matthieu.herrb@laas.fr> | 2011-04-02 15:01:45 +0200 |
---|---|---|
committer | Matthieu Herrb <matthieu.herrb@laas.fr> | 2011-04-02 15:01:45 +0200 |
commit | 7d903943b806fe02a747a49e73b574b0bf843ab0 (patch) | |
tree | f6d36b577f25a9e1a111d697a9465b35c52a90a3 | |
parent | eccd9febd2b96b50b1ed7bd900a9dc9a8ddc4d6e (diff) | |
parent | 3c1375afdb9e1be524adae98c3713397d50e3a3e (diff) |
Merge remote branch 'origin/master' into obsd
-rw-r--r-- | README | 64 | ||||
-rw-r--r-- | configure.ac | 2 | ||||
-rw-r--r-- | src/gx_driver.c | 14 | ||||
-rw-r--r-- | src/gx_randr.c | 2 | ||||
-rw-r--r-- | src/lx_display.c | 2 | ||||
-rw-r--r-- | src/lx_driver.c | 4 | ||||
-rw-r--r-- | src/lx_exa.c | 60 |
7 files changed, 74 insertions, 74 deletions
@@ -1,6 +1,6 @@ xf86-video-geode -- AMD Geode GX and LX graphics driver for X.org ================================================================= -README last updated: 2009-09-09 +README last updated: 2011-03-13 GIT repository: git://anongit.freedesktop.org/git/xorg/driver/xf86-video-geode @@ -16,13 +16,21 @@ Project homepage: This is the X graphics driver for the AMD Geode GX and LX processors. The GX driver features XAA and EXA support for graphics acceleration, and the LX driver supports EXA (including compositing). Both drivers -support dynamic rotation with XRandR, and Xv overlay support. +support Xv overlay supprot and dynamic rotation with XRandR. -= Roadmap = += Dependencies = + +As of version 2.9.0, this driver depends on X server 1.3 or newer, +because it utilizes the new common DDC probing libraries from X.Org. -Support for X servers older than 1.4 is expected to be dropped in the -near future. If your distribution still hasn't upgraded, please urge -them to get around it soon. + If necessary, it might be possible to create autoconf macros to make + this driver compile against older X servers, following this example: + + http://lists.freedesktop.org/archives/xorg-commit/2007-February/010341.html + + Patches accomplishing the same trick for the Geode driver are welcome. + += Roadmap = Support for old GX1 Geodes by Cyrix and NSC will be reintroduced soon, at which point xf86-video-cyrix and xf86-video-nsc will be retired. @@ -44,27 +52,22 @@ xf86-video-cyrix Please note that both NSC and GEODE support GX2. This is indeed correct. However, only GEODE has up-to-date code, while NSC is deprecated. -= Dependencies = - -As of version 2.11.4, this driver depends upon X server 1.5 or newer, -because the GX Randr code utilizes dixSetPrivate whose API was modified -in a non backward-compatible way. += Maximum Resolutions = - #ifdef'ing the changes from f1268f3ba8404129d358db3bb1e66f3841f7018a - and b28abde0276ddd7f687242f3886f98b0e49a7fc2 might make it possible - to build this driver against older X servers. Patches are welcome. - -As of version 2.9.0, this driver depends on X server 1.3 or newer, -because it utilizes the new common DDC probing libraries from X.Org. +The driver suppports all maximum resolutions advertized by AMD, namely: - If necessary, it might be possible to create autoconf macros to make - this driver compile against older X servers, following this example: +LX: 1920x1440 (CRT) and 1600x1200 (TFT) +GX: 1600x1200 (CRT) and 1280x1024 (TFT) +SC: 1280x1024 (CRT/TFT) - Currently unsupported by this driver - - http://lists.freedesktop.org/archives/xorg-commit/2007-February/010341.html += FAQ = - Patches accomplishing the same trick for the Geode driver are welcome. +Q: Why doesn't the GEODE driver work at WXGA (wide screen) resolutions? -= FAQ = +A: Make sure that TFT Panel support is disabled in the BIOS settings, + otherwise resolutions will be restricted to traditional VGA modes. + The GEODE offers a choice between CRT-only, CRT+TFT, TFT-only for + output device and selecting CRT-only removes the VGA restriction. Q: Why doesn't screen rotation work? @@ -73,13 +76,6 @@ A: Make sure that a sufficient amount of video RAM is reserved in the BIOS, Couldn't allocate the shadow memory for rotation You need XX bytes, but only YY bytes are available -Q: Why doesn't this GEODE driver work at WXGA (wide screen) resolutions? - -A: Make sure that TFT Panel support is disabled in the BIOS settings, - otherwise resolutions will be restricted to traditional VGA modes. - The GEODE offers a choice between CRT-only, CRT+TFT, TFT-only for - output device and selecting CRT-only removes the VGA restriction. - Q: How do I produce useful information whenever submiting a bug report? A: See http://www.x.org/wiki/Development/Documentation/ServerDebugging @@ -87,7 +83,7 @@ A: See http://www.x.org/wiki/Development/Documentation/ServerDebugging Q: How do I test development snapshots from the upstream GIT repository? -A: Run the following commands from a command line interpreter shell... +A: Run the following commands from a command line interpreter shell: 1. git clone git://anongit.freedesktop.org/git/xorg/driver/xf86-video-geode 2. Debian/Ubuntu: apt-get install autoconf automake libtool xutils-dev apt-get install build-dep xserver-xorg-video-geode @@ -106,16 +102,16 @@ A: See http://www.x.org/wiki/Development/Documentation/SubmittingPatches = Configuration options = -You can specify the Geode driver in the normal fashion: +You can specify driver options in /etc/xorg.conf in the usual fashion: Section "Device" Identifier "AMD Geode" Driver "geode" - Option "blah" "blah" + Option "OptionName" "value" ... EndSection -The following options may be added to the section: +The following options may be added to such a Device section: == Common options == @@ -123,7 +119,7 @@ FBSize: Specify the size of the video space (in bytes) NoAccel: Disable hardware assisted acceleration NoCompression: Disable video bandwidth compression NoPanel: Disable panel support -Rotate: Select a orientation to start with - LEFT, INVERT, CCW +Rotate: Select an initial orientation - LEFT, INVERT, CCW SWCursor: Enable software cursors (essentially disabling HW cursor support) == GX-specific options == diff --git a/configure.ac b/configure.ac index 124b3c3..483caff 100644 --- a/configure.ac +++ b/configure.ac @@ -22,7 +22,7 @@ AC_PREREQ(2.59) AC_INIT([xf86-video-geode], - [2.11.11], + [2.11.12], [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg&component=Driver%2Fgeode], [xf86-video-geode], [http://www.x.org/wiki/GeodeDriver]) diff --git a/src/gx_driver.c b/src/gx_driver.c index e2ed44b..47c20d2 100644 --- a/src/gx_driver.c +++ b/src/gx_driver.c @@ -426,7 +426,7 @@ GXPreInit(ScrnInfoPtr pScrni, int flags) return FALSE; #endif - pGeode = pScrni->driverPrivate = xnfcalloc(sizeof(GeodeRec), 1); + pGeode = pScrni->driverPrivate = xnfcalloc(1, sizeof(GeodeRec)); if (pGeode == NULL) return FALSE; @@ -447,7 +447,7 @@ GXPreInit(ScrnInfoPtr pScrni, int flags) pGeode->useVGA = FALSE; #if INT10_SUPPORT - pGeode->vesa = calloc(sizeof(VESARec), 1); + pGeode->vesa = calloc(1, sizeof(VESARec)); #endif } @@ -649,7 +649,7 @@ GXPreInit(ScrnInfoPtr pScrni, int flags) else pScrni->videoRam = pGeode->pEnt->device->videoRam; - GeodeClockRange = (ClockRangePtr) xnfcalloc(sizeof(ClockRange), 1); + GeodeClockRange = (ClockRangePtr) xnfcalloc(1, sizeof(ClockRange)); GeodeClockRange->next = NULL; GeodeClockRange->minClock = 25175; GeodeClockRange->maxClock = 229500; @@ -1259,11 +1259,11 @@ GXScreenInit(int scrnIndex, ScreenPtr pScrn, int argc, char **argv) } } else { pGeode->AccelImageWriteBuffers = - calloc(sizeof(pGeode->AccelImageWriteBuffers[0]), - pGeode->NoOfImgBuffers); + calloc(pGeode->NoOfImgBuffers, + sizeof(pGeode->AccelImageWriteBuffers[0])); pGeode->AccelColorExpandBuffers = - calloc(sizeof(pGeode->AccelColorExpandBuffers[0]), - pGeode->NoOfColorExpandLines); + calloc(pGeode->NoOfColorExpandLines, + sizeof(pGeode->AccelColorExpandBuffers[0])); } } diff --git a/src/gx_randr.c b/src/gx_randr.c index 345eaa5..116678d 100644 --- a/src/gx_randr.c +++ b/src/gx_randr.c @@ -351,7 +351,7 @@ GXRandRInit(ScreenPtr pScreen, int rotation) return FALSE; #endif - pRandr = calloc(sizeof(XF86RandRInfoRec), 1); + pRandr = calloc(1, sizeof(XF86RandRInfoRec)); if (pRandr == NULL) return FALSE; diff --git a/src/lx_display.c b/src/lx_display.c index ca6fed1..1f240f5 100644 --- a/src/lx_display.c +++ b/src/lx_display.c @@ -577,7 +577,7 @@ LXSetupCrtc(ScrnInfoPtr pScrni) return; } - lxpriv = xnfcalloc(sizeof(LXCrtcPrivateRec), 1); + lxpriv = xnfcalloc(1, sizeof(LXCrtcPrivateRec)); if (!lxpriv) { xf86CrtcDestroy(crtc); diff --git a/src/lx_driver.c b/src/lx_driver.c index 477939d..a17854c 100644 --- a/src/lx_driver.c +++ b/src/lx_driver.c @@ -300,7 +300,7 @@ LXPreInit(ScrnInfoPtr pScrni, int flags) return TRUE; } - pGeode = pScrni->driverPrivate = xnfcalloc(sizeof(GeodeRec), 1); + pGeode = pScrni->driverPrivate = xnfcalloc(1, sizeof(GeodeRec)); if (pGeode == NULL) return FALSE; @@ -313,7 +313,7 @@ LXPreInit(ScrnInfoPtr pScrni, int flags) if (!xf86LoadSubModule(pScrni, "vgahw") || !vgaHWGetHWRec(pScrni)) pGeode->useVGA = FALSE; - pGeode->vesa = calloc(sizeof(VESARec), 1); + pGeode->vesa = calloc(1, sizeof(VESARec)); } cim_rdmsr = LXReadMSR; diff --git a/src/lx_exa.c b/src/lx_exa.c index 6bc84ea..ef90d6b 100644 --- a/src/lx_exa.c +++ b/src/lx_exa.c @@ -48,6 +48,19 @@ #define F(x) IntToxFixed(x) #define I(x) xFixedToInt(x) +#define GEODE_TRACE_FALL 0 + +#if GEODE_TRACE_FALL +#define GEODE_FALLBACK(x) \ +do { \ + ErrorF("%s: ", __FUNCTION__); \ + ErrorF x; \ + return FALSE; \ +} while (0) +#else +#define GEODE_FALLBACK(x) return FALSE +#endif + static const struct exa_format_t { int exa; @@ -532,10 +545,8 @@ lx_check_composite(int op, PicturePtr pSrc, PicturePtr pMsk, PicturePtr pDst) GeodeRec *pGeode = GEODEPTR_FROM_PICTURE(pDst); const struct exa_format_t *srcFmt, *dstFmt; - /* Check that the operation is supported */ - if (op > PictOpAdd) - return FALSE; + GEODE_FALLBACK(("Operation %d is not supported\n", op)); /* FIXME: Meet this conditions from the debug for PictOpAdd. * Any Other possibilities? Add a judge for the future supplement */ @@ -551,15 +562,13 @@ lx_check_composite(int op, PicturePtr pSrc, PicturePtr pMsk, PicturePtr pDst) pDst->format == PICT_a8 && !pMsk) return TRUE; - /* We need the off-screen buffer to do the multipass work */ - if (usesPasses(op)) { if (pGeode->exaBfrOffset == 0 || !pMsk) - return FALSE; + GEODE_FALLBACK(("Multipass operation requires off-screen buffer\n")); } if (pMsk && op == PictOpAdd) - return FALSE; + GEODE_FALLBACK(("PictOpAdd with mask is not supported\n")); /* Check that the filter matches what we support */ @@ -571,17 +580,15 @@ lx_check_composite(int op, PicturePtr pSrc, PicturePtr pMsk, PicturePtr pDst) break; default: - /* WE don't support bilinear or convolution filters */ - return FALSE; + GEODE_FALLBACK(("Bilinear or convolution filters are not supported\n")); } - /* We don't support any mask transforms */ if (pMsk && pMsk->transform) - return FALSE; + GEODE_FALLBACK(("Mask transforms are not supported\n")); /* XXX - don't know if we can do any hwaccel on solid fills or gradient types */ if (pSrc->pSourcePict || (pMsk && pMsk->pSourcePict)) - return FALSE; + GEODE_FALLBACK(("Solid fills or gradient types are not supported\n")); /* Keep an eye out for source rotation transforms - those we can * do something about */ @@ -590,13 +597,12 @@ lx_check_composite(int op, PicturePtr pSrc, PicturePtr pMsk, PicturePtr pDst) exaScratch.transform = NULL; if (pSrc->transform && !lx_process_transform(pSrc)) - return FALSE; + GEODE_FALLBACK(("Transform operation is non-trivial\n")); /* XXX - I don't understand PICT_a8 enough - so I'm punting */ - if ((op != PictOpAdd) && (pSrc->format == PICT_a8 || pDst->format == PICT_a8)) - return FALSE; + GEODE_FALLBACK(("PICT_a8 as src or dst format is unsupported\n")); if (pMsk && op != PictOpClear) { struct blend_ops_t *opPtr = &lx_alpha_ops[op * 2]; @@ -605,21 +611,21 @@ lx_check_composite(int op, PicturePtr pSrc, PicturePtr pMsk, PicturePtr pDst) /* Direction 0 indicates src->dst, 1 indiates dst->src */ if (((direction == 0) && (pSrc->pDrawable->bitsPerPixel < 16)) || ((direction == 1) && (pDst->pDrawable->bitsPerPixel < 16))) { - ErrorF("Can't do mask blending with less then 16bpp\n"); + ErrorF("Mask blending unsupported with <16bpp\n"); return FALSE; } - /* We can only do masks with a 8bpp or a 4bpp mask */ if (pMsk->format != PICT_a8 && pMsk->format != PICT_a4) - return FALSE; + GEODE_FALLBACK(("Masks can be only done with a 8bpp or 4bpp depth\n")); + /* The pSrc should be 1x1 pixel if the pMsk is not zero */ if (pSrc->pDrawable->width != 1 || pSrc->pDrawable->height != 1) - return FALSE; + GEODE_FALLBACK(("pSrc should be 1x1 pixel if pMsk is not zero\n")); /* FIXME: In lx_prepare_composite, there are no variables to record the * one pixel source's width and height when the mask is not zero. * That will lead to bigger region to render instead of one pixel in lx * _do_composite, so we should fallback currently to avoid this */ if (!pSrc->repeat) - return FALSE; + GEODE_FALLBACK(("FIXME: unzero mask might lead to bigger rendering region than 1x1 pixels\n")); } /* Get the formats for the source and destination */ @@ -630,7 +636,7 @@ lx_check_composite(int op, PicturePtr pSrc, PicturePtr pMsk, PicturePtr pDst) } if ((dstFmt = lx_get_format(pDst)) == NULL) { - ErrorF("EXA: Invalid destination format %x\n", pDst->format); + ErrorF("EXA: Invalid destination format %x\n", pDst->format); return FALSE; } @@ -638,21 +644,19 @@ lx_check_composite(int op, PicturePtr pSrc, PicturePtr pMsk, PicturePtr pDst) /* If a mask is enabled, the alpha will come from there */ if (!pMsk && (!srcFmt->alphabits && usesSrcAlpha(op))) - return FALSE; + GEODE_FALLBACK(("Operation requires src alpha, but alphabits is unset\n")); if (!pMsk && (!dstFmt->alphabits && usesDstAlpha(op))) - return FALSE; - - /* FIXME: See a way around this! */ + GEODE_FALLBACK(("Operation requires dst alpha, but alphabits is unset\n")); + /* FIXME: See a way around this! */ if (srcFmt->alphabits == 0 && dstFmt->alphabits != 0) - return FALSE; + GEODE_FALLBACK(("src_alphabits=0, dst_alphabits!=0\n")); /* If this is a rotate operation, then make sure the src and dst * formats are the same */ - if (exaScratch.rotate != RR_Rotate_0 && srcFmt != dstFmt) { - ErrorF("EXA: Can't rotate and convert formats at the same time\n"); + ErrorF("EXA: Unable to rotate and convert formats at the same time\n"); return FALSE; } return TRUE; |