[prev in list] [next in list] [prev in thread] [next in thread] 

List:       freedesktop-xorg
Subject:    Re: xorg/xserver - [PATCH] Replace ALLOCATE_LOCAL/DEALLOCATE_LOCAL
From:       Paulo Cesar Pereira de Andrade <pcpa () mandriva ! com ! br>
Date:       2008-01-31 17:06:04
Message-ID: 47A1FFFC.1000005 () mandriva ! com ! br
[Download RAW message or body]

pcpa@mandriva.com.br wrote:

  Just remade the correct version in my computer @ work instead
of git-am'ing it.

  Thanks to Alan Coopersmith for noticing the missing replacement
of ALLOCATE_LOCAL with xalloc.


Paulo


["0001-Replace-ALLOCATE_LOCAL-DEALLOCATE_LOCAL-with-xalloc.patch" (text/x-patch)]

From c42234a6ae2b81b06cca954440037189b75ba078 Mon Sep 17 00:00:00 2001
From: Paulo Cesar Pereira de Andrade <pcpa@mandriva.com.br>
Date: Thu, 31 Jan 2008 14:59:13 -0200
Subject: [PATCH] Replace ALLOCATE_LOCAL/DEALLOCATE_LOCAL with xalloc/xfree.

Also add a dummy mfbChangeWindowAttributes function, as the original
one was removed in commit e4d11e58ce349dfe6af2f73ff341317f9b39684c
This only adds a stub for missing symbol xf1bppChangeWindowAttributes
in the vga driver.

This patchisn't enough to make the vga driver work, but solves problems
with missing symbols.
---
 hw/xfree86/xf4bpp/ppcSpMcro.h |    6 +++---
 mfb/mfbwindow.c               |   17 +++++++++++++++++
 2 files changed, 20 insertions(+), 3 deletions(-)

diff --git a/hw/xfree86/xf4bpp/ppcSpMcro.h b/hw/xfree86/xf4bpp/ppcSpMcro.h
index 2b7f951..eeb2cf1 100644
--- a/hw/xfree86/xf4bpp/ppcSpMcro.h
+++ b/hw/xfree86/xf4bpp/ppcSpMcro.h
@@ -28,11 +28,11 @@
 #define SETSPANPTRS(IN,N,IPW,PW,IPPT,PPT,FPW,FPPT,FSORT)		\
 	{								\
 	N = IN * miFindMaxBand(pGC->pCompositeClip);			\
-	if(!(PW = (int *)ALLOCATE_LOCAL(N * sizeof(int))))		\
+	if(!(PW = (int *)xalloc(N * sizeof(int))))			\
 		return;							\
-	if(!(PPT = (DDXPointRec *)ALLOCATE_LOCAL(N * sizeof(DDXPointRec)))) \
+	if(!(PPT = (DDXPointRec *)xalloc(N * sizeof(DDXPointRec))))	\
 		{							\
-		DEALLOCATE_LOCAL(PW);					\
+		xfree(PW);						\
 		return;							\
     		}							\
 	FPW = PW;							\
diff --git a/mfb/mfbwindow.c b/mfb/mfbwindow.c
index 37125da..39397f0 100644
--- a/mfb/mfbwindow.c
+++ b/mfb/mfbwindow.c
@@ -166,3 +166,20 @@ mfbCopyWindow(pWin, ptOldOrg, prgnSrc)
     xfree(pptSrc);
     REGION_DESTROY(pWin->drawable.pScreen, prgnDst);
 }
+
+/*ARGSUSED*/
+Bool
+mfbChangeWindowAttributes(pWin, mask)
+    register WindowPtr pWin;
+    register unsigned long mask;
+{
+    /*
+     * Does this work like in mfbPositionWindow() ?
+     *
+    pWin->drawable.serialNumber = NEXT_SERIAL_NUMBER;
+     */
+
+    /* Again, we have no failure modes indicated by any of the routines
+     * we've called, so we have to assume it worked */
+    return (TRUE);
+}
-- 
1.5.3.5



_______________________________________________
xorg mailing list
xorg@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/xorg

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic