Re: [PATCH] dix: a valuator count of 0 is valid (#34510)

2011-02-21 Thread Timo Aaltonen
On 21.02.2011 07:39, Peter Hutterer wrote:
 For all but motion and proximity events, having no valuators is ok.
 Regression from 1.9, keyboard events are not converted to protocol events.
 
 X.Org Bug 34510 http://bugs.freedesktop.org/show_bug.cgi?id=34510
 
 Signed-off-by: Peter Hutterer peter.hutte...@who-t.net

Thanks! Mumble works now.

Tested-by: Timo Aaltonen timo.aalto...@canonical.com
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel


[PATCH joystick] Remove old input ABI leftovers from jstkCoreUnInit

2011-03-18 Thread Timo Aaltonen
From: Timo Aaltonen timo.aalto...@canonical.com

Fixes crashes on device unplug:
https://bugs.freedesktop.org/show_bug.cgi?id=35391

Signed-off-by: Timo Aaltonen timo.aalto...@canonical.com
---
 src/jstk.c |7 ---
 1 files changed, 0 insertions(+), 7 deletions(-)

diff --git a/src/jstk.c b/src/jstk.c
index 9796a46..41cace7 100644
--- a/src/jstk.c
+++ b/src/jstk.c
@@ -622,13 +622,6 @@ jstkCoreUnInit(InputDriverPtrdrv,
 {
 JoystickDevPtr device = (JoystickDevPtr) pInfo-private;
 
-if (device-keyboard_device != NULL)
-{
-xf86DisableDevice(device-keyboard_device-dev, TRUE);
-device-keyboard_device = NULL;
-}
-
-free (device);
 pInfo-private = NULL;
 xf86DeleteInput(pInfo, 0);
 }
-- 
1.7.4.1

___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel


Re: [PATCH joystick] Remove old input ABI leftovers from jstkCoreUnInit

2011-03-22 Thread TImo Aaltonen
On 22.03.2011 08:42, Peter Hutterer wrote:
 On Fri, Mar 18, 2011 at 07:13:38PM +0200, Timo Aaltonen wrote:
 From: Timo Aaltonen timo.aalto...@canonical.com

 Fixes crashes on device unplug:
 https://bugs.freedesktop.org/show_bug.cgi?id=35391

 Signed-off-by: Timo Aaltonen timo.aalto...@canonical.com
 ---
  src/jstk.c |7 ---
  1 files changed, 0 insertions(+), 7 deletions(-)

 diff --git a/src/jstk.c b/src/jstk.c
 index 9796a46..41cace7 100644
 --- a/src/jstk.c
 +++ b/src/jstk.c
 @@ -622,13 +622,6 @@ jstkCoreUnInit(InputDriverPtrdrv,
  {
  JoystickDevPtr device = (JoystickDevPtr) pInfo-private;
  
 -if (device-keyboard_device != NULL)
 -{
 -xf86DisableDevice(device-keyboard_device-dev, TRUE);
 -device-keyboard_device = NULL;
 -}
 
 that's not quite enough. we still support ABI 11. in theory anyway, I don't
 think either has been actually tested on a device.
 so the if condition removal should go into a ifdef ABI = 12
 
 alternatively, you could just up the driver to only support ABI 12. as long
 as no-one steps up to maintain it, I'm happy to keep it in lockstep with the
 server at least.

Duh, yes.. I misread the commit log. Pre-ABI 11 support was dropped
earlier, so I'll add the ifdef.

 -
 -free (device);
 
 some comment explainig _why_ this fixes the crash in the commit message
 would have been nice.
 
 turns out that pInfo-private is shared between the keyboard device and the 
 actual device and this would cause a double free.
 
 and the condition above is obsolete because with input ABI 12, devices that
 are hotplugged through the driver are removed by the server now.

Right, I'll make it more clear in the next version.

t

___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel


[PATCH joystick] Fix crashes on unplug due to double-free with ABI 12.

2011-03-22 Thread Timo Aaltonen
From: Timo Aaltonen timo.aalto...@canonical.com

With ABI 12 and newer the server removes devices
hotplugged through the driver. And pInfo-private is shared
between the keyboard device and actual one, so these combined
mean there's a double-free which would result in a server crash
on unplug.

https://bugs.freedesktop.org/show_bug.cgi?id=35391

Signed-off-by: Timo Aaltonen timo.aalto...@canonical.com
---
 src/jstk.c |2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/src/jstk.c b/src/jstk.c
index 9796a46..8fa97c0 100644
--- a/src/jstk.c
+++ b/src/jstk.c
@@ -622,6 +622,7 @@ jstkCoreUnInit(InputDriverPtrdrv,
 {
 JoystickDevPtr device = (JoystickDevPtr) pInfo-private;
 
+#if GET_ABI_MAJOR(ABI_XINPUT_VERSION)  12
 if (device-keyboard_device != NULL)
 {
 xf86DisableDevice(device-keyboard_device-dev, TRUE);
@@ -629,6 +630,7 @@ jstkCoreUnInit(InputDriverPtrdrv,
 }
 
 free (device);
+#endif
 pInfo-private = NULL;
 xf86DeleteInput(pInfo, 0);
 }
-- 
1.7.4.1

___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel


[PATCH sis 04/15] Fix suggest parentheses around operand of ‘!’ compiler warnings.

2011-04-06 Thread Timo Aaltonen
Signed-off-by: Timo Aaltonen timo.aalto...@canonical.com
---
 src/sis_cursor.c  |2 +-
 src/sis_utility.c |2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/sis_cursor.c b/src/sis_cursor.c
index 13eddc4..67a3402 100644
--- a/src/sis_cursor.c
+++ b/src/sis_cursor.c
@@ -759,7 +759,7 @@ SiS300LoadCursorImage(ScrnInfoPtr pScrn, UChar *src)
 }
 
 if(pSiS-VBFlags  CRT2_ENABLE) {
-   if((pSiS-UseHWARGBCursor)  (!pSiS-VBFlags  DISPTYPE_CRT1)) {
+   if((pSiS-UseHWARGBCursor)  ((!pSiS-VBFlags)  DISPTYPE_CRT1)) {
  status2 = sis301GetCursorStatus;
  sis301DisableHWCursor()
  SISWaitRetraceCRT2(pScrn);
diff --git a/src/sis_utility.c b/src/sis_utility.c
index 64d8919..0892cf5 100644
--- a/src/sis_utility.c
+++ b/src/sis_utility.c
@@ -523,7 +523,7 @@ SISSwitchCRT2Type(ScrnInfoPtr pScrn, ULong newvbflags, Bool 
quiet)
 }
 #endif
 
-if((!(newvbflags  CRT2_ENABLE))  (!newvbflags  DISPTYPE_CRT1)) {
+if((!(newvbflags  CRT2_ENABLE))  ((!newvbflags)  DISPTYPE_CRT1)) {
if(!quiet) {
   xf86DrvMsg(pScrn-scrnIndex, X_ERROR,
  CRT2 can't be switched off while CRT1 is off\n);
-- 
1.7.4.1

___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel


[PATCH sis 00/15] a bunch of cleanups, and a taste of things to come

2011-04-06 Thread Timo Aaltonen
Here's a first set of patches to xf86-video-sis, hoping to narrow down
the diff against Thomas Winischofer's 'sisfree' (*) package and the
forked versions from Intel and SiS (and Mandriva).

The first 13 are more or less self-explanatory, but the two final ones
are moving things around to make the code more readable, among other things.

Every commit is build-tested against xserver 1.10 headers.

* http://www.winischhofer.net/linuxsispart4.shtml#download

Timo Aaltonen (15):
  Write out remaining IS_SIS* macros.
  Replace deprecated x(c)alloc/xfree with m/calloc/free
  Fix format not a string literal and no format arguments compile
warnings
  Fix suggest parentheses around operand of ‘!’ compiler warnings.
  Fix compile warnings of uninitialized variables
  Declare mmioFlags only if XSERVER_LIBPCIACCESS isn't defined
  Purge obsolete and unused SIS_CP checks
  Drop useless checks and relevant code for old XFree86 releases
  Drop unused and non-working XAA trapezoid support for 310 series and
later
  Remove unused code from sis_video.c
  Remove unused code from SISPutImageBlit()
  Remove unused  non-working Xv deinterlacer code
  Remove deprecated XV SD interface
  Move configurable values from sis.h to sis_config.h
  Move all TV related functions fron sis_driver.c to sis_vb.c

 src/init.c  |   35 +-
 src/init.h  |3 -
 src/init301.c   |   62 +-
 src/init301.h   |3 -
 src/initdef.h   |   19 +-
 src/initextx.c  |   18 +-
 src/sis.h   |   86 +--
 src/sis310_accel.c  |  754 ---
 src/sis6326_video.c |   60 +--
 src/sis_accel.c |  128 ---
 src/sis_config.h|   71 ++
 src/sis_cursor.c|8 +-
 src/sis_dac.h   |2 +
 src/sis_dga.c   |6 +-
 src/sis_dri.c   |   38 +-
 src/sis_driver.c| 2625 ---
 src/sis_driver.h|  813 +
 src/sis_memcpy.c|   10 +-
 src/sis_opt.c   |   49 +-
 src/sis_utility.c   |  527 +--
 src/sis_vb.c| 2259 ++--
 src/sis_vb.h|  931 ++
 src/sis_vga.c   |7 +-
 src/sis_video.c |  291 +--
 src/sis_video.h |  195 
 src/sis_videostr.h  |3 -
 src/vgatypes.h  |5 -
 27 files changed, 3490 insertions(+), 5518 deletions(-)
 create mode 100644 src/sis_config.h
 create mode 100644 src/sis_vb.h

-- 
1.7.4.1

___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel

[PATCH sis 03/15] Fix format not a string literal and no format arguments compile warnings

2011-04-06 Thread Timo Aaltonen
Signed-off-by: Timo Aaltonen timo.aalto...@canonical.com
---
 src/sis_driver.c |8 
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/src/sis_driver.c b/src/sis_driver.c
index 8ce1cdd..337bba6 100644
--- a/src/sis_driver.c
+++ b/src/sis_driver.c
@@ -403,14 +403,14 @@ SISErrorLog(ScrnInfoPtr pScrn, const char *format, ...)
 static const char *str = 
**\n;
 
 va_start(ap, format);
-xf86DrvMsg(pScrn-scrnIndex, X_ERROR, str);
+xf86DrvMsg(pScrn-scrnIndex, X_ERROR, %s, str);
 xf86DrvMsg(pScrn-scrnIndex, X_ERROR,
  ERROR:\n);
 xf86VDrvMsgVerb(pScrn-scrnIndex, X_ERROR, 1, format, ap);
 va_end(ap);
 xf86DrvMsg(pScrn-scrnIndex, X_ERROR,
  END OF MESSAGE\n);
-xf86DrvMsg(pScrn-scrnIndex, X_ERROR, str);
+xf86DrvMsg(pScrn-scrnIndex, X_ERROR, %s, str);
 }
 
 static void
@@ -1888,14 +1888,14 @@ SiSUpdateXineramaScreenInfo(ScrnInfoPtr pScrn1)
if(infochanged  !usenonrect) {
  xf86DrvMsg(pScrn1-scrnIndex, X_INFO,
Virtual screen size does not match maximum display 
modes...\n);
- xf86DrvMsg(pScrn1-scrnIndex, X_INFO, rectxine);
+ xf86DrvMsg(pScrn1-scrnIndex, X_INFO, %s, rectxine);
 
}
 } else if(infochanged  usenonrect) {
usenonrect = FALSE;
xf86DrvMsg(pScrn1-scrnIndex, X_INFO,
Only clone modes available for this virtual screen size...\n);
-   xf86DrvMsg(pScrn1-scrnIndex, X_INFO, rectxine);
+   xf86DrvMsg(pScrn1-scrnIndex, X_INFO, %s, rectxine);
 }
 
 if(pSiS-maxCRT1_X1) { /* Means we have at least one non-clone 
mode */
-- 
1.7.4.1

___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel


[PATCH sis 02/15] Replace deprecated x(c)alloc/xfree with m/calloc/free

2011-04-06 Thread Timo Aaltonen
and xrealloc with realloc.

Signed-off-by: Timo Aaltonen timo.aalto...@canonical.com
---
 src/initextx.c  |   18 
 src/sis6326_video.c |6 +-
 src/sis_dga.c   |6 +-
 src/sis_dri.c   |   24 +-
 src/sis_driver.c|  128 +-
 src/sis_memcpy.c|   10 ++--
 src/sis_opt.c   |   12 ++--
 src/sis_utility.c   |6 +-
 src/sis_vga.c   |2 +-
 src/sis_video.c |8 ++--
 10 files changed, 110 insertions(+), 110 deletions(-)

diff --git a/src/initextx.c b/src/initextx.c
index 5c00398..1e84d0f 100644
--- a/src/initextx.c
+++ b/src/initextx.c
@@ -238,10 +238,10 @@ SiSBuildBuiltInModeList(ScrnInfoPtr pScrn, BOOLEAN 
includelcdmodes, BOOLEAN isfo
 continue;
   }
 
-  if(!(new = xalloc(sizeof(DisplayModeRec return first;
+  if(!(new = malloc(sizeof(DisplayModeRec return first;
   memset(new, 0, sizeof(DisplayModeRec));
-  if(!(new-name = xalloc(10))) {
-xfree(new);
+  if(!(new-name = malloc(10))) {
+free(new);
 return first;
   }
   if(!first) first = new;
@@ -385,11 +385,11 @@ SiSBuildBuiltInModeList(ScrnInfoPtr pScrn, BOOLEAN 
includelcdmodes, BOOLEAN isfo
 }
  }
 
- if(!(new = xalloc(sizeof(DisplayModeRec return first;
+ if(!(new = malloc(sizeof(DisplayModeRec return first;
 
  memset(new, 0, sizeof(DisplayModeRec));
- if(!(new-name = xalloc(12))) {
-xfree(new);
+ if(!(new-name = malloc(12))) {
+free(new);
 return first;
  }
  if(!first) first = new;
@@ -470,11 +470,11 @@ SiSBuildBuiltInModeList(ScrnInfoPtr pScrn, BOOLEAN 
includelcdmodes, BOOLEAN isfo
 
 if(pSiS-SiS_Pr-CP_DataValid[i]) {
 
-   if(!(new = xalloc(sizeof(DisplayModeRec return first;
+   if(!(new = malloc(sizeof(DisplayModeRec return first;
 
memset(new, 0, sizeof(DisplayModeRec));
-   if(!(new-name = xalloc(10))) {
-  xfree(new);
+   if(!(new-name = malloc(10))) {
+  free(new);
   return first;
}
if(!first) first = new;
diff --git a/src/sis6326_video.c b/src/sis6326_video.c
index c6b18e2..66352b7 100644
--- a/src/sis6326_video.c
+++ b/src/sis6326_video.c
@@ -170,7 +170,7 @@ void SIS6326InitVideo(ScreenPtr pScreen)
adaptors = newAdaptor;
} else {
/* need to free this someplace */
-   newAdaptors = xalloc((num_adaptors + 1) * 
sizeof(XF86VideoAdaptorPtr*));
+   newAdaptors = malloc((num_adaptors + 1) * 
sizeof(XF86VideoAdaptorPtr*));
if(newAdaptors) {
memcpy(newAdaptors, adaptors, num_adaptors *
sizeof(XF86VideoAdaptorPtr));
@@ -185,7 +185,7 @@ void SIS6326InitVideo(ScreenPtr pScreen)
xf86XVScreenInit(pScreen, adaptors, num_adaptors);
 
 if(newAdaptors)
-   xfree(newAdaptors);
+   free(newAdaptors);
 }
 
 /* client libraries expect an encoding */
@@ -531,7 +531,7 @@ SIS6326SetupImageVideo(ScreenPtr pScreen)
return NULL;
 #endif
 
-if(!(adapt = xcalloc(1, sizeof(XF86VideoAdaptorRec) +
+if(!(adapt = calloc(1, sizeof(XF86VideoAdaptorRec) +
 sizeof(SISPortPrivRec) +
 sizeof(DevUnion
return NULL;
diff --git a/src/sis_dga.c b/src/sis_dga.c
index d358645..16b0ee4 100644
--- a/src/sis_dga.c
+++ b/src/sis_dga.c
@@ -150,18 +150,18 @@ SISSetupDGAMode(
 
if(pMode-HDisplay != otherPitch) {
 
-   newmodes = xrealloc(modes, (*num + 2) * sizeof(DGAModeRec));
+   newmodes = realloc(modes, (*num + 2) * sizeof(DGAModeRec));
oneMore  = TRUE;
 
} else {
 
-   newmodes = xrealloc(modes, (*num + 1) * sizeof(DGAModeRec));
+   newmodes = realloc(modes, (*num + 1) * sizeof(DGAModeRec));
oneMore  = FALSE;
 
}
 
if(!newmodes) {
-   xfree(modes);
+   free(modes);
return NULL;
}
modes = newmodes;
diff --git a/src/sis_dri.c b/src/sis_dri.c
index 3a476a2..97ed951 100644
--- a/src/sis_dri.c
+++ b/src/sis_dri.c
@@ -149,19 +149,19 @@ SISInitVisualConfigs(ScreenPtr pScreen)
   case 32:
 numConfigs = (useZ16) ? 8 : 16;
 
-if(!(pConfigs = (__GLXvisualConfig*)xcalloc(sizeof(__GLXvisualConfig),
+if(!(pConfigs = (__GLXvisualConfig*)calloc(sizeof(__GLXvisualConfig),
   numConfigs))) {
return FALSE;
 }
-if(!(pSISConfigs = (SISConfigPrivPtr)xcalloc(sizeof(SISConfigPrivRec),
+if(!(pSISConfigs = (SISConfigPrivPtr)calloc(sizeof(SISConfigPrivRec),
numConfigs))) {
-   xfree(pConfigs);
+   free

[PATCH sis 01/15] Write out remaining IS_SIS* macros.

2011-04-06 Thread Timo Aaltonen
Signed-off-by: Timo Aaltonen timo.aalto...@canonical.com
---
 src/init.c|   35 +--
 src/init301.c |   48 
 src/initdef.h |   19 +--
 3 files changed, 50 insertions(+), 52 deletions(-)

diff --git a/src/init.c b/src/init.c
index 74df1f5..9dfb6cf 100644
--- a/src/init.c
+++ b/src/init.c
@@ -1276,7 +1276,7 @@ SiSDetermineROMLayout661(struct SiS_Private *SiS_Pr)
   if((romvmaj != 0) || (romvmin = 92)) {
 return TRUE;
   }
-   } else if(IS_SIS650740) {
+   } else if((SiS_Pr-ChipType = SIS_650)  (SiS_Pr-ChipType = SIS_740)) {
   if((ROMAddr[0x1a] == 'N') 
 (ROMAddr[0x1b] == 'e') 
 (ROMAddr[0x1c] == 'w') 
@@ -1404,7 +1404,7 @@ SiS_ResetSegmentRegOver(struct SiS_Private *SiS_Pr)
 static void
 SiS_ResetSegmentRegisters(struct SiS_Private *SiS_Pr)
 {
-   if((IS_SIS65x) || (SiS_Pr-ChipType = SIS_661)) {
+   if((SiS_Pr-SiS_SysFlags  SF_Is65x) || (SiS_Pr-ChipType = SIS_661)) {
   SiS_ResetSegmentReg(SiS_Pr);
   SiS_ResetSegmentRegOver(SiS_Pr);
}
@@ -1522,7 +1522,9 @@ SiS_Get310DRAMType(struct SiS_Private *SiS_Pr)
 } else {
data = SiS_GetReg(SiS_Pr-SiS_P3d4,0x78)  0x07;
 }
-  } else if(IS_SIS550650740) {
+  } else if((SiS_Pr-ChipType == SIS_550) ||
+   (SiS_Pr-ChipType == SIS_650) ||
+   (SiS_Pr-ChipType == SIS_740)) {
 data = SiS_GetReg(SiS_Pr-SiS_P3c4,0x13)  0x07;
   } else { /* 315, 330 */
 data = SiS_GetReg(SiS_Pr-SiS_P3c4,0x3a)  0x03;
@@ -1732,17 +1734,25 @@ SiS_SetLowModeTest(struct SiS_Private *SiS_Pr, unsigned 
short ModeNo)
 static void
 SiS_OpenCRTC(struct SiS_Private *SiS_Pr)
 {
-   if(IS_SIS650) {
+   switch(SiS_Pr-ChipType) {
+   case SIS_650:
   SiS_SetRegAND(SiS_Pr-SiS_P3d4,0x51,0x1f);
-  if(IS_SIS651) SiS_SetRegOR(SiS_Pr-SiS_P3d4,0x51,0x20);
+  if(SiS_Pr-SiS_SysFlags  (SF_Is651 | SF_Is652)) {
+   SiS_SetRegOR(SiS_Pr-SiS_P3d4,0x51,0x20);
+  }
   SiS_SetRegAND(SiS_Pr-SiS_P3d4,0x56,0xe7);
-   } else if(IS_SIS661741660760) {
+  break;
+   case SIS_661:
+   case SIS_741:
+   case SIS_660:
+   case SIS_760:
   SiS_SetRegAND(SiS_Pr-SiS_P3d4,0x61,0xf7);
   SiS_SetRegAND(SiS_Pr-SiS_P3d4,0x51,0x1f);
   SiS_SetRegAND(SiS_Pr-SiS_P3d4,0x56,0xe7);
   if(!SiS_Pr-SiS_ROMNew) {
 SiS_SetRegAND(SiS_Pr-SiS_P3d4,0x3a,0xef);
   }
+  break;
}
 }
 
@@ -1752,7 +1762,11 @@ SiS_CloseCRTC(struct SiS_Private *SiS_Pr)
 #if 0 /* This locks some CRTC registers. We don't want that. */
unsigned short temp1 = 0, temp2 = 0;
 
-   if(IS_SIS661741660760) {
+   switch(SiS_Pr-ChipType) {
+   case SIS_661:
+   case SIS_741:
+   case SIS_660:
+   case SIS_760:
   if(SiS_Pr-SiS_VBInfo  SetCRT2ToLCDA) {
  temp1 = 0xa0; temp2 = 0x08;
   }
@@ -1953,7 +1967,8 @@ SiS_SetATTRegs(struct SiS_Private *SiS_Pr, unsigned short 
StandTableIndex)
}
 } else if(SiS_Pr-SiS_VBInfo  SetCRT2ToLCD) {
if(SiS_Pr-ChipType = SIS_315H) {
-  if(IS_SIS550650740660) {
+  if((SiS_Pr-ChipType = SIS_550) 
+ (SiS_Pr-ChipType != SIS_330)) {
  /* 315, 330 don't do this */
  if(SiS_Pr-SiS_VBType  VB_SIS30xB) {
 if(SiS_Pr-SiS_VBInfo  SetInSlaveMode) ARdata = 0;
@@ -3134,7 +3149,7 @@ SiS_StrangeStuff(struct SiS_Private *SiS_Pr)
 * this here.
 */
 #ifdef SIS315H
-   if((IS_SIS651) || (IS_SISM650) ||
+   if((SiS_Pr-SiS_SysFlags  SF_Is65x) ||
   SiS_Pr-ChipType == SIS_340 ||
   SiS_Pr-ChipType == XGI_40) {
   SiS_SetReg(SiS_Pr-SiS_VidCapt, 0x3f, 0x00);   /* Fiddle with capture 
regs */
@@ -3401,7 +3416,7 @@ SiSSetMode(struct SiS_Private *SiS_Pr, unsigned short 
ModeNo)
 
 SiS_SetReg(SiS_Pr-SiS_P3d4,0x38,backupreg);
 
-if((IS_SIS650)  (SiS_GetReg(SiS_Pr-SiS_P3d4,0x30)  0xfc)) {
+if((SiS_Pr-ChipType == SIS_650)  (SiS_GetReg(SiS_Pr-SiS_P3d4,0x30) 
 0xfc)) {
if((ModeNo == 0x03) || (ModeNo == 0x10)) {
   SiS_SetRegOR(SiS_Pr-SiS_P3d4,0x51,0x80);
   SiS_SetRegOR(SiS_Pr-SiS_P3d4,0x56,0x08);
diff --git a/src/init301.c b/src/init301.c
index ffa6eaa..603ecb6 100644
--- a/src/init301.c
+++ b/src/init301.c
@@ -984,7 +984,7 @@ SiS_GetVBInfo(struct SiS_Private *SiS_Pr, unsigned short 
ModeNo,
 /* Reset LCDA setting if not driver mode */
 SiS_SetRegAND(SiS_Pr-SiS_P3d4,0x38,0xfc);
  }
- if(IS_SIS650) {
+ if(SiS_Pr-ChipType == SIS_650) {
 if(SiS_Pr-SiS_UseLCDA) {
if(SiS_GetReg(SiS_Pr-SiS_P3d4,0x5f)  0xF0) {
   if((ModeNo = 0x13) || 
(!(SiS_GetReg(SiS_Pr-SiS_P3d4,0x31)  (DriverMode  8 {
@@ -2557,7 +2557,7 @@ SiS_SetCRT2ModeRegs(struct SiS_Private *SiS_Pr, unsigned 
short ModeNo, unsigned
if(SiS_Pr-SiS_IF_DEF_LVDS == 1) {
   SiS_SetRegANDOR(SiS_Pr

[PATCH sis 06/15] Declare mmioFlags only if XSERVER_LIBPCIACCESS isn't defined

2011-04-06 Thread Timo Aaltonen
Signed-off-by: Timo Aaltonen timo.aalto...@canonical.com
---
 src/sis_driver.c |2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/src/sis_driver.c b/src/sis_driver.c
index 337bba6..61fd515 100644
--- a/src/sis_driver.c
+++ b/src/sis_driver.c
@@ -7103,7 +7103,9 @@ static Bool
 SISMapMem(ScrnInfoPtr pScrn)
 {
 SISPtr pSiS = SISPTR(pScrn);
+#ifndef XSERVER_LIBPCIACCESS
 int mmioFlags = VIDMEM_MMIO;
+#endif
 #ifdef SISDUALHEAD
 SISEntPtr pSiSEnt = pSiS-entityPrivate;
 #endif
-- 
1.7.4.1

___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel


[PATCH sis 05/15] Fix compile warnings of uninitialized variables

2011-04-06 Thread Timo Aaltonen
Signed-off-by: Timo Aaltonen timo.aalto...@canonical.com
---
 src/sis_utility.c |4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/src/sis_utility.c b/src/sis_utility.c
index 0892cf5..0e9dc5b 100644
--- a/src/sis_utility.c
+++ b/src/sis_utility.c
@@ -1550,7 +1550,9 @@ SiSHandleSiSDirectCommand(xSiSCtrlCommandReply *sdcbuf)
 #ifdef SISMERGED
   if(pSiS-MergedFB) {
  int clk, hd, hss, hse, ht, vd, vss, vse, vt;
-unsigned int pos, crt1x, crt1y, crt1clk, crt2x, crt2y, crt2clk;
+unsigned int pos;
+unsigned int crt1x = 0, crt1y = 0, crt1clk = 0;
+unsigned int crt2x = 0, crt2y = 0, crt2clk = 0;
 
 clk   = sdcbuf-sdc_parm[0];
 hd= sdcbuf-sdc_parm[1];
-- 
1.7.4.1

___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel


[PATCH sis 09/15] Drop unused and non-working XAA trapezoid support for 310 series and later

2011-04-06 Thread Timo Aaltonen
Signed-off-by: Timo Aaltonen timo.aalto...@canonical.com
---
 src/sis310_accel.c |  176 
 1 files changed, 0 insertions(+), 176 deletions(-)

diff --git a/src/sis310_accel.c b/src/sis310_accel.c
index befb095..26c4c00 100644
--- a/src/sis310_accel.c
+++ b/src/sis310_accel.c
@@ -56,18 +56,6 @@
 
 #ifdef SIS_USE_XAA
 
-#undef TRAP/* Use/Don't use Trapezoid Fills
-* DOES NOT WORK. XAA sometimes provides illegal
-* trapezoid data (left and right edges cross each
-* other) which causes drawing errors. Since
-* checking the trapezoid for such a case is very
-* time-intensive, it is faster to let it be done
-* by the generic polygon functions.
-* Does not work on 330 series at all, hangs the engine.
-* Even with correct trapezoids, this is slower than
-* doing it by the CPU.
- */
-
 #undef CTSCE   /* Use/Don't use CPUToScreenColorExpand. Disabled
 * because it is slower than doing it by the CPU.
 * Indirect mode does not work in VRAM queue mode.
@@ -424,85 +412,6 @@ SiSSubsequentSolidFillRect(ScrnInfoPtr pScrn,
 
 #ifdef SIS_USE_XAA  /*  XAA 
-- */
 
-/* Trapezoid */
-/* This would work better if XAA would provide us with valid trapezoids.
- * In fact, with small trapezoids the left and the right edge often cross
- * each other which causes drawing errors (filling over whole scanline).
- * DOES NOT WORK ON 330 SERIES, HANGS THE ENGINE.
- */
-#ifdef TRAP
-static void
-SiSSubsequentSolidFillTrap(ScrnInfoPtr pScrn, int y, int h,
-   int left,  int dxL, int dyL, int eL,
-   int right, int dxR, int dyR, int eR )
-{
-   SISPtr pSiS = SISPTR(pScrn);
-   CARD32 dstbase = 0;
-
-   if(y = 2048) {
-  dstbase = pSiS-scrnOffset * y;
-  y = 0;
-   }
-
-   dstbase += FBOFFSET;
-
-#ifdef SISVRAMQ/* Not optimized yet */
-   SiSCheckQueue(16 * 10)
-#else
-   SiSSetupDSTBase(dstbase)
-#endif
-
-#if 1
-   SiSSetupPATFG(0xff) /* FOR TESTING */
-#endif
-
-   /* Clear CommandReg because SetUp can be used for Rect and Trap */
-   pSiS-CommandReg = ~(T_L_X_INC | T_L_Y_INC |
- T_R_X_INC | T_R_Y_INC |
- T_XISMAJORL | T_XISMAJORR |
- BITBLT);
-
-xf86DrvMsg(0, X_INFO, Trap (%d %d %d %d) dxL %d dyL %d eL %d   dxR %d 
dyR %d eR %d\n,
-   left, right, y, h, dxL, dyL, eL, dxR, dyR, eR);
-
-   /* Determine egde angles */
-   if(dxL  0) { dxL = -dxL; }
-   else{ SiSSetupCMDFlag(T_L_X_INC) }
-   if(dxR  0) { dxR = -dxR; }
-   else{ SiSSetupCMDFlag(T_R_X_INC) }
-
-   /* (Y direction always positive - do this anyway) */
-   if(dyL  0) { dyL = -dyL; }
-   else{ SiSSetupCMDFlag(T_L_Y_INC) }
-   if(dyR  0) { dyR = -dyR; }
-   else{ SiSSetupCMDFlag(T_R_Y_INC) }
-
-   /* Determine major axis */
-   if(dxL = dyL) {  SiSSetupCMDFlag(T_XISMAJORL) }
-   if(dxR = dyR) {  SiSSetupCMDFlag(T_XISMAJORR) }
-
-   SiSSetupCMDFlag(TRAPAZOID_FILL);
-
-#ifdef SISVRAMQ
-   SiSSetupYHLR(y, h, left, right)
-   SiSSetupdLdR(dxL, dyL, dxR, dyR)
-   SiSSetupELER(eL, eR)
-   SiSSetupDSTBaseDoCMD(dstbase)
-#else
-   /* Set up deltas */
-   SiSSetupdL(dxL, dyL)
-   SiSSetupdR(dxR, dyR)
-   /* Set up y, h, left, right */
-   SiSSetupYH(y, h)
-   SiSSetupLR(left, right)
-   /* Set up initial error term */
-   SiSSetupEL(eL)
-   SiSSetupER(eR)
-   SiSDoCMD
-#endif
-}
-#endif
-
 static void
 SiSSetupForSolidLine(ScrnInfoPtr pScrn, int color, int rop,
unsigned int planemask)
@@ -748,73 +657,6 @@ SiSSubsequentMonoPatternFill(ScrnInfoPtr pScrn,
 #endif
 }
 
-/* --- Trapezoid --- */
-
-/* Does not work at all on 330 series */
-
-#ifdef TRAP
-static void
-SiSSubsequentMonoPatternFillTrap(ScrnInfoPtr pScrn,
-   int patx, int paty,
-   int y, int h,
-   int left, int dxL, int dyL, int eL,
-   int right, int dxR, int dyR, int eR)
-{
-   SISPtr pSiS = SISPTR(pScrn);
-   CARD32 dstbase = 0;
-
-   if(y = 2048) {
-  dstbase=pSiS-scrnOffset*y;
-  y = 0;
-   }
-
-   dstbase += FBOFFSET;
-
-#ifdef SISVRAMQ
-   SiSCheckQueue(16 * 4);
-#else
-   SiSSetupDSTBase(dstbase)
-#endif
-
-   /* Clear CommandReg because SetUp can be used for Rect and Trap */
-   pSiS-CommandReg = ~(T_XISMAJORL | T_XISMAJORR |
- T_L_X_INC | T_L_Y_INC

[PATCH sis 07/15] Purge obsolete and unused SIS_CP checks

2011-04-06 Thread Timo Aaltonen
Signed-off-by: Timo Aaltonen timo.aalto...@canonical.com
---
 src/init.h   |3 ---
 src/init301.c|   14 --
 src/init301.h|3 ---
 src/sis.h|   11 ---
 src/sis_driver.c |   12 
 src/sis_opt.c|   16 
 src/sis_video.c  |   23 ---
 src/sis_video.h  |6 --
 8 files changed, 0 insertions(+), 88 deletions(-)

diff --git a/src/init.h b/src/init.h
index bc90933..d0ac959 100644
--- a/src/init.h
+++ b/src/init.h
@@ -68,9 +68,6 @@
 #ifdef SIS_LINUX_KERNEL
 #include vgatypes.h
 #include vstruct.h
-#ifdef SIS_CP
-#undef SIS_CP
-#endif
 #include linux/config.h
 #include linux/version.h
 #include linux/types.h
diff --git a/src/init301.c b/src/init301.c
index 603ecb6..74bbc4c 100644
--- a/src/init301.c
+++ b/src/init301.c
@@ -7354,11 +7354,7 @@ SiS_SetGroup3(struct SiS_Private *SiS_Pr, unsigned short 
ModeNo, unsigned short
 
   if(SiS_Pr-SiS_VBInfo  SetCRT2ToLCDA) return;
 
-#ifndef SIS_CP
   SiS_SetReg(SiS_Pr-SiS_Part3Port,0x00,0x00);
-#else
-  SIS_CP_INIT301_CP
-#endif
 
   if(SiS_Pr-SiS_TVMode  TVSetPALTiming) {
  SiS_SetReg(SiS_Pr-SiS_Part3Port,0x13,0xFA);
@@ -7398,10 +7394,6 @@ SiS_SetGroup3(struct SiS_Private *SiS_Pr, unsigned short 
ModeNo, unsigned short
}
  }
   }
-
-#ifdef SIS_CP
-  SIS_CP_INIT301_CP2
-#endif
 }
 
 /*/
@@ -8081,9 +8073,7 @@ SiS_SetCHTVReg(struct SiS_Private *SiS_Pr, unsigned short 
ModeNo, unsigned short
   /* Register 0x3D does not exist in non-macrovision register map
 (Maybe this is a macrovision register?)
*/
-#ifndef SIS_CP
   SiS_SetCH70xx(SiS_Pr,0x3d,0x00);
-#endif
 
   /* Register 0x10 only contains 1 writable bit (S0) for sensing,
  all other bits a read-only. Macrovision?
@@ -8199,10 +8189,6 @@ SiS_SetCHTVReg(struct SiS_Private *SiS_Pr, unsigned 
short ModeNo, unsigned short
 
}
 
-#ifdef SIS_CP
-   SIS_CP_INIT301_CP3
-#endif
-
 }
 
 #ifdef SIS315H  /* --- 315 series only -- */
diff --git a/src/init301.h b/src/init301.h
index 7dca546..d656bad 100644
--- a/src/init301.h
+++ b/src/init301.h
@@ -62,9 +62,6 @@
 #ifdef SIS_LINUX_KERNEL
 #include vgatypes.h
 #include vstruct.h
-#ifdef SIS_CP
-#undef SIS_CP
-#endif
 #include linux/config.h
 #include linux/version.h
 #include linux/types.h
diff --git a/src/sis.h b/src/sis.h
index 2144052..7cf81af 100644
--- a/src/sis.h
+++ b/src/sis.h
@@ -68,11 +68,6 @@
 #define TWDEBUG/* for debugging */
 #endif
 
-#undef SIS_CP
-#if 0
-#include siscp.H
-#endif
-
 #include compiler.h
 #include xf86Pci.h
 #include xf86Priv.h
@@ -929,9 +924,6 @@ typedef struct {
 UShort MapCountIOPBase;/* map/unmap queue counter */
 Bool   forceUnmapIOPBase;  /* ignore counter and unmap */
 #endif
-#ifdef SIS_CP
-SIS_CP_H_ENT
-#endif
 } SISEntRec, *SISEntPtr;
 #endif
 
@@ -1294,9 +1286,6 @@ typedef struct {
 intSiS76xUMASize;
 intCRT1isoff;
 ULong  UMAsize, LFBsize;   /* For SiSCtrl extension info 
only */
-#ifdef SIS_CP
-SIS_CP_H
-#endif
 ULong  ChipFlags;
 ULong  SiS_SD_Flags, SiS_SD2_Flags, SiS_SD3_Flags, 
SiS_SD4_Flags;
 Bool   UseHWARGBCursor;
diff --git a/src/sis_driver.c b/src/sis_driver.c
index 61fd515..863ad24 100644
--- a/src/sis_driver.c
+++ b/src/sis_driver.c
@@ -4280,9 +4280,6 @@ SISPreInit(ScrnInfoPtr pScrn, int flags)
  pSiSEnt-SenseYPbPr = pSiS-SenseYPbPr;
  pSiSEnt-XvUseMemcpy = pSiS-XvUseMemcpy;
  pSiSEnt-BenchMemCpy = pSiS-BenchMemCpy;
-#ifdef SIS_CP
- SIS_CP_DRIVER_COPYOPTIONSENT
-#endif
} else {
  /* We always use same cursor type on both screens */
  pSiS-HWCursor = pSiSEnt-HWCursor;
@@ -4364,9 +4361,6 @@ SISPreInit(ScrnInfoPtr pScrn, int flags)
  pSiSEnt-NewGammaConR = pSiS-NewGammaConR;
  pSiSEnt-NewGammaConG = pSiS-NewGammaConG;
  pSiSEnt-NewGammaConB = pSiS-NewGammaConB;
-#ifdef SIS_CP
- SIS_CP_DRIVER_COPYOPTIONS
-#endif
}
 }
 #endif
@@ -5514,9 +5508,6 @@ SISPreInit(ScrnInfoPtr pScrn, int flags)
}
 }
 
-#ifdef SIS_CP
-SIS_CP_DRIVER_RECONFIGOPT
-#endif
 
 if((pSiS-Chipset == PCI_CHIP_SIS6326)  (pSiS-SiS6326Flags  
SIS6326_HASTV)) {
if(pSiS-sis6326tvplug != -1) {
@@ -10478,9 +10469,6 @@ void SiSPreSetMode(ScrnInfoPtr pScrn, DisplayModePtr 
mode, int viewmode)
  } else {
 pSiS-SiS_Pr-SiS_CHSOverScan = FALSE;
  }
-#ifdef SIS_CP
- SIS_CP_DRIVER_CONFIG
-#endif
  break;
 
case CRT2_LCD:
diff --git a/src/sis_opt.c b/src/sis_opt.c
index d39ff6e..933049e 100644
--- a/src/sis_opt.c
+++ b/src/sis_opt.c
@@ -152,9 +152,6 @@ typedef enum {
 OPTION_FORCE1ASPECT,
 OPTION_FORCE2ASPECT,
 OPTION_TVBLUE,
-#ifdef SIS_CP
-SIS_CP_OPT_OPTIONS
-#endif
 OPTION_PSEUDO
 } SISOpts

[PATCH sis 08/15] Drop useless checks and relevant code for old XFree86 releases

2011-04-06 Thread Timo Aaltonen
Signed-off-by: Timo Aaltonen timo.aalto...@canonical.com
---
 src/sis.h   |   11 
 src/sis310_accel.c  |   42 ---
 src/sis6326_video.c |   54 
 src/sis_cursor.c|6 
 src/sis_dri.c   |   14 --
 src/sis_driver.c|   35 --
 src/sis_opt.c   |   21 ---
 src/sis_vga.c   |5 ---
 src/sis_video.c |   68 ---
 src/vgatypes.h  |5 ---
 10 files changed, 0 insertions(+), 261 deletions(-)

diff --git a/src/sis.h b/src/sis.h
index 7cf81af..3314471 100644
--- a/src/sis.h
+++ b/src/sis.h
@@ -87,11 +87,6 @@
 #ifdef XORG_VERSION_CURRENT
 #include xorgVersion.h
 #define SISMYSERVERNAME X.org
-#ifndef XF86_VERSION_NUMERIC
-#define XF86_VERSION_NUMERIC(major,minor,patch,snap,dummy) \
-   (((major) * 1000) + ((minor) * 10) + ((patch) * 1000) + snap)
-#define XF86_VERSION_CURRENT XF86_VERSION_NUMERIC(4,3,99,902,0)
-#endif
 #if XORG_VERSION_CURRENT = XORG_VERSION_NUMERIC(6,8,99,900,0) || 
XORG_VERSION_CURRENT  XORG_VERSION_NUMERIC(4,0,0,0,0)
 #define SISISXORG6899900
 #endif
@@ -120,10 +115,8 @@
 #define SIS_CURRENT_VERSION ((SIS_MAJOR_VERSION  16) | \
  (SIS_MINOR_VERSION  8) | SIS_PATCH sisLEVEL 
)
 
-#if (XF86_VERSION_CURRENT = XF86_VERSION_NUMERIC(4,3,99,0,0)) || 
(defined(XvExtension))
 #include xf86xv.h
 #include X11/extensions/Xv.h
-#endif
 
 /* Platform/architecture related definitions: */
 
@@ -169,12 +162,8 @@
 #undef SISHAVEDRMWRITE
 #undef SISNEWDRI
 #ifdef XF86DRI
-#if XF86_VERSION_CURRENT = XF86_VERSION_NUMERIC(4,2,99,3,0)
 #define SISHAVEDRMWRITE
-#endif
-#if XF86_VERSION_CURRENT = XF86_VERSION_NUMERIC(4,3,99,14,0)
 #define SISNEWDRI
-#endif
 #undef SIS315DRI   /* define this if dri is adapted for 315/330 
series */
 #include xf86drm.h
 #include sarea.h
diff --git a/src/sis310_accel.c b/src/sis310_accel.c
index 8bba823..befb095 100644
--- a/src/sis310_accel.c
+++ b/src/sis310_accel.c
@@ -144,11 +144,7 @@ extern unsigned char SiSGetPatternROP(int rop);
 CARD32 dummybuf;
 
 #ifdef SIS_NEED_ARRAY
-#if XF86_VERSION_CURRENT = XF86_VERSION_NUMERIC(4,2,0,0,0)
 #define SiSRenderOpsMAX 0x2b
-#else
-#define SiSRenderOpsMAX 0x0f
-#endif
 static const CARD8 SiSRenderOps[] = {  /* PictOpXXX 1 = supported, 0 = 
unsupported */
  1, 1, 1, 1,
  0, 0, 0, 0,
@@ -319,32 +315,6 @@ SiSSubsequentScreenToScreenCopy(ScrnInfoPtr pScrn,
mymin = min(src_y, dst_y);
mymax = max(src_y, dst_y);
 
-   /* Libxaa.a has a bug: The tilecache cannot operate
-* correctly if there are 512x512 slots, but no 256x256
-* slots. This leads to catastrophic data fed to us.
-* Filter this out here and warn the user.
-* Fixed in 4.3.99.10 (?) and Debian's 4.3.0.1
-*/
-#if (XF86_VERSION_CURRENT  XF86_VERSION_NUMERIC(4,3,99,10,0))  
(XF86_VERSION_CURRENT != XF86_VERSION_NUMERIC(4,3,0,1,0))
-   if((src_x  0)  ||
-  (dst_x  0)  ||
-  (src_y  0)  ||
-  (dst_y  0)  ||
-  (width = 0) ||
-  (height = 0)) {
-  xf86DrvMsg(pScrn-scrnIndex, X_ERROR,
-   BitBlit fatal error: Illegal coordinates:\n);
-  xf86DrvMsg(pScrn-scrnIndex, X_ERROR,
-   Source x %d y %d, dest x %d y %d, width %d height %d\n,
- src_x, src_y, dst_x, dst_y, width, height);
-  xf86DrvMsg(pScrn-scrnIndex, X_ERROR,
-   This is very probably caused by a known bug in libxaa.a.\n);
-  xf86DrvMsg(pScrn-scrnIndex, X_ERROR,
-   Please update libxaa.a to avoid this error.\n);
-  return;
-   }
-#endif
-
/* Although the chip knows the direction to use
 * if the source and destination areas overlap,
 * that logic fails if we fiddle with the bitmap
@@ -1435,29 +1405,23 @@ SiSSetupForCPUToScreenAlphaTexture(ScrnInfoPtr pScrn,
SiSSetupDSTColorDepth(pSiS-SiS310_AccelDepth);
switch(op) {
case PictOpClear:
-#if XF86_VERSION_CURRENT = XF86_VERSION_NUMERIC(4,2,0,0,0)
case PictOpDisjointClear:
case PictOpConjointClear:
-#endif
   SiSSetupPATFGDSTRect(0, pSiS-scrnOffset, DEV_HEIGHT)
   /* SiSSetupROP(0x00) - is already 0 */
   SiSSetupCMDFlag(PATFG)
   docopy = FALSE;
   break;
case PictOpSrc:
-#if XF86_VERSION_CURRENT = XF86_VERSION_NUMERIC(4,2,0,0,0)
case PictOpDisjointSrc:
case PictOpConjointSrc:
-#endif
   SiSSetupSRCPitchDSTRect((pitch  2), pSiS-scrnOffset, DEV_HEIGHT);
   SiSSetupAlpha(0xff)
   SiSSetupCMDFlag(ALPHA_BLEND | SRCVIDEO | A_NODESTALPHA)
   break;
case PictOpDst:
-#if XF86_VERSION_CURRENT = XF86_VERSION_NUMERIC(4,2,0,0,0)
case PictOpDisjointDst:
case PictOpConjointDst:
-#endif
   SiSSetupSRCPitchDSTRect((pitch  2), pSiS

[PATCH sis 10/15] Remove unused code from sis_video.c

2011-04-06 Thread Timo Aaltonen
Signed-off-by: Timo Aaltonen timo.aalto...@canonical.com
---
 src/sis310_accel.c |  536 
 src/sis_accel.c|  128 -
 2 files changed, 0 insertions(+), 664 deletions(-)

diff --git a/src/sis310_accel.c b/src/sis310_accel.c
index 26c4c00..6f93e78 100644
--- a/src/sis310_accel.c
+++ b/src/sis310_accel.c
@@ -56,21 +56,6 @@
 
 #ifdef SIS_USE_XAA
 
-#undef CTSCE   /* Use/Don't use CPUToScreenColorExpand. Disabled
-* because it is slower than doing it by the CPU.
-* Indirect mode does not work in VRAM queue mode.
-* Does not work on 330 series (even in MMIO mode).
-*/
-#undef CTSCE_DIRECT/* Use direct method - This works (on both 315 and 330 
at
-* least in VRAM queue mode) but we don't use this 
either,
-* because it's slower than doing it by the CPU. (Using 
it
-* would require defining CTSCE)
-*/
-
-#undef STSCE   /* Use/Don't use ScreenToScreenColorExpand - does not 
work,
-* see comments below.
-*/
-
 #define INCL_RENDER/* Use/Don't use RENDER extension acceleration */
 
 #ifdef INCL_RENDER
@@ -196,14 +181,6 @@ SiSSync(ScrnInfoPtr pScrn)
 
 #ifdef SIS_USE_XAA
if(!pSiS-useEXA) {
-#ifdef CTSCE
-#ifdef CTSCE_DIRECT
-  if(pSiS-DoColorExpand) {
- SiSDoCMD
- pSiS-ColorExpandBusy = TRUE;
-  }
-#endif
-#endif
   pSiS-DoColorExpand = FALSE;
}
 #endif
@@ -711,420 +688,6 @@ SiSSubsequentColor8x8PatternFillRect(ScrnInfoPtr pScrn, 
int patternx,
 }
 #endif
 
-/*  CPUToScreen Color Expand --- */
-
-#ifdef CTSCE
-
-#ifdef CTSCE_DIRECT
-
-/* Direct method */
-
-/* This is somewhat a fake. We let XAA copy its data not to an
- * aperture, but to video RAM, and then do a ScreenToScreen
- * color expansion.
- * Since the data is sent AFTER the call to Subsequent, we
- * don't execute the command here, but set a flag and do
- * that in the (subsequent) call to Sync()
- */
-
-static void
-SiSSetupForCPUToScreenColorExpandFill(ScrnInfoPtr pScrn,
-   int fg, int bg, int rop, unsigned int planemask)
-{
-   SISPtr pSiS=SISPTR(pScrn);
-
-#ifdef SISVRAMQ
-   SiSSetupDSTColorDepth(pSiS-SiS310_AccelDepth);
-   SiSSetupROP(SiSGetCopyROP(rop));
-   SiSSetupSRCFGDSTRect(fg, pSiS-scrnOffset, DEV_HEIGHT)
-   if(bg == -1) {
-  SiSSetupCMDFlag(TRANSPARENT | ENCOLOREXP | SRCVIDEO);
-   } else {
-  SiSSetupSRCBG(bg);
-  SiSSetupCMDFlag(ENCOLOREXP | SRCVIDEO);
-   }
-   SiSSyncWP
-#else
-   SiSSetupSRCXY(0,0);
-   SiSSetupROP(SiSGetCopyROP(rop));
-   SiSSetupSRCFG(fg);
-   SiSSetupDSTRect(pSiS-scrnOffset, DEV_HEIGHT);
-   SiSSetupDSTColorDepth(pSiS-DstColor);
-   if(bg == -1) {
-  SiSSetupCMDFlag(TRANSPARENT | ENCOLOREXP | SRCVIDEO
-  | pSiS-SiS310_AccelDepth);
-   } else {
-  SiSSetupSRCBG(bg);
-  SiSSetupCMDFlag(ENCOLOREXP | SRCVIDEO | pSiS-SiS310_AccelDepth);
-   }
-#endif
-}
-
-static void
-SiSSubsequentCPUToScreenColorExpandFill(
-   ScrnInfoPtr pScrn, int x, int y, int w,
-   int h, int skipleft)
-{
-   SISPtr pSiS = SISPTR(pScrn);
-   int _x0, _y0, _x1, _y1;
-   CARD32 srcbase, dstbase;
-
-   srcbase = pSiS-ColorExpandBase;
-
-   dstbase = 0;
-   if(y = 2048) {
-  dstbase = pSiS-scrnOffset*y;
-  y = 0;
-   }
-
-   srcbase += FBOFFSET;
-   dstbase += FBOFFSET;
-
-#ifdef SISVRAMQ
-   SiSSetupSRCDSTBase(srcbase,dstbase);
-#else
-   SiSSetupSRCBase(srcbase);
-   SiSSetupDSTBase(dstbase)
-#endif
-
-   if(skipleft  0) {
-  _x0 = x + skipleft;
-  _y0 = y;
-  _x1 = x + w;
-  _y1 = y + h;
-#ifdef SISVRAMQ
-  SiSSetupClip(_x0, _y0, _x1, _y1);
-#else
-  SiSSetupClipLT(_x0, _y0);
-  SiSSetupClipRB(_x1, _y1);
-#endif
-  SiSSetupCMDFlag(CLIPENABLE);
-   } else {
-  pSiS-CommandReg = (~CLIPENABLE);
-   }
-
-#ifdef SISVRAMQ
-   SiSSetupRectSRCPitch(w, h, w + 7)  3) + 3)  2)  2);
-   SiSSetupSRCDSTXY(0, 0, x, y);
-#else
-   SiSSetupRect(w, h);
-   SiSSetupSRCPitch(w+7)/8)+3)  2) * 4);
-   SiSSetupDSTXY(x, y);
-#endif
-
-   if(pSiS-ColorExpandBusy) {
-  pSiS-ColorExpandBusy = FALSE;
-  SiSIdle
-   }
-
-   pSiS-DoColorExpand = TRUE;
-}
-
-#else
-
-/* Indirect method */
-
-/* This is SLOW, slower than the CPU on most chipsets */
-/* Does not work in VRAM queue mode. */
-
-static void
-SiSSetupForScanlineCPUToScreenColorExpandFill(ScrnInfoPtr pScrn,
-   int fg, int bg, int rop, unsigned int planemask)
-{
-   SISPtr pSiS=SISPTR(pScrn

[PATCH sis 14/15] Move configurable values from sis.h to sis_config.h

2011-04-06 Thread Timo Aaltonen
Signed-off-by: Timo Aaltonen timo.aalto...@canonical.com
---
 src/sis.h|   40 +-
 src/sis_config.h |   71 ++
 2 files changed, 72 insertions(+), 39 deletions(-)
 create mode 100644 src/sis_config.h

diff --git a/src/sis.h b/src/sis.h
index 9ef30b8..b8dba90 100644
--- a/src/sis.h
+++ b/src/sis.h
@@ -173,45 +173,7 @@
 #include sis_dri.h
 #endif /* XF86DRI */
 
-/* Configurable stuff: - */
-
-#define SISDUALHEAD/* Include Dual Head code  */
-
-#define SISMERGED  /* Include Merged-FB code */
-
-#undef SISXINERAMA
-#ifdef SISMERGED
-#define SISXINERAMA/* Include SiS Pseudo-Xinerama for MergedFB 
mode */
-#define SIS_XINERAMA_MAJOR_VERSION  1
-#define SIS_XINERAMA_MINOR_VERSION  1
-#endif
-
-#define SIS_ARGB_CURSOR/* Include code for color hardware 
cursors */
-
-#define ENABLE_YPBPR   /* Include YPbPr support on SiS bridges (315 
series and 661/741/760) */
-
-#define SISVRAMQ   /* Use VRAM queue mode on 315/330/340/XGI 
series */
-
-#undef INCL_YUV_BLIT_ADAPTOR
-#ifdef SISVRAMQ
-#define INCL_YUV_BLIT_ADAPTOR  /* Include support for YUV-RGB blit adaptors 
(VRAM queue mode only) */
-#endif
-
-#if 1
-#define SIS_USE_XAA/* Include code for XAA */
-#endif
-
-#ifdef SISVRAMQ
-#ifdef XORG_VERSION_CURRENT
-#if defined(SIS_HAVE_EXA) || (defined(XF86EXA)  (XF86EXA != 0))
-#if 1
-#define SIS_USE_EXA/* Include code for EXA */
-#endif
-#endif
-#endif
-#endif
-
-/* End of configurable stuff - */
+#include sis_config.h
 
 #define UNLOCK_ALWAYS  /* Always unlock the registers (should be set!) 
*/
 
diff --git a/src/sis_config.h b/src/sis_config.h
new file mode 100644
index 000..b8b625c
--- /dev/null
+++ b/src/sis_config.h
@@ -0,0 +1,71 @@
+/*
+ * Configurable compile-time options
+ *
+ * Copyright (C) 2001-2005 by Thomas Winischhofer, Vienna, Austria
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1) Redistributions of source code must retain the above copyright
+ *notice, this list of conditions and the following disclaimer.
+ * 2) Redistributions in binary form must reproduce the above copyright
+ *notice, this list of conditions and the following disclaimer in the
+ *documentation and/or other materials provided with the distribution.
+ * 3) The name of the author may not be used to endorse or promote products
+ *derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+ * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+ * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+ * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ *
+ * Author:   Thomas Winischhofer tho...@winischhofer.net
+ *
+ */
+
+#undef SISXINERAMA
+#undef INCL_YUV_BLIT_ADAPTOR
+
+/* Configurable stuff: - */
+
+#define SISDUALHEAD/* Include Dual Head support  */
+
+#define SISMERGED  /* Include Merged-FB support */
+
+#ifdef SISMERGED
+#define SISXINERAMA/* Include SiS Pseudo-Xinerama support for 
MergedFB mode */
+#define SIS_XINERAMA_MAJOR_VERSION  1
+#define SIS_XINERAMA_MINOR_VERSION  1
+#endif
+
+#define SIS_ARGB_CURSOR/* Include support for color hardware 
cursors */
+
+#define ENABLE_YPBPR   /* Include YPbPr support on SiS bridges (315 
series and 661/741/760) */
+
+#define SISVRAMQ   /* Use VRAM queue mode on 315/330/340/XGI 
series */
+
+#ifdef SISVRAMQ
+#define INCL_YUV_BLIT_ADAPTOR  /* Include support for YUV-RGB blit adaptors 
(VRAM queue mode only) */
+#endif
+
+#if 1
+#define SIS_USE_XAA/* Include support for XAA */
+#endif
+
+#ifdef SISVRAMQ
+#ifdef XORG_VERSION_CURRENT
+#if defined(SIS_HAVE_EXA) || (defined(XF86EXA)  (XF86EXA != 0))
+#if 1
+#define SIS_USE_EXA/* Include support for EXA */
+#endif
+#endif
+#endif
+#endif
+
+/* End of configurable stuff - */
-- 
1.7.4.1

___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel


[PATCH sis 11/15] Remove unused code from SISPutImageBlit()

2011-04-06 Thread Timo Aaltonen
Signed-off-by: Timo Aaltonen timo.aalto...@canonical.com
---
 src/sis_video.c |   66 ---
 1 files changed, 0 insertions(+), 66 deletions(-)

diff --git a/src/sis_video.c b/src/sis_video.c
index 9859f33..17d8f71 100644
--- a/src/sis_video.c
+++ b/src/sis_video.c
@@ -4269,34 +4269,6 @@ SISPutImageBlit(
   DSTVIDEO;
 
 
-#if 0 /* Not implemented by hardware! */
-   if(pPriv-vsync) {
-#ifdef SISMERGED
-  if(!pSiS-MergedFB) {
-#endif
-#ifdef SISDUALHEAD
- if(pSiS-DualHeadMode) {
-   if(pSiS-SecondHead) {
-  MyPacket.P12_Command |= pPriv-VBlankTriggerCRT1;
-   } else {
-  MyPacket.P12_Command |= pPriv-VBlankTriggerCRT2;
-   }
-} else {
-#endif
-Bool IsSlaveMode = SiSBridgeIsInSlaveMode(pScrn);
-if((pSiS-VBFlags  DISPTYPE_DISP2)  !IsSlaveMode)
-  MyPacket.P12_Command |= pPriv-VBlankTriggerCRT2;
-   else if((pSiS-VBFlags  DISPTYPE_DISP1) || IsSlaveMode)
-  MyPacket.P12_Command |= pPriv-VBlankTriggerCRT1;
-#ifdef SISDUALHEAD
- }
-#endif
-#ifdef SISMERGED
-  }
-#endif
-   }
-#endif
-
first = TRUE;
while(nbox--) {
   left = pbox-x1;
@@ -4321,23 +4293,6 @@ SISPutImageBlit(
   MyPacket.P12_RectWidth = right - left;
   MyPacket.P12_RectHeight = bottom - top;
 
-#if 0
-#ifdef SISMERGED
-  if((first)  (pSiS-MergedFB)) {
- int scrwidth = 
((SiSMergedDisplayModePtr)pSiS-CurrentLayout.mode-Private)-CRT2-HDisplay;
-int scrheight = 
((SiSMergedDisplayModePtr)pSiS-CurrentLayout.mode-Private)-CRT2-VDisplay;
-if( (right  pSiS-CRT2pScrn-frameX0) ||
-(left = pSiS-CRT2pScrn-frameX0 + scrwidth) ||
-(bottom  pSiS-CRT2pScrn-frameY0) ||
-(top = pSiS-CRT2pScrn-frameY0 + scrheight) ) {
-   MyPacket.P12_Command |= pPriv-VBlankTriggerCRT1;
-} else {
-   MyPacket.P12_Command |= pPriv-VBlankTriggerCRT2;
-}
-  }
-#endif
-#endif
-
   offsety = offsetuv = 0;
   if(packed) {
  if(pbox-y1  drw_y + yoffset) {
@@ -4346,19 +4301,9 @@ SISPutImageBlit(
  if(pbox-x1  drw_x + xoffset) {
 offsetuv += ((pbox-x1 - drw_x - xoffset)  1);
if(offsetuv  3) {
-#if 0 /* Paint over covering object - no */
-  if(MyPacket.P12_DstX  0) {
- offsetuv = ~3;
- MyPacket.P12_DstX--;
- MyPacket.P12_RectWidth++;
-  } else {
-#endif
  offsetuv = (offsetuv + 3)  ~3;
  MyPacket.P12_DstX++;
  MyPacket.P12_RectWidth--;
-#if 0
-  }
-#endif
}
  }
   } else {
@@ -4383,22 +4328,11 @@ SISPutImageBlit(
   MyPacket.P12_YSrcAddr  = pPriv-bufAddr[index][pPriv-currentBuf[index]] 
+ offsety + FBOFFSET;
   MyPacket.P12_UVSrcAddr = pPriv-bufAddr[index][pPriv-currentBuf[index]] 
+ bytesize + offsetuv + FBOFFSET;
   SISWriteBlitPacket(pSiS, (CARD32*)MyPacket);
-#if 0
-  MyPacket.P12_Command = ~(pPriv-VBlankTriggerCRT1 | 
pPriv-VBlankTriggerCRT2);
-#endif
   first = FALSE;
 mycont:
   pbox++;
}
 
-#if 0
-   {
-   int debug = 0;
-   while( (SIS_MMIO_IN16(pSiS-IOBase, Q_STATUS+2)  0x8000) != 0x8000) { 
debug++; };
-   while( (SIS_MMIO_IN16(pSiS-IOBase, Q_STATUS+2)  0x8000) != 0x8000) { 
debug++; };
-   xf86DrvMsg(0, X_INFO, vsync %d, debug %d\n, pPriv-vsync, debug);
-   }
-#endif
 
pPriv-currentBuf[index] ^= 1;
 
-- 
1.7.4.1

___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel


[PATCH sis 12/15] Remove unused non-working Xv deinterlacer code

2011-04-06 Thread Timo Aaltonen
Signed-off-by: Timo Aaltonen timo.aalto...@canonical.com
---
 src/sis.h  |7 --
 src/sis_video.c|   55 
 src/sis_video.h|9 
 src/sis_videostr.h |3 --
 4 files changed, 0 insertions(+), 74 deletions(-)

diff --git a/src/sis.h b/src/sis.h
index 3314471..f40563e 100644
--- a/src/sis.h
+++ b/src/sis.h
@@ -212,10 +212,6 @@
 #endif
 
 #if 0
-#define SISDEINT   /* Include Xv deinterlacer code (not functional 
yet!) */
-#endif
-
-#if 0
 #define XV_SD_DEPRECATED   /* Include deprecated XV SD interface for 
SiSCtrl */
 #endif
 
@@ -1253,9 +1249,6 @@ typedef struct {
 Atom   xvDisableGfx, xvDisableGfxLR, xvTVXPosition, 
xvTVYPosition;
 Atom   xvDisableColorkey, xvUseChromakey, xvChromaMin, 
xvChromaMax;
 Atom   xvInsideChromakey, xvYUVChromakey, xvVSync;
-#ifdef SISDEINT
-Atom   xvdeintmeth;
-#endif
 Atom   xvGammaRed, xvGammaGreen, xvGammaBlue;
 #ifdef XV_SD_DEPRECATED
 Atom   xv_QVF, xv_QVV, xv_USD, xv_SVF, xv_QDD, xv_TAF, xv_TSA, 
xv_TEE, xv_GSF;
diff --git a/src/sis_video.c b/src/sis_video.c
index 17d8f71..f134aad 100644
--- a/src/sis_video.c
+++ b/src/sis_video.c
@@ -968,9 +968,6 @@ SISSetupImageVideo(ScreenPtr pScreen)
 pSiS-xvYUVChromakey  = MAKE_ATOM(sisxvyuvchromakey);
 pSiS-xvChromaMin= MAKE_ATOM(sisxvchromamin);
 pSiS-xvChromaMax = MAKE_ATOM(sisxvchromamax);
-#ifdef SISDEINT
-pSiS-xvdeintmeth= MAKE_ATOM(sisxvdeinterlace);
-#endif
 #ifdef XV_SD_DEPRECATED
 pSiS-xv_QVF  = MAKE_ATOM(sisxvqueryvbflags);
 pSiS-xv_GDV = MAKE_ATOM(sisxvsdgetdriverversion);
@@ -1212,12 +1209,6 @@ SISSetPortAttribute(ScrnInfoPtr pScrn, Atom attribute,
  pPriv-chromamin = value;
   } else if(attribute == pSiS-xvChromaMax) {
  pPriv-chromamax = value;
-#ifdef SISDEINT
-  } else if(attribute == pSiS-xvdeintmeth) {
- if(value  0) value = 0;
- if(value  4) value = 4;
- pPriv-deinterlacemethod = value;
-#endif
   } else if(attribute == pSiS-xvHue) {
  if(pSiS-VGAEngine == SIS_315_VGA) {
 if((value  -8) || (value  7)) return BadValue;
@@ -1309,10 +1300,6 @@ SISGetPortAttribute(ScrnInfoPtr pScrn, Atom attribute,
  *value = pPriv-chromamin;
   } else if(attribute == pSiS-xvChromaMax) {
  *value = pPriv-chromamax;
-#ifdef SISDEINT
-  } else if(attribute == pSiS-xvdeintmeth) {
- *value = pPriv-deinterlacemethod;
-#endif
   } else if(attribute == pSiS-xvHue) {
  if(pSiS-VGAEngine == SIS_315_VGA) {
 *value = pPriv-hue;
@@ -2666,26 +2653,7 @@ SISDisplayVideo(ScrnInfoPtr pScrn, SISPortPrivPtr pPriv)
   overlay.keyOP = VI_ROP_DestKey;
}
 
-#ifdef SISDEINT
-   switch(pPriv-deinterlacemethod) {
-   case 1:
-  overlay.bobEnable = 0x02;
-  /* overlay.bobEnable |= (pPriv-currentBuf) ? 0x00 : 0x10; */
-  break;
-   case 2:
-  overlay.bobEnable = 0x08;
-  /* overlay.bobEnable |= (pPriv-currentBuf) ? 0x00 : 0x10; */
-  break;
-   case 3:
-  overlay.bobEnable = 0x0a;
-  /* overlay.bobEnable |= (pPriv-currentBuf) ? 0x00 : 0x10; */
-  break;
-   default:
-#endif
   overlay.bobEnable = 0x00;/* Disable BOB de-interlacer */
-#ifdef SISDEINT
-   }
-#endif
 
 #ifdef SISMERGED
if(pSiS-MergedFB) {
@@ -3461,9 +3429,6 @@ SISPutImage(
int myreds[] = { 0x00ff, 0xf800, 0, 0x00ff };
 #endif
int totalSize = 0;
-#ifdef SISDEINT
-   Booldeintfm = (pPriv-deinterlacemethod  1) ? TRUE : FALSE;
-#endif
 
 #if 0
xf86DrvMsg(0, X_INFO, PutImage: src %dx%d-%dx%d, drw %dx%d-%dx%d, id %x, w 
%d h %d, buf %p\n,
@@ -3545,23 +3510,6 @@ SISPutImage(
if(!(pPriv-bufAddr[0] = SISAllocateFBMemory(pScrn, pPriv-handle, 
totalSize  1)))
   return BadAlloc;
 
-#ifdef SISDEINT
-   if(deintfm) {
-  pPriv-bufAddr[1] = pPriv-bufAddr[0] + pPriv-srcPitch;
-
-  {
- CARD8 *src = (CARD8 *)buf;
- CARD8 *dest = (CARD8 *)(pSiS-FbBase + 
pPriv-bufAddr[pPriv-currentBuf]);
- int i = height;
- while(i--) {
-   SiSMemCopyToVideoRam(pSiS, dest, src, pPriv-srcPitch);
-   src += pPriv-srcPitch;
-   dest += (pPriv-srcPitch  1);
- }
-  }
-
-   } else {
-#endif
   pPriv-bufAddr[1] = pPriv-bufAddr[0] + totalSize;
 
   /* copy data */
@@ -3578,9 +3526,6 @@ SISPutImage(
*dest++ = *src++;
  }
   }
-#ifdef SISDEINT
-   }
-#endif
 
SISDisplayVideo(pScrn, pPriv);
 
diff --git a/src/sis_video.h b/src/sis_video.h
index 7cd63c3..25fadd1 100644
--- a/src/sis_video.h
+++ b/src/sis_video.h
@@ -214,9 +214,6 @@ static char sisxvinsidechromakey[]  = 
XV_INSIDE_CHROMAKEY;
 static char sisxvyuvchromakey[]= XV_YUV_CHROMAKEY;
 static char sisxvchromamin[]   = XV_CHROMAMIN;
 static char sisxvchromamax

[PATCH sis 13/15] Remove deprecated XV SD interface

2011-04-06 Thread Timo Aaltonen
Signed-off-by: Timo Aaltonen timo.aalto...@canonical.com
---
 src/sis.h |   17 --
 src/sis_utility.c |  515 -
 src/sis_video.c   |   71 
 src/sis_video.h   |  180 ---
 4 files changed, 0 insertions(+), 783 deletions(-)

diff --git a/src/sis.h b/src/sis.h
index f40563e..9ef30b8 100644
--- a/src/sis.h
+++ b/src/sis.h
@@ -211,10 +211,6 @@
 #endif
 #endif
 
-#if 0
-#define XV_SD_DEPRECATED   /* Include deprecated XV SD interface for 
SiSCtrl */
-#endif
-
 /* End of configurable stuff - */
 
 #define UNLOCK_ALWAYS  /* Always unlock the registers (should be set!) 
*/
@@ -1250,19 +1246,6 @@ typedef struct {
 Atom   xvDisableColorkey, xvUseChromakey, xvChromaMin, 
xvChromaMax;
 Atom   xvInsideChromakey, xvYUVChromakey, xvVSync;
 Atom   xvGammaRed, xvGammaGreen, xvGammaBlue;
-#ifdef XV_SD_DEPRECATED
-Atom   xv_QVF, xv_QVV, xv_USD, xv_SVF, xv_QDD, xv_TAF, xv_TSA, 
xv_TEE, xv_GSF;
-Atom   xv_TTE, xv_TCO, xv_TCC, xv_TCF, xv_TLF, xv_CMD, 
xv_CMDR, xv_CT1, xv_SGA;
-Atom   xv_GDV, xv_GHI, xv_OVR, xv_GBI, xv_TXS, xv_TYS, xv_CFI, 
xv_COC, xv_COF;
-Atom   xv_YFI, xv_GSS, xv_BRR, xv_BRG, xv_BRB, xv_PBR, xv_PBG, 
xv_PBB, xv_SHC;
-Atom   xv_BRR2, xv_BRG2, xv_BRB2, xv_PBR2, xv_PBG2, xv_PBB2, 
xv_PMD, xv_RDT;
-Atom   xv_GARC2,xv_GAGC2,xv_GABC2, xv_GSF2;
-Atom   xv_BRRC2, xv_BRGC2, xv_BRBC2, xv_PBRC2, xv_PBGC2, 
xv_PBBC2;
-#ifdef TWDEBUG
-Atom   xv_STR;
-#endif
-unsigned int   xv_sd_result;
-#endif /* XV_SD_DEPRECATED */
 intxv_sisdirectunlocked;
 intSiS76xLFBSize;
 intSiS76xUMASize;
diff --git a/src/sis_utility.c b/src/sis_utility.c
index 0e9dc5b..a3f61b1 100644
--- a/src/sis_utility.c
+++ b/src/sis_utility.c
@@ -254,13 +254,6 @@ typedef struct {
 void   SiSCtrlExtInit(ScrnInfoPtr pScrn);
 void   SiSCtrlExtUnregister(SISPtr pSiS, int index);
 
-#ifdef XV_SD_DEPRECATED
-intSISSetPortUtilAttribute(ScrnInfoPtr pScrn, Atom attribute,
-   INT32 value, SISPortPrivPtr pPriv);
-intSISGetPortUtilAttribute(ScrnInfoPtr pScrn,  Atom attribute,
-   INT32 *value, SISPortPrivPtr pPriv);
-#endif
-
 extern BoolSISRedetectCRT2Type(ScrnInfoPtr pScrn);
 extern UShort  SiS_CheckModeCRT1(ScrnInfoPtr pScrn, DisplayModePtr mode,
 unsigned int VBFlags, Bool hcm);
@@ -713,37 +706,6 @@ SISCheckModeForCRT2Type(ScrnInfoPtr pScrn, DisplayModePtr 
mode, ULong vbflags, U
 return result;
 }
 
-#ifdef XV_SD_DEPRECATED
-static int
-SISCheckModeIndexForCRT2Type(ScrnInfoPtr pScrn, UShort cond, UShort index, 
Bool quiet)
-{
-SISPtr pSiS = SISPTR(pScrn);
-DisplayModePtr mode = pScrn-modes;
-ULong vbflags;
-int i;
-
-/* Not only CRT2, but also LCDA */
-
-/* returns 0 if mode ok,
- * 0x01 if mode not ok for CRT2 device,
- * 0x02 if mode too large for current root window
- * or combinations thereof
- */
-
-vbflags = SiSCondToVBFlags(cond, pSiS-VBFlags);
-
-/* Find mode of given index */
-if(index) {
-   for(i = 0; i  index; i++) {
-  if(!mode) return 0x03;
-  mode = mode-next;
-   }
-}
-
-return(SISCheckModeForCRT2Type(pScrn, mode, vbflags, cond, quiet));
-}
-#endif
-
 static DisplayModePtr
 sisFindModeFromTiming(ScrnInfoPtr pScrn, UShort hdisplay,
  UShort vdisplay, UShort htotal, UShort vtotal,
@@ -2102,480 +2064,3 @@ SiSCtrlExtUnregister(SISPtr pSiS, int index)
   }
}
 }
-
-/***
- * Xv attribute interface  *
- ***/
-
-#ifdef XV_SD_DEPRECATED
-
-int
-SISSetPortUtilAttribute(ScrnInfoPtr pScrn, Atom attribute,
-   INT32 value, SISPortPrivPtr pPriv)
-{
-  SISPtr pSiS = SISPTR(pScrn);
-#ifdef SISDUALHEAD
-  SISEntPtr pSiSEnt = pSiS-entityPrivate;;
-#endif
-
-  if(attribute == pSiS-xv_USD) {
- if(pSiS-enablesisctrl) {
-if(value == SIS_DIRECTKEY) {
-  pSiS-xv_sisdirectunlocked++;
-   } else if(pSiS-xv_sisdirectunlocked) {
-  pSiS-xv_sisdirectunlocked--;
-   }
- } else {
-   pSiS-xv_sisdirectunlocked = 0;
- }
-  } else if(attribute == pSiS-xv_SVF) {
-#ifdef SISDUALHEAD
- if(!pPriv-dualHeadMode)
-#endif
-   if(pSiS-xv_sisdirectunlocked) {
-  SISSwitchCRT2Type(pScrn, (ULong)value, FALSE);
-  SISUpdateVideoParms(pSiS, pPriv);
-   }
-  } else if(attribute == pSiS-xv_CT1) {
-#ifdef SISDUALHEAD
- if(!pPriv-dualHeadMode)
-#endif
-   if(pSiS-xv_sisdirectunlocked) {
-  SISSwitchCRT1Status(pScrn, (ULong)value, FALSE

Re: [PATCH sis 04/15] Fix suggest parentheses around operand of ‘!’ compiler warnings.

2011-04-07 Thread TImo Aaltonen
On 06.04.2011 23:14, Mark Kettenis wrote:
 From: Timo Aaltonen tjaal...@ubuntu.com
 Date: Wed,  6 Apr 2011 19:50:06 +0300

 Signed-off-by: Timo Aaltonen timo.aalto...@canonical.com
 ---
  src/sis_cursor.c  |2 +-
  src/sis_utility.c |2 +-
  2 files changed, 2 insertions(+), 2 deletions(-)

 diff --git a/src/sis_cursor.c b/src/sis_cursor.c
 index 13eddc4..67a3402 100644
 --- a/src/sis_cursor.c
 +++ b/src/sis_cursor.c
 @@ -759,7 +759,7 @@ SiS300LoadCursorImage(ScrnInfoPtr pScrn, UChar *src)
  }
  
  if(pSiS-VBFlags  CRT2_ENABLE) {
 -   if((pSiS-UseHWARGBCursor)  (!pSiS-VBFlags  DISPTYPE_CRT1)) {
 +   if((pSiS-UseHWARGBCursor)  ((!pSiS-VBFlags)  DISPTYPE_CRT1)) {
 
 Hmm, while your change is correct in the sense that it doesn't change
 the meaning of the code, I do think that what's actually meant here is:
 
if((pSiS-UseHWARGBCursor)  (!(pSiS-VBFlags  DISPTYPE_CRT1))) {
 
 What's there now, just doesn't make sense, since it will always
 evaluate to false.  See also SiS310LoadCursorImage.

Yeah, you're right. I'll post a fixed patch shortly. Thanks!
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel


[PATCH sis v2 04/15] Fix suggest parentheses around operand of ‘!’ compiler warnings.

2011-04-07 Thread Timo Aaltonen
Signed-off-by: Timo Aaltonen timo.aalto...@canonical.com
---
 src/sis_cursor.c  |2 +-
 src/sis_utility.c |2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

Fix the logic, as pointed out by Mark Kettenis.

diff --git a/src/sis_cursor.c b/src/sis_cursor.c
index 13eddc4..67a3402 100644
--- a/src/sis_cursor.c
+++ b/src/sis_cursor.c
@@ -759,7 +759,7 @@ SiS300LoadCursorImage(ScrnInfoPtr pScrn, UChar *src)
 }
 
 if(pSiS-VBFlags  CRT2_ENABLE) {
-   if((pSiS-UseHWARGBCursor)  (!pSiS-VBFlags  DISPTYPE_CRT1)) {
+   if((pSiS-UseHWARGBCursor)  (!(pSiS-VBFlags  DISPTYPE_CRT1))) {
  status2 = sis301GetCursorStatus;
  sis301DisableHWCursor()
  SISWaitRetraceCRT2(pScrn);
diff --git a/src/sis_utility.c b/src/sis_utility.c
index 64d8919..0892cf5 100644
--- a/src/sis_utility.c
+++ b/src/sis_utility.c
@@ -523,7 +523,7 @@ SISSwitchCRT2Type(ScrnInfoPtr pScrn, ULong newvbflags, Bool 
quiet)
 }
 #endif
 
-if((!(newvbflags  CRT2_ENABLE))  (!newvbflags  DISPTYPE_CRT1)) {
+if((!(newvbflags  CRT2_ENABLE))  (!(newvbflags  DISPTYPE_CRT1))) {
if(!quiet) {
   xf86DrvMsg(pScrn-scrnIndex, X_ERROR,
  CRT2 can't be switched off while CRT1 is off\n);
-- 
1.7.4.1

___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel


Re: [PATCH sis 00/15] a bunch of cleanups, and a taste of things to come

2011-04-13 Thread TImo Aaltonen
On 06.04.2011 19:50, Timo Aaltonen wrote:
 Here's a first set of patches to xf86-video-sis, hoping to narrow down
 the diff against Thomas Winischofer's 'sisfree' (*) package and the
 forked versions from Intel and SiS (and Mandriva).
 
 The first 13 are more or less self-explanatory, but the two final ones
 are moving things around to make the code more readable, among other things.
 
 Every commit is build-tested against xserver 1.10 headers.
 
 * http://www.winischhofer.net/linuxsispart4.shtml#download
 
 Timo Aaltonen (15):
   Write out remaining IS_SIS* macros.
   Replace deprecated x(c)alloc/xfree with m/calloc/free
   Fix format not a string literal and no format arguments compile
 warnings
   Fix suggest parentheses around operand of ‘!’ compiler warnings.
   Fix compile warnings of uninitialized variables
   Declare mmioFlags only if XSERVER_LIBPCIACCESS isn't defined
   Purge obsolete and unused SIS_CP checks
   Drop useless checks and relevant code for old XFree86 releases
   Drop unused and non-working XAA trapezoid support for 310 series and
 later
   Remove unused code from sis_video.c
   Remove unused code from SISPutImageBlit()
   Remove unused  non-working Xv deinterlacer code
   Remove deprecated XV SD interface
   Move configurable values from sis.h to sis_config.h
   Move all TV related functions fron sis_driver.c to sis_vb.c
 
  src/init.c  |   35 +-
  src/init.h  |3 -
  src/init301.c   |   62 +-
  src/init301.h   |3 -
  src/initdef.h   |   19 +-
  src/initextx.c  |   18 +-
  src/sis.h   |   86 +--
  src/sis310_accel.c  |  754 ---
  src/sis6326_video.c |   60 +--
  src/sis_accel.c |  128 ---
  src/sis_config.h|   71 ++
  src/sis_cursor.c|8 +-
  src/sis_dac.h   |2 +
  src/sis_dga.c   |6 +-
  src/sis_dri.c   |   38 +-
  src/sis_driver.c| 2625 
 ---
  src/sis_driver.h|  813 +
  src/sis_memcpy.c|   10 +-
  src/sis_opt.c   |   49 +-
  src/sis_utility.c   |  527 +--
  src/sis_vb.c| 2259 ++--
  src/sis_vb.h|  931 ++
  src/sis_vga.c   |7 +-
  src/sis_video.c |  291 +--
  src/sis_video.h |  195 
  src/sis_videostr.h  |3 -
  src/vgatypes.h  |5 -
  27 files changed, 3490 insertions(+), 5518 deletions(-)
  create mode 100644 src/sis_config.h
  create mode 100644 src/sis_vb.h
 

Ping? Patch 04/15 got reviewed, but the rest are still waiting for input.

t
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel

Re: [PATCH sis 00/15] a bunch of cleanups, and a taste of things to come

2011-04-27 Thread TImo Aaltonen
On 13.04.2011 18:22, TImo Aaltonen wrote:
 On 06.04.2011 19:50, Timo Aaltonen wrote:
 Here's a first set of patches to xf86-video-sis, hoping to narrow down
 the diff against Thomas Winischofer's 'sisfree' (*) package and the
 forked versions from Intel and SiS (and Mandriva).

 The first 13 are more or less self-explanatory, but the two final ones
 are moving things around to make the code more readable, among other things.

 Every commit is build-tested against xserver 1.10 headers.

 * http://www.winischhofer.net/linuxsispart4.shtml#download

 Timo Aaltonen (15):
   Write out remaining IS_SIS* macros.
   Replace deprecated x(c)alloc/xfree with m/calloc/free
   Fix format not a string literal and no format arguments compile
 warnings
   Fix suggest parentheses around operand of ‘!’ compiler warnings.
   Fix compile warnings of uninitialized variables
   Declare mmioFlags only if XSERVER_LIBPCIACCESS isn't defined
   Purge obsolete and unused SIS_CP checks
   Drop useless checks and relevant code for old XFree86 releases
   Drop unused and non-working XAA trapezoid support for 310 series and
 later
   Remove unused code from sis_video.c
   Remove unused code from SISPutImageBlit()
   Remove unused  non-working Xv deinterlacer code
   Remove deprecated XV SD interface
   Move configurable values from sis.h to sis_config.h
   Move all TV related functions fron sis_driver.c to sis_vb.c

  src/init.c  |   35 +-
  src/init.h  |3 -
  src/init301.c   |   62 +-
  src/init301.h   |3 -
  src/initdef.h   |   19 +-
  src/initextx.c  |   18 +-
  src/sis.h   |   86 +--
  src/sis310_accel.c  |  754 ---
  src/sis6326_video.c |   60 +--
  src/sis_accel.c |  128 ---
  src/sis_config.h|   71 ++
  src/sis_cursor.c|8 +-
  src/sis_dac.h   |2 +
  src/sis_dga.c   |6 +-
  src/sis_dri.c   |   38 +-
  src/sis_driver.c| 2625 
 ---
  src/sis_driver.h|  813 +
  src/sis_memcpy.c|   10 +-
  src/sis_opt.c   |   49 +-
  src/sis_utility.c   |  527 +--
  src/sis_vb.c| 2259 ++--
  src/sis_vb.h|  931 ++
  src/sis_vga.c   |7 +-
  src/sis_video.c |  291 +--
  src/sis_video.h |  195 
  src/sis_videostr.h  |3 -
  src/vgatypes.h  |5 -
  27 files changed, 3490 insertions(+), 5518 deletions(-)
  create mode 100644 src/sis_config.h
  create mode 100644 src/sis_vb.h

 
 Ping? Patch 04/15 got reviewed, but the rest are still waiting for input.

And another ping.

Patch 03 is apparently controversial, I could drop it from the series..


-- 
t
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel

Re: [PATCH] Revert composite: Don't backfill non-bg-None windows

2011-05-31 Thread TImo Aaltonen
On 29.03.2011 17:29, Alex Deucher wrote:
 On Tue, Mar 29, 2011 at 10:25 AM, Adam Jackson a...@redhat.com wrote:
 This reverts commit 6dd775f57d2f94f0ddaee324aeec33b9b66ed5bc.

 Bugzilla: https://bugs.freedesktop.org/34427

 Signed-off-by: Adam Jackson a...@redhat.com
 
 Acked-by: Alex Deucher alexdeuc...@gmail.com

Looks like this has gone unnoticed, still not in master and therefore
unable to propose it for 1.10-branch.

Acked-by: Timo Aaltonen timo.aalto...@canonical.com

 
 ---
  composite/compalloc.c |   26 --
  1 files changed, 0 insertions(+), 26 deletions(-)

 diff --git a/composite/compalloc.c b/composite/compalloc.c
 index e4064f6..7164c0d 100644
 --- a/composite/compalloc.c
 +++ b/composite/compalloc.c
 @@ -508,17 +508,6 @@ compUnredirectOneSubwindow (WindowPtr pParent, 
 WindowPtr pWin)
 return Success;
  }

 -static int
 -bgNoneVisitWindow(WindowPtr pWin, void *null)
 -{
 -if (pWin-backgroundState != BackgroundPixmap)
 -   return WT_WALKCHILDREN;
 -if (pWin-background.pixmap != None)
 -   return WT_WALKCHILDREN;
 -
 -return WT_STOPWALKING;
 -}
 -
  static PixmapPtr
  compNewPixmap (WindowPtr pWin, int x, int y, int w, int h, Bool map)
  {
 @@ -539,21 +528,6 @@ compNewPixmap (WindowPtr pWin, int x, int y, int w, int 
 h, Bool map)
 if (!map)
return pPixmap;

 -/*
 - * If there's no bg=None in the tree, we're done.
 - *
 - * We could optimize this more by collection the regions of all the
 - * bg=None subwindows and feeding that in as the clip for the
 - * CopyArea below, but since window trees are shallow these days it
 - * might not be worth the effort.
 - */
 -if (TraverseTree(pWin, bgNoneVisitWindow, NULL) == WT_NOMATCH)
 -   return pPixmap;
 -
 -/*
 - * Copy bits from the parent into the new pixmap so that it will
 - * have reasonable contents in case for background None areas.
 - */
 if (pParent-drawable.depth == pWin-drawable.depth)
 {
GCPtr   pGC = GetScratchGC (pWin-drawable.depth, pScreen);
 --
 1.7.4

 ___
 xorg-devel@lists.x.org: X.Org development
 Archives: http://lists.x.org/archives/xorg-devel
 Info: http://lists.x.org/mailman/listinfo/xorg-devel

 ___
 xorg-devel@lists.x.org: X.Org development
 Archives: http://lists.x.org/archives/xorg-devel
 Info: http://lists.x.org/mailman/listinfo/xorg-devel
 


-- 
t
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel


Re: [ANNOUNCE] xorg-server 1.7.99.902

2010-03-24 Thread Timo Aaltonen

On Wed, 24 Mar 2010, Stefan Dirsch wrote:


On Mon, Mar 22, 2010 at 07:59:18AM -0700, Dan Nicholson wrote:

2. Make the handling of missing sections from an existing
configuration behave more like the full autoconfig. In other words, if
there's a missing Screen section, generate multiple Screen/Device
pairs with fallbacks. I think this is the correct fix, but I'm not
that familiar with the autoconfig code so I don't think I could whip
up a patch that fast.


I've now attached a patch to

 https://bugs.freedesktop.org/show_bug.cgi?id=27229

which does that. It works fine for us.


Excellent, thanks Rüdiger! :)

just what I've been missing since xorg.conf.d was pushed.. backported all 
of x.c.d/inputclass/etc on top of 1.7.6 and it seems to work great.



--
Timo Aaltonen
Systems Specialist
IT Services, Aalto University School of Science and Technology
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel


Re: [ANNOUNCE] xorg-server 1.7.99.902

2010-03-25 Thread Timo Aaltonen

On Thu, 25 Mar 2010, Ruediger Oertel wrote:


Do you have any backtrace information?

sure ...
Program received signal SIGSEGV, Segmentation fault.
0x0055fe4f in DeliverPropertyEvent (pWin=0x4545454545454545, 
value=0x7fffdf00) at rrproperty.c:34
34  rrproperty.c: No such file or directory.
   in rrproperty.c
(gdb) bt
#0  0x0055fe4f in DeliverPropertyEvent (pWin=0x4545454545454545, 
value=0x7fffdf00) at rrproperty.c:34
#1  0x00443e85 in TraverseTree (pWin=0x87dd00, func=0x55fe30 
DeliverPropertyEvent, data=0x7fffdf00) at window.c:233
#2  0x0055ff4e in RRDeleteAllOutputProperties (output=0x838fe0) at 
rrproperty.c:77
#3  0x0049d41b in RROutputDestroyResource (value=0x838fe0, pid=value 
optimized out) at rroutput.c:413
#4  0x00456f13 in FreeClientResources (client=value optimized out) at 
resource.c:810
#5  0x00456fe9 in FreeAllResources () at resource.c:827
#6  0x00425bb1 in main (argc=value optimized out, argv=value optimized 
out, envp=value optimized out) at main.c:300


Do you mean that it crashes when you stop/restart the server (which 
usually happens on logout). Have you tried it on top of 1.7.x? I have, and 
it doesn't crash there.. tried on my laptop with intel, and it loads vesa 
and fbdev as well.




--
Timo Aaltonen
Systems Specialist
IT Services, Aalto University School of Science and Technology
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel


Re: [ANNOUNCE] xorg-server 1.7.99.902

2010-03-25 Thread Timo Aaltonen

On Thu, 25 Mar 2010, Timo Aaltonen wrote:


On Thu, 25 Mar 2010, Ruediger Oertel wrote:


On Thursday 25 March 2010 20:45:27 Timo Aaltonen wrote:

On Thu, 25 Mar 2010, Ruediger Oertel wrote:

Do you have any backtrace information?


sure ...
Program received signal SIGSEGV, Segmentation fault.
0x0055fe4f in DeliverPropertyEvent (pWin=0x4545454545454545,
value=0x7fffdf00) at rrproperty.c:34 34  rrproperty.c: No such
file or directory.

   in rrproperty.c

(gdb) bt
#0  0x0055fe4f in DeliverPropertyEvent (pWin=0x4545454545454545,
value=0x7fffdf00) at rrproperty.c:34 #1  0x00443e85 in
TraverseTree (pWin=0x87dd00, func=0x55fe30 DeliverPropertyEvent,
data=0x7fffdf00) at window.c:233 #2  0x0055ff4e in
RRDeleteAllOutputProperties (output=0x838fe0) at rrproperty.c:77 #3
0x0049d41b in RROutputDestroyResource (value=0x838fe0,
pid=value optimized out) at rroutput.c:413 #4  0x00456f13 in
FreeClientResources (client=value optimized out) at resource.c:810 #5
0x00456fe9 in FreeAllResources () at resource.c:827
#6  0x00425bb1 in main (argc=value optimized out, argv=value
optimized out, envp=value optimized out) at main.c:300


Do you mean that it crashes when you stop/restart the server (which
usually happens on logout). Have you tried it on top of 1.7.x? I have, and
it doesn't crash there.. tried on my laptop with intel, and it loads vesa
and fbdev as well.

yes, for some reason it does not happen with the intel driver (or probably
other combinations with only one native driver plus fbdev and vesa).
Maybe that's a way to look: something in the screen setup may be different
for fbdev or vesa, I'll try to look later on.

my simple test to reproduce is just starting the xserver plus an xterm on
it and then exiting the xterm.


Crap, sounds like I need to try in on the desktop with nouveau/blob/nv :)


Still no crash even with that machine. Tried several different scenarios:

- nvidia loaded (nouveau blacklisted), nv/nouveau available/missing
- nouveau loaded, nv/nvidia available/missing

so I guess that leaves hybrids like intel/ati, intel/nvidia, ati/nvidia 
that are crashing?


--
Timo Aaltonen
Systems Specialist
IT Services, Aalto University School of Science and Technology
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel


Re: libX11 and xcb

2010-04-09 Thread Timo Aaltonen

On Fri, 9 Apr 2010, Jamey Sharp wrote:


I may not have a complete picture of support issues, though. Ubuntu
apparently fails to send XCB-related bug reports upstream, for example,
and naturally I can't tell if other distros are failing the same way.


Is this upstream enough?

http://bugzilla.freedesktop.org/show_bug.cgi?id=27552

though it probably should've been upstreamed earlier, my bad for assuming 
it was a dupe of the libXext related crasher. The component might still be 
wrong, adjust if needed.


Other than that it has been quite stable.


--
Timo Aaltonen
Systems Specialist
IT Services, Aalto University
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel


Re: libX11 and xcb

2010-04-10 Thread Timo Aaltonen

On Sat, 10 Apr 2010, Jamey Sharp wrote:


On Fri, Apr 9, 2010 at 2:49 PM, Timo Aaltonen timo.aalto...@aalto.fi wrote:

On Fri, 9 Apr 2010, Jamey Sharp wrote:

I may not have a complete picture of support issues, though. Ubuntu
apparently fails to send XCB-related bug reports upstream, for example,
and naturally I can't tell if other distros are failing the same way.


Is this upstream enough?

http://bugzilla.freedesktop.org/show_bug.cgi?id=27552


Yes! Thanks. :-)

Though I'd like to encourage people with libX11 bugs that might be
XCB-related to CC x...@lists.freedesktop.org, when filing them in
Bugzilla. That helps ensure that XCB experts see them.


Ok thanks, I'll try to remember if there's a next time ;)


though it probably should've been upstreamed earlier, my bad for assuming it
was a dupe of the libXext related crasher.


I was just grumpy that if I see an Ubuntu bug related to XCB, it's
often full of negative comments. If what's really going on is that
you're protecting me from your users' wrath, then thank you. :-)


Totally with you on this. The bug above is unlike the Sun java related one 
which hit us after inheriting xcb enabled libX11 from Debian roughly two 
years ago. _Those_ people were negative, though it was easy to work around in 
the end :) And this one is hard to reproduce despite the dupes :/



--
Timo Aaltonen
Systems Specialist
IT Services, Aalto University
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel


Re: [PATCH sis 00/15] a bunch of cleanups, and a taste of things to come

2011-10-30 Thread Timo Aaltonen
30.10.2011 15:27, Jeremy Huddleston kirjoitti:
 Wow, I wish I knew about this series before I started cleaning up the
 drivers...
 
 Where was this series sent?  I don't see it in my xorg-devel log.

Looks like it was on 6th of April. I got an ack from Dave to just push
it sometime in May, but then never got that far.

 By all means, take it over.  Do you want to maintain it?  If so, get
 yourself an fd.o account, so you can get yourself commit access to
 the driver.  See http://www.freedesktop.org/wiki/AccountRequests

I have an account, so maybe I'll revive the set in the coming weeks and
start pushing things to the repo. Dunno about taking over the
maintainership though, I really hate the sis machine I got ;)

t
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel


Re: Problem with touchscreen events and grabs

2012-10-22 Thread Timo Aaltonen
On 22.10.2012 09:47, Peter Hutterer wrote:
 On Tue, Oct 16, 2012 at 09:54:23PM -0400, Thomas Jaeger wrote:
 I've noticed an issue with grabs as well, not sure if it's related to
 this one.  It's really easy to reproduce, though:  All you need is a
 little test client that passively grabs button 1 on the MD (like the one
 attached).  A passive core grab will do as well.  What happens is that
 (1) clients selecting for core events will receive emulated pointer
 events despite the passive grab and (2) sometimes ButtonRelease events
 go missing (this goes both for the grabbing and non-grabbing clients,
 but not necessarily at the same time).
 
 btw, did you file a bug for this one? I've got a preliminary patch
 (attached) but I'm not sure of the side-effects yet.

For me the patch only made it faster to lose control of the desktop,
grab.c still shows press/release events but button1 seems stuck. Testing
with unity on ubuntu 12.10 the first touch on the launcher breaks it. If
I launch apps remotely without the launcher, everything seems to work fine.


-- 
t
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel


Re: [PULL 1.13 v2] input fixes and video ABI 13.1

2012-10-25 Thread Timo Aaltonen
On 12.10.2012 09:35, Peter Hutterer wrote:
 On Fri, Oct 12, 2012 at 12:14:21AM -0600, Matt Dew wrote:
 Ack'd.
   Are there any bugzilla tickets (fdo or other?) related to this?
 
 https://bugs.freedesktop.org/show_bug.cgi?id=55752 is the one for the ABI
 bump though it may be a bit sparse.

https://bugs.freedesktop.org/show_bug.cgi?id=54614
for Xi: Don't check for TOUCH_END, it's never set


 On Thu, Oct 11, 2012 at 5:59 PM, Peter Hutterer 
 peter.hutte...@who-t.netwrote:

 Matt,

 This is an updated pull request for server 1.13.1. One more input fix,
 scaling edge
 cases into the correct coordinates. A bigger change is the export of the
 new
 xf86UpdateDesktopDimensions() API as part of ABI 13.1. This is a
 convenience
 API for binary drivers (read: NVIDIA) to update the server's representation
 of the desktop dimensions after changing outputs. That again is needed for
 the transformation matrix to work, e.g. if you want a tablet mapped to a
 single screen only.

 Cheers,
Peter

 The following changes since commit
 f0bad69edd57facd6cffde8cb0863d1a735e2492:

   Version bumped to 1.13 (2012-09-05 14:45:08 -0700)

 are available in the git repository at:

   git://people.freedesktop.org/~whot/xserver server-1.13-branch

 for you to fetch changes up to 8f39a6b0b35764c8d5cac4c7bf66d5902c0ae9a5:

   xfree86: add xf86UpdateDesktopDimensions() (2012-10-12 09:48:10 +1000)

 
 Daniel Drake (1):
   Xi: Don't check for TOUCH_END, it's never set

 Daniel Stone (1):
   Touch: Fix duplicate TouchBegin selection with virtual devices

 Peter Hutterer (3):
   dix: set the device transformation matrix
   dix: fix crash on XI 1.x grabs on disabled devices.  (#54934)
   xfree86: add xf86UpdateDesktopDimensions()

 Yufeng Shen (1):
   dix: fix scale_to_desktop for edge ABS events

  Xi/exevents.c  | 2 --
  Xi/xiselectev.c| 9 +++--
  dix/devices.c  | 3 +++
  dix/events.c   | 9 ++---
  dix/getevents.c| 4 ++--
  hw/xfree86/common/xf86.h   | 4 
  hw/xfree86/common/xf86Helper.c | 6 ++
  hw/xfree86/common/xf86Module.h | 2 +-
  8 files changed, 29 insertions(+), 10 deletions(-)

 ___
 xorg-devel@lists.x.org: X.Org development
 Archives: http://lists.x.org/archives/xorg-devel
 Info: http://lists.x.org/mailman/listinfo/xorg-devel
 


-- 
t
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel


[PATCH] Fix kwin crashes on xrandr update on NX

2013-02-06 Thread Timo Aaltonen

https://bugs.freedesktop.org/show_bug.cgi?id=59795

Signed-off-by: Ritesh Khadgaray khadga...@gmail.com
Reviewed-by: Peter Hutterer peter.hutte...@who-t.net
---
 src/Xrandr.c |4 
 1 file changed, 4 insertions(+)

diff --git a/src/Xrandr.c b/src/Xrandr.c
index b1e97ec..9a56636 100644
--- a/src/Xrandr.c
+++ b/src/Xrandr.c
@@ -483,6 +483,10 @@ int XRRUpdateConfiguration(XEvent *event)
scevent = (XRRScreenChangeNotifyEvent *) event;
snum = XRRRootToScreen(dpy,
   ((XRRScreenChangeNotifyEvent *) event)-root);
+   /* check for return value, fails on nx */
+   if (snum == -1 ) {
+   return 0;
+   }
if (scevent-rotation  (RR_Rotate_90 | RR_Rotate_270)) {
dpy-screens[snum].width   = scevent-height;
dpy-screens[snum].height  = scevent-width;
-- 
1.7.10.4
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel


Re: BCM5974 touchpad issues...

2013-02-12 Thread Timo Aaltonen

On 12.02.2013 09:32, Daniel J Blueman wrote:

On 12 February 2013 12:47, Peter Hutterer peter.hutte...@who-t.net wrote:

please don't send out 4 emails for the same issue.


My apologies; posting, subscribing and resubscribing to the right
mailing list with you CCd was racing with quick moderator approval.


On Mon, Feb 11, 2013 at 03:10:41PM +0800, Daniel J Blueman wrote:

I'm seeing erratic click events on Broadcom 5974 touchpads (Macbook
Pro 10,1) during two-finger scrolling.

I was wondering what mailing list is the most relevant, and where to
start to see if this is a userspace or kernel HID issue, anyone?

Thanks,
   Daniel

$ synclient
Parameter settings:
 LeftEdge= -3898


this doesn't look right. did you set this somehow, or is this the default
it comes up with?


This is the default, perhaps because the BCM5974 advertises a clickpad property.


 RightEdge   = 4428
 TopEdge = 434
 BottomEdge  = 6146
 FingerLow   = 70
 FingerHigh  = 75
 FingerPress = 257
 MaxTapTime  = 180
 MaxTapMove  = 535
 MaxDoubleTapTime= 180
 SingleTapTimeout= 180
 ClickTime   = 100
 FastTaps= 0
 EmulateMidButtonTime= 0
 EmulateTwoFingerMinZ= 283
 EmulateTwoFingerMinW= 7
 VertScrollDelta = -243
 HorizScrollDelta= -243


did you configure this as negative? if not, there's a bug there somewhere.


Yes, to achieve the (IMHO) more natural scroll direction.


either way, hard to tell without any information as to what server version
or synaptics driver version you're running.


xserver-xorg-input-synaptics 1.6.2
xserver-xorg 7.7


sounds like you're on debian/ubuntu, the latter doesn't say much, 
'apt-cache policy xserver-xorg-core' would.


--
t
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel


Re: [PATCH] Fix kwin crashes on xrandr update on NX

2013-06-17 Thread Timo Aaltonen
On 06.03.2013 17:19, Timo Aaltonen wrote:
 
 https://bugs.freedesktop.org/show_bug.cgi?id=59795
 
 Signed-off-by: Ritesh Khadgaray khadga...@gmail.com
 Reviewed-by: Peter Hutterer peter.hutte...@who-t.net
 ---
  src/Xrandr.c |4 
  1 file changed, 4 insertions(+)
 
 diff --git a/src/Xrandr.c b/src/Xrandr.c
 index b1e97ec..9a56636 100644
 --- a/src/Xrandr.c
 +++ b/src/Xrandr.c
 @@ -483,6 +483,10 @@ int XRRUpdateConfiguration(XEvent *event)
 scevent = (XRRScreenChangeNotifyEvent *) event;
 snum = XRRRootToScreen(dpy,
((XRRScreenChangeNotifyEvent *) event)-root);
 + /* check for return value, fails on nx */
 + if (snum == -1 ) {
 + return 0;
 + }
 if (scevent-rotation  (RR_Rotate_90 | RR_Rotate_270)) {
 dpy-screens[snum].width   = scevent-height;
 dpy-screens[snum].height  = scevent-width;
 

should I just push this by now?


-- 
t
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel


Re: [PULL 1.14] touch fixes, backported

2013-08-12 Thread Timo Aaltonen
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On 17.07.2013 08:27, Peter Hutterer wrote:
 I admit this is a huge set of patches but it's needed. Mostly
 prompted by 56578 it fixes a number of things wrong with the touch
 implementation as shipped in 1.12-1.14, fixing a few race
 conditions, a few bad deliveries and a bunch of dangling pointer
 acesses.
 
 I'd really like those to be in 1.14.3.

+1

We've seen positive testing dowstream on ubuntu, would be nice to see
these in 1.14.3.

- -- 
t
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.12 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iQIcBAEBAgAGBQJSCMMCAAoJEMtwMWWoiYTc0IIP/i+a6xQO0Hn2G3kvGRJcW9s7
BSiiOriwQMLvRH1n+PKDJraf/+VfyeUxxMSPmXd4cEqggvXI299Pu8lJjrtTU5mQ
INPYw5hxjk8od2fBaJKWhCZh3/BzRaqnWaei8rlZ/0byGu62xQ3ETcyFOwK5MrZc
fWmfEf4ry2PDEFu0uv0jPZgsoayJT+W10E6Bq7NmhtSs6OkiJp3dPTZXFFFvYLD9
roCdc/JrsD/aABvgzHpmNAs9/hKkZPVnlYeMhOJLrzRbqozpcPmpnGkDMlYQVP95
9SyJFkDcCQbHRE6FcJZKZ8Ch1pqZVWaJw32prfqp/smZlxd2zOa2uyG0Mdvs6xmi
F9ShDoWX6BkcENzlpg9/PrCkaj62BCUtsH4Xh4DvM6MnEedIktrMRDd4h3Ok/dLn
RtF41uYElGus8hAmXrAdCLoU2+XkKTQj2aOJu3FJnaI/WtgGavCAWhlqdf0ITx6d
WBT75qrjxV/1y3kBb+fYfXe0n2ErAQIbb4RN/YG9bkF/Wi+AmtlZIJOFCBJBZrfW
RuWoZmvWwMdp9PeVZySxNuDk0cnqJwrsaab7o6ag4D+qboq60ALLgey5Q8kmBHhP
i/qDO+bfWjSdDv66g97caqfe83c4SRKchG36ezga7Bv092MqBQh8dMRrub/O0Qof
mrFmo0hJIRQpvox3nbPI
=piVv
-END PGP SIGNATURE-
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel


Re: [PULL 1.14] touch fixes, backported

2013-08-12 Thread Timo Aaltonen
On 13.08.2013 07:20, Matt Dew wrote:
 On 08/12/2013 02:52 PM, Peter Hutterer wrote:
 On Mon, Aug 12, 2013 at 02:12:02PM +0300, Timo Aaltonen wrote:
 -BEGIN PGP SIGNED MESSAGE-
 Hash: SHA1

 On 17.07.2013 08:27, Peter Hutterer wrote:
 I admit this is a huge set of patches but it's needed. Mostly
 prompted by 56578 it fixes a number of things wrong with the touch
 implementation as shipped in 1.12-1.14, fixing a few race
 conditions, a few bad deliveries and a bunch of dangling pointer
 acesses.

 I'd really like those to be in 1.14.3.

 +1

 We've seen positive testing dowstream on ubuntu, would be nice to see
 these in 1.14.3.

 matt merges these as bc41226f7741098e55a3b0df924986991576d50a which is
 also
 the tag xorg-server-1.14.2.901.

 Cheers,
 Peter

 
 Correctomundo

Yeah, wasn't looking at the right place, my bad. Anyway, great to see
this there :)

-- 
t
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel


Re: [PATCH] config/udev: do not remove devices on add udev events

2014-01-09 Thread Timo Aaltonen
On 26.11.2013 11:56, Maarten Lankhorst wrote:
 udevadm trigger --action=add can cause devices to be unloaded,
 which breaks when X.org is already started during early init.
 
 Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=72021
 Signed-off-by: Maarten Lankhorst maarten.lankho...@canonical.com

Reviewed-by: Timo Aaltonen timo.aalto...@canonical.com


-- 
t
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel


Re: [PATCH 1/1] randr: make RROutputChanged change the main protocol screen not the gpu screen

2015-07-07 Thread Timo Aaltonen
On 14.01.2014 00:37, Alberto Milone wrote:
 On 16/12/13 09:52, Alberto Milone wrote:
 On 12/12/13 10:00, Alberto Milone wrote:
 We only set changes on the main protocol screen as, for example
 in RRSetChanged() and RRTellChanged(), therefore we should follow
 the same logic when reporting that an output changed in
 RROutputChanged().

 This means that RRTellChanged() will then update the relevant
 timestamps also when events come from gpu screens.

 Reviewed-by: Dave Airlie airl...@redhat.com
 Signed-off-by: Alberto Milone alberto.mil...@canonical.com

 Keith, please let me know if there's anything else I should modify in
 the patch or if it's ok for inclusion now.

 Thank,

 
 If there are no further objections, can you commit the patch, please?

Hi Keith, this old reviewed patch is still not merged, could you add it
please?


-- 
t
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel

Re: [PATCH xserver] randr: Do not check the screen size bound for gpu screens

2016-05-26 Thread Timo Aaltonen
On 20.05.2016 08:00, Nikhil Mahale wrote:
> For gpu screen, CrtcSet set/adjust the master screen size along
> mode in following callstack -
> 
>   ProcRRSetCrtcConfig()
> |
> -> RRCrtcSet()
> |
> -> rrCheckPixmapBounding()
> |
> -> pScrPriv->rrScreenSetSize()
> 
> Checking screen size bound for gpus screen cause some configurations
> to fails, e.g
> 
>   $ xrandr --output eDP --mode 1920x1080 --pos 0x0 --output HDMI \
>   --mode 2560x1440 --pos 0x0
> 
>   Here xrandr utility first sets screen size to 2560x1440 which
>   gets resized to 1920x1080 on RRSetCrtcConfig request for eDP,
>   and then RRSetCrtcConfig request for HDMI fails because
>   of failure of screen bound check.
> 
> Signed-off-by: Nikhil Mahale 

I've tried to come up with a test that would hang/crash the xserver
reliably, but failed. It usually takes a number of cycles through
mirrored/extended/external-only modes, or switching between
external-only and mirrored. Anyway, the impact is that on intel+nvidia
hybrid the server can crash or hang or just fail to set the mode without
these two patches.


-- 
t
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

Re: [PATCH xserver] randr: Do not check the screen size bound for gpu screens

2016-05-26 Thread Timo Aaltonen
On 26.05.2016 11:21, Nikhil Mahale wrote:
> On 05/26/2016 01:31 PM, Timo Aaltonen wrote:
>> On 20.05.2016 08:00, Nikhil Mahale wrote:
>>> For gpu screen, CrtcSet set/adjust the master screen size along
>>> mode in following callstack -
>>>
>>>   ProcRRSetCrtcConfig()
>>> |
>>> -> RRCrtcSet()
>>> |
>>> -> rrCheckPixmapBounding()
>>> |
>>> -> pScrPriv->rrScreenSetSize()
>>>
>>> Checking screen size bound for gpus screen cause some configurations
>>> to fails, e.g
>>>
>>>   $ xrandr --output eDP --mode 1920x1080 --pos 0x0 --output HDMI \
>>>   --mode 2560x1440 --pos 0x0
>>>
>>>   Here xrandr utility first sets screen size to 2560x1440 which
>>>   gets resized to 1920x1080 on RRSetCrtcConfig request for eDP,
>>>   and then RRSetCrtcConfig request for HDMI fails because
>>>   of failure of screen bound check.
>>>
>>> Signed-off-by: Nikhil Mahale <nmah...@nvidia.com>
>>
>> I've tried to come up with a test that would hang/crash the xserver
>> reliably, but failed. It usually takes a number of cycles through
>> mirrored/extended/external-only modes, or switching between
>> external-only and mirrored. Anyway, the impact is that on intel+nvidia
>> hybrid the server can crash or hang or just fail to set the mode without
>> these two patches.
>>
> 
> Sorry Timo, I don't think I understand what you want to say. This patch
> was not intended to fix hang/crash, it simple fixes modeset failure for
> the use cases like I mentioned in description of patch.
> 
> The second "[PATCH xserver] randr: Adjust master's last set time with
> slaves" fixes XRandr's client confusion about lastConfigTimes and
> lastSetTime, I seen client was repeatedly sending modeset request
> because each time it gets lastSetTime < lastConfigTime.
> 
> Both the patches only impacting prime configurations.

It was for whoever reviews these. The server certainly can crash without
the patches with prime setup, according to my tests..


-- 
t
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

[PATCH xserver] dri2: Sync i915_pci_ids.h and i965_pci_ids.h from mesa

2016-01-27 Thread Timo Aaltonen
Adds Skylake, Kabylake and Broxton allowing them to use
modesetting + glamor with dri2.

Signed-off-by: Timo Aaltonen <timo.aalto...@canonical.com>
---
 hw/xfree86/dri2/pci_ids/i915_pci_ids.h |  4 +--
 hw/xfree86/dri2/pci_ids/i965_pci_ids.h | 56 +++---
 2 files changed, 54 insertions(+), 6 deletions(-)

diff --git a/hw/xfree86/dri2/pci_ids/i915_pci_ids.h 
b/hw/xfree86/dri2/pci_ids/i915_pci_ids.h
index 7d51975..1c43c8e 100644
--- a/hw/xfree86/dri2/pci_ids/i915_pci_ids.h
+++ b/hw/xfree86/dri2/pci_ids/i915_pci_ids.h
@@ -11,5 +11,5 @@ CHIPSET(0x27AE, I945_GME, "Intel(R) 945GME")
 CHIPSET(0x29B2, Q35_G,"Intel(R) Q35")
 CHIPSET(0x29C2, G33_G,"Intel(R) G33")
 CHIPSET(0x29D2, Q33_G,"Intel(R) Q33")
-CHIPSET(0xA011, IGD_GM,   "Intel(R) IGD")
-CHIPSET(0xA001, IGD_G,"Intel(R) IGD")
+CHIPSET(0xA011, PNV_GM,   "Intel(R) Pineview M")
+CHIPSET(0xA001, PNV_G,"Intel(R) Pineview")
diff --git a/hw/xfree86/dri2/pci_ids/i965_pci_ids.h 
b/hw/xfree86/dri2/pci_ids/i965_pci_ids.h
index 2e04301..5139e27 100644
--- a/hw/xfree86/dri2/pci_ids/i965_pci_ids.h
+++ b/hw/xfree86/dri2/pci_ids/i965_pci_ids.h
@@ -109,7 +109,55 @@ CHIPSET(0x162A, bdw_gt3, "Intel(R) Iris Pro P6300 
(Broadwell GT3e)")
 CHIPSET(0x162B, bdw_gt3, "Intel(R) Iris 6100 (Broadwell GT3)")
 CHIPSET(0x162D, bdw_gt3, "Intel(R) Broadwell GT3")
 CHIPSET(0x162E, bdw_gt3, "Intel(R) Broadwell GT3")
-CHIPSET(0x22B0, chv, "Intel(R) Cherryview")
-CHIPSET(0x22B1, chv, "Intel(R) Cherryview")
-CHIPSET(0x22B2, chv, "Intel(R) Cherryview")
-CHIPSET(0x22B3, chv, "Intel(R) Cherryview")
+CHIPSET(0x1902, skl_gt1, "Intel(R) HD Graphics 510 (Skylake GT1)")
+CHIPSET(0x1906, skl_gt1, "Intel(R) HD Graphics 510 (Skylake GT1)")
+CHIPSET(0x190A, skl_gt1, "Intel(R) Skylake GT1")
+CHIPSET(0x190E, skl_gt1, "Intel(R) Skylake GT1")
+CHIPSET(0x1912, skl_gt2, "Intel(R) HD Graphics 530 (Skylake GT2)")
+CHIPSET(0x1913, skl_gt2, "Intel(R) Skylake GT2f")
+CHIPSET(0x1915, skl_gt2, "Intel(R) Skylake GT2f")
+CHIPSET(0x1916, skl_gt2, "Intel(R) HD Graphics 520 (Skylake GT2)")
+CHIPSET(0x1917, skl_gt2, "Intel(R) Skylake GT2f")
+CHIPSET(0x191A, skl_gt2, "Intel(R) Skylake GT2")
+CHIPSET(0x191B, skl_gt2, "Intel(R) HD Graphics 530 (Skylake GT2)")
+CHIPSET(0x191D, skl_gt2, "Intel(R) HD Graphics P530 (Skylake GT2)")
+CHIPSET(0x191E, skl_gt2, "Intel(R) HD Graphics 515 (Skylake GT2)")
+CHIPSET(0x1921, skl_gt2, "Intel(R) Skylake GT2")
+CHIPSET(0x1923, skl_gt3, "Intel(R) Iris Graphics 540 (Skylake GT3e)")
+CHIPSET(0x1926, skl_gt3, "Intel(R) HD Graphics 535 (Skylake GT3)")
+CHIPSET(0x1927, skl_gt3, "Intel(R) Iris Graphics 550 (Skylake GT3e)")
+CHIPSET(0x192A, skl_gt4, "Intel(R) Skylake GT4")
+CHIPSET(0x192B, skl_gt3, "Intel(R) Iris Graphics (Skylake GT3fe)")
+CHIPSET(0x1932, skl_gt4, "Intel(R) Skylake GT4")
+CHIPSET(0x193A, skl_gt4, "Intel(R) Skylake GT4")
+CHIPSET(0x193B, skl_gt4, "Intel(R) Skylake GT4")
+CHIPSET(0x193D, skl_gt4, "Intel(R) Skylake GT4")
+CHIPSET(0x5902, kbl_gt1, "Intel(R) Kabylake GT1")
+CHIPSET(0x5906, kbl_gt1, "Intel(R) Kabylake GT1")
+CHIPSET(0x590A, kbl_gt1, "Intel(R) Kabylake GT1")
+CHIPSET(0x590B, kbl_gt1, "Intel(R) Kabylake GT1")
+CHIPSET(0x590E, kbl_gt1, "Intel(R) Kabylake GT1")
+CHIPSET(0x5913, kbl_gt1_5, "Intel(R) Kabylake GT1.5")
+CHIPSET(0x5915, kbl_gt1_5, "Intel(R) Kabylake GT1.5")
+CHIPSET(0x5917, kbl_gt1_5, "Intel(R) Kabylake GT1.5")
+CHIPSET(0x5912, kbl_gt2, "Intel(R) Kabylake GT2")
+CHIPSET(0x5916, kbl_gt2, "Intel(R) Kabylake GT2")
+CHIPSET(0x591A, kbl_gt2, "Intel(R) Kabylake GT2")
+CHIPSET(0x591B, kbl_gt2, "Intel(R) Kabylake GT2")
+CHIPSET(0x591D, kbl_gt2, "Intel(R) Kabylake GT2")
+CHIPSET(0x591E, kbl_gt2, "Intel(R) Kabylake GT2")
+CHIPSET(0x5921, kbl_gt2, "Intel(R) Kabylake GT2F")
+CHIPSET(0x5926, kbl_gt3, "Intel(R) Kabylake GT3")
+CHIPSET(0x592A, kbl_gt3, "Intel(R) Kabylake GT3")
+CHIPSET(0x592B, kbl_gt3, "Intel(R) Kabylake GT3")
+CHIPSET(0x5932, kbl_gt4, "Intel(R) Kabylake GT4")
+CHIPSET(0x593A, kbl_gt4, "Intel(R) Kabylake GT4")
+CHIPSET(0x593B, kbl_gt4, "Intel(R) Kabylake GT4")
+CHIPSET(0x593D, kbl_gt4, "Intel(R) Kabylake GT4")
+CHIPSET(0x22B0, chv, "Intel(R) HD Graphics (Cherryview)")
+CHIPSET(0x22B1, chv, "Intel(R) HD Graphics (Cherryview)")
+CHIPSET(0x22B2, chv, "Intel(R) HD Graphics (Cherryview)")
+CHIPSET(0x22B3, chv, "Intel(R) HD Graphics (Cherryview)")
+CHIPSET(0x0A84, bxt, "Intel(R) HD Graphics (Broxton)")
+CHIPSET(0x1A84, bxt, "Intel(R) HD Graphics (Broxton)")
+CHIPSET(0x5A84, bxt, "Intel(R) HD Graphics (Broxton)")
-- 
2.5.0

___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel

Re: [PATCH xserver 2/2] glamor: Source pictures are always depth 32

2016-03-10 Thread Timo Aaltonen
08.03.2016, 22:18, Adam Jackson kirjoitti:
> On Tue, 2016-02-23 at 17:19 +0900, Michel Dänzer wrote:
>> From: Michel Dänzer 
>>
>> We were using the destination pixmap depth to determine the source
>> picture format.
>>
>> Fixes incorrect text rendering with some MATE desktop GTK3 themes.
>>
>> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=94246
>> Signed-off-by: Michel Dänzer 
> 
> remote: I: patch #74718 updated using rev 
> b05ae79ee3bebef9790c97eedc033d1ffb3ec39a.
> remote: I: patch #74719 updated using rev 
> a3e681eafa5355b8bb3b099d47983f14f0d5e197.
> remote: I: 2 patch(es) updated to state Accepted.
> To ssh://git.freedesktop.org/git/xorg/xserver
>947e94a..a3e681e  master -> master

Please add these for 1.18.x too, the first one needs a bit of
backporting unless a lot of glamor from master is pulled in.


-- 
t
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

Re: [PATCH] Fix XineramaQueryScreens for reverse prime

2016-03-10 Thread Timo Aaltonen
09.02.2016, 00:23, Adam Jackson kirjoitti:
> On Mon, 2016-02-08 at 14:17 +1000, Dave Airlie wrote:
>> On 4 February 2016 at 23:06, Jan Burgmeier
>>  wrote:
>>> Bugzilla: https://bugs.freedesktop.org/92313
>>
>> Reviewed-by: Dave Airlie 
>>
>> though it might be nice to have some more info from the bug in the
>> commit message.
> 
> Pushed with a slightly more detailed commit message:
> 
> To ssh://git.freedesktop.org/git/xorg/xserver
>87d5534..7bb64d8  master -> master

Please add this to 1.18.x, nvidia hybrids are quite unhappy without it.


-- 
t
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

Re: [PATCH] glamor: swizzle RED to 0 for alpha textures.

2016-03-15 Thread Timo Aaltonen
16.03.2016, 02:45, Dave Airlie kirjoitti:
> From: Dave Airlie <airl...@redhat.com>
> 
> I'm pretty sure Eric suspected this could cause a problem, and
> we couldn't find a test. Well loading feedly in firefox seems
> to trigger badness that this solves.
> 
> bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=94554
> Signed-off-by: Dave Airlie <airl...@redhat.com>

works great, thanks

Tested-by: Timo Aaltonen <tjaal...@ubuntu.com>


-- 
t
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

Re: [PATCH xserver] randr: Do not check the screen size bound for gpu screens

2016-08-31 Thread Timo Aaltonen

Any update on this?

On 20.06.2016 20:27, Hans de Goede wrote:
> Hi,
> 
> On 20-06-16 18:32, Nikhil Mahale wrote:
>> Sorry for late reply, Hans. See inline -
>>
>> On 06/13/2016 10:36 PM, Hans de Goede wrote:
>>> Hi,
>>>
>>> On 20-05-16 07:00, Nikhil Mahale wrote:
 For gpu screen, CrtcSet set/adjust the master screen size along
 mode in following callstack -

   ProcRRSetCrtcConfig()
 |
 -> RRCrtcSet()
 |
 -> rrCheckPixmapBounding()
 |
 -> pScrPriv->rrScreenSetSize()

 Checking screen size bound for gpus screen cause some configurations
 to fails, e.g

   $ xrandr --output eDP --mode 1920x1080 --pos 0x0 --output HDMI \
   --mode 2560x1440 --pos 0x0

   Here xrandr utility first sets screen size to 2560x1440 which
   gets resized to 1920x1080 on RRSetCrtcConfig request for eDP,
   and then RRSetCrtcConfig request for HDMI fails because
   of failure of screen bound check.
>>>
>>> Hmm, but one has the same problem when not using clone mode,
>>> then the master screen size must be made big enough to hold
>>> both crtc-s, so how come this has never been a problem then ?
>>>
>>> I've a feeling that in that case we end up doing things in
>>> finer grained steps. What if you do:
>>>
>>> $ xrandr --output eDP --mode 1920x1080 --pos 0x0
>>> $ xrandr --output HDMI --mode 2560x1440 --pos 0x0
>>>
>>> ? Does that work ?  If that works, which I would expect it will,
>>> then this should be fixed in the xrandr utility instead IMHO.
>>>
>>> Just circumventing the screen size check for slave outputs
>>> seem to go against the xrandr-1.2 spec to me.
>>>
>>> Also I guess one can reproduce the same problem without using
>>> slave-outputs, in which case your patch will not help.
>>>
>>
>> I don't think we could reproduce this problem without using slave-
>> output, because rrScreenSetSize() path which I explained in commit
>> message is not there, isn't it?
>>
>> Let me try to explain differece between both sequence of commands,
>> please correct me if required -
>>
>> $ xrandr --output eDP --mode 1920x1080 --pos 0x0 --output HDMI \
>> --mode 2560x1440 --pos 0x0
>>
>> ---
>> | Cmd | Screen size  |  eDP  | HDMI   |
>> ---
>> | RRSetScreenSize | 2560x1440| - |   -|
>> ---
>> | RRSetCrtcConfig | 1920x1080| 1920x1080 |   -|
>> | | changed from 2560x1440   |   ||
>> | | because of rrScreenSetSize() |   ||
>> | | path explained in commit |   ||
>> | | msg. (A) |   ||
>> ---
>> | RRSetCrtcConfig | 2560x1440| 1920x1080 | failed |
>> ---
> 
> Ah I see now, this will only happen when the eDP is a slave output,
> I was thinking that the HDMI would be a slave output, but that does
> not matter, this problem will happen independ of the HDMI being a normal
> or a slave output, as long as the eDP is a slave output.
> 
>> $ xrandr --output eDP --mode 1920x1080 --pos 0x0
>> $ xrandr --output HDMI --mode 2560x1440 --pos 0x0
>>
>>
>> 
>> | Cmd | Screen size|  eDP  | HDMI  |
>> 
>> | RRSetScreenSize | 1920x1080  | - |   -   |
>> 
>> | RRSetCrtcConfig | 1920x1080  | 1920x1080 |   -   |
>> 
>> | RRSetScreenSize | 2560x1440  | 1920x1080 |   -   |
>> 
>> | RRSetCrtcConfig | 2560x1440  | 1920x1080 | 2560x1440 |
>> 
>>
>> Case (A) is not there in second sequence of xrand commands, so you
>> could not reproduce problem.
> 
> Right, so you can get things to work without requiring a server change,
> iow this may be considered a xrandr utility bug, it could reproduce the
> sequence used in your second table, instead of skipping the second
> RRSetScreenSize.
> 
> OTOH this may indeed be a server bug, but your fix is not the right
> one, I wonder why we are doing a RRSetScreenSize for slave GPU-s at
> all. Since we already check that the Screen is big enough in
> ProcRRSetCrtcConfig?
> 
> I 

Re: Proposed X server 1.19 schedule

2016-09-13 Thread Timo Aaltonen
On 09.09.2016 20:18, Aaron Plattner wrote:
> On 09/06/2016 12:27 PM, Keith Packard wrote:
>> Adam Jackson  writes:
>>
>>> ... move the non-critical bug deadline to 2016-10-01? Still leaves
>>> three weeks for critical fixes. Either way, looks plausible to me. I
>>> don't personally have any non-bug changes I want to land before 1.19.
>>
>> Yeah, sounds good. We don't usually get many changes during the critical
>> bug window anyways.
> 
> When do you want to freeze the ABI? It would be good to get Alex's prime
> sync changes in an official ABI and run through our QA test cycle before
> the release.

that was merged on Jun 28th.


-- 
t
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

Re: [Spice-devel] [PATCH xf86-video-qxl] Adjust xspice_wakeup_handler() prototype for building xspice with server 1.19

2016-11-18 Thread Timo Aaltonen
On 04.10.2016 14:41, Hans de Goede wrote:
> Hi,
> 
> On 03-10-16 12:04, Christophe Fergeau wrote:
>>
>>
>> On Thu, Sep 29, 2016 at 01:03:01PM +0200, Hans de Goede wrote:
>>> Signed-off-by: Hans de Goede 
>>> ---
>>>  src/spiceqxl_main_loop.c | 4 
>>>  1 file changed, 4 insertions(+)
>>>
>>> diff --git a/src/spiceqxl_main_loop.c b/src/spiceqxl_main_loop.c
>>> index db89b6d..0ac1f3e 100644
>>> --- a/src/spiceqxl_main_loop.c
>>> +++ b/src/spiceqxl_main_loop.c
>>> @@ -330,7 +330,11 @@ static int no_write_watches(Ring *w)
>>>  return 1;
>>>  }
>>>
>>> +#if ABI_VIDEODRV_VERSION >= SET_ABI_VERSION(23, 0)
>>
>> We have an occurrence of
>> #if GET_ABI_MAJOR(ABI_VIDEODRV_VERSION) < 6
>> I'd use this here too to stay consistent (I assume they are equivalent
>> here).
>>
>> Acked-by: Christophe Fergeau 
> 
> Sorry, but this patch turns out to be incomplete, self NACK.
> 
> I just saw that spiceqxl_main_loop also uses a BlockHandler
> (xspice_block_handler) and expects to be able to add
> fds to watch for read activity through the xserver mainloop
> by treating the 3th argument as a FD_SET.
> 
> This is no longer supported as of xserver 1.19, instead
> the new NotifyFD functionality should be used. The advantage
> of this is that it can also properly watch fds for them
> becoming ready for writing.
> 
> For an example patch of how to use the new NotifyFD
> functionality see the recent tigervnc patch to make
> tigervnc work with 1.19:
> 
> https://lists.x.org/archives/xorg-devel/2016-October/051482.html

Any update here? Looks like you still have the original patch in Fedora ;)

A new release with this fixed would be great.


-- 
t
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

[PATCH xserver] dri2: Sync i965_pci_ids.h from mesa

2016-11-02 Thread Timo Aaltonen
Import changes from these mesa commits:
85ea8deb26da420 i965: Removing PCI IDs that are no longer listed as Kabylake.
bdff2e554735ed9 i956: Add more Kabylake PCI IDs.
f1fa8b4a1ca73fa i965/bxt: Add 2x6 variant
d1ab544bb883d04 i965/chv: Display proper branding
20e8ee36627f874 i965/skl: Update Skylake renderer strings
644c8a515192d28 i965/skl: Add two missing device IDs

Signed-off-by: Timo Aaltonen <tjaal...@ubuntu.com>
---
 hw/xfree86/dri2/pci_ids/i965_pci_ids.h | 32 +---
 1 file changed, 17 insertions(+), 15 deletions(-)

diff --git a/hw/xfree86/dri2/pci_ids/i965_pci_ids.h 
b/hw/xfree86/dri2/pci_ids/i965_pci_ids.h
index 5139e27..1566afd 100644
--- a/hw/xfree86/dri2/pci_ids/i965_pci_ids.h
+++ b/hw/xfree86/dri2/pci_ids/i965_pci_ids.h
@@ -112,6 +112,7 @@ CHIPSET(0x162E, bdw_gt3, "Intel(R) Broadwell GT3")
 CHIPSET(0x1902, skl_gt1, "Intel(R) HD Graphics 510 (Skylake GT1)")
 CHIPSET(0x1906, skl_gt1, "Intel(R) HD Graphics 510 (Skylake GT1)")
 CHIPSET(0x190A, skl_gt1, "Intel(R) Skylake GT1")
+CHIPSET(0x190B, skl_gt1, "Intel(R) HD Graphics 510 (Skylake GT1)")
 CHIPSET(0x190E, skl_gt1, "Intel(R) Skylake GT1")
 CHIPSET(0x1912, skl_gt2, "Intel(R) HD Graphics 530 (Skylake GT2)")
 CHIPSET(0x1913, skl_gt2, "Intel(R) Skylake GT2f")
@@ -122,19 +123,21 @@ CHIPSET(0x191A, skl_gt2, "Intel(R) Skylake GT2")
 CHIPSET(0x191B, skl_gt2, "Intel(R) HD Graphics 530 (Skylake GT2)")
 CHIPSET(0x191D, skl_gt2, "Intel(R) HD Graphics P530 (Skylake GT2)")
 CHIPSET(0x191E, skl_gt2, "Intel(R) HD Graphics 515 (Skylake GT2)")
-CHIPSET(0x1921, skl_gt2, "Intel(R) Skylake GT2")
-CHIPSET(0x1923, skl_gt3, "Intel(R) Iris Graphics 540 (Skylake GT3e)")
-CHIPSET(0x1926, skl_gt3, "Intel(R) HD Graphics 535 (Skylake GT3)")
+CHIPSET(0x1921, skl_gt2, "Intel(R) HD Graphics 520 (Skylake GT2)")
+CHIPSET(0x1923, skl_gt3, "Intel(R) Skylake GT3e")
+CHIPSET(0x1926, skl_gt3, "Intel(R) Iris Graphics 540 (Skylake GT3e)")
 CHIPSET(0x1927, skl_gt3, "Intel(R) Iris Graphics 550 (Skylake GT3e)")
 CHIPSET(0x192A, skl_gt4, "Intel(R) Skylake GT4")
-CHIPSET(0x192B, skl_gt3, "Intel(R) Iris Graphics (Skylake GT3fe)")
-CHIPSET(0x1932, skl_gt4, "Intel(R) Skylake GT4")
-CHIPSET(0x193A, skl_gt4, "Intel(R) Skylake GT4")
-CHIPSET(0x193B, skl_gt4, "Intel(R) Skylake GT4")
-CHIPSET(0x193D, skl_gt4, "Intel(R) Skylake GT4")
+CHIPSET(0x192B, skl_gt3, "Intel(R) Iris Graphics 555 (Skylake GT3e)")
+CHIPSET(0x192D, skl_gt3, "Intel(R) Iris Graphics P555 (Skylake GT3e)")
+CHIPSET(0x1932, skl_gt4, "Intel(R) Iris Pro Graphics 580 (Skylake GT4e)")
+CHIPSET(0x193A, skl_gt4, "Intel(R) Iris Pro Graphics P580 (Skylake GT4e)")
+CHIPSET(0x193B, skl_gt4, "Intel(R) Iris Pro Graphics 580 (Skylake GT4e)")
+CHIPSET(0x193D, skl_gt4, "Intel(R) Iris Pro Graphics P580 (Skylake GT4e)")
 CHIPSET(0x5902, kbl_gt1, "Intel(R) Kabylake GT1")
 CHIPSET(0x5906, kbl_gt1, "Intel(R) Kabylake GT1")
 CHIPSET(0x590A, kbl_gt1, "Intel(R) Kabylake GT1")
+CHIPSET(0x5908, kbl_gt1, "Intel(R) Kabylake GT1")
 CHIPSET(0x590B, kbl_gt1, "Intel(R) Kabylake GT1")
 CHIPSET(0x590E, kbl_gt1, "Intel(R) Kabylake GT1")
 CHIPSET(0x5913, kbl_gt1_5, "Intel(R) Kabylake GT1.5")
@@ -147,17 +150,16 @@ CHIPSET(0x591B, kbl_gt2, "Intel(R) Kabylake GT2")
 CHIPSET(0x591D, kbl_gt2, "Intel(R) Kabylake GT2")
 CHIPSET(0x591E, kbl_gt2, "Intel(R) Kabylake GT2")
 CHIPSET(0x5921, kbl_gt2, "Intel(R) Kabylake GT2F")
+CHIPSET(0x5923, kbl_gt3, "Intel(R) Kabylake GT3")
 CHIPSET(0x5926, kbl_gt3, "Intel(R) Kabylake GT3")
-CHIPSET(0x592A, kbl_gt3, "Intel(R) Kabylake GT3")
-CHIPSET(0x592B, kbl_gt3, "Intel(R) Kabylake GT3")
-CHIPSET(0x5932, kbl_gt4, "Intel(R) Kabylake GT4")
-CHIPSET(0x593A, kbl_gt4, "Intel(R) Kabylake GT4")
+CHIPSET(0x5927, kbl_gt3, "Intel(R) Kabylake GT3")
 CHIPSET(0x593B, kbl_gt4, "Intel(R) Kabylake GT4")
-CHIPSET(0x593D, kbl_gt4, "Intel(R) Kabylake GT4")
-CHIPSET(0x22B0, chv, "Intel(R) HD Graphics (Cherryview)")
-CHIPSET(0x22B1, chv, "Intel(R) HD Graphics (Cherryview)")
+CHIPSET(0x22B0, chv, "Intel(R) HD Graphics (Cherrytrail)")
+CHIPSET(0x22B1, chv, "Intel(R) HD Graphics XXX (Braswell)") /* Overridden 
in brw_get_renderer_string */
 CHIPSET(0x22B2, chv, "Intel(R) HD Graphics (Cherryview)")
 CHIPSET(0x22B3, chv, "Intel(R) HD Graphics (Cherryview)")
 CHIPSET(0x0A84, bxt, "Intel(R) HD Graphics (Broxton)")
 CHIPSET(0x1A84, bxt, "Intel(R) HD Graphics (Broxton)")
+CHIPSET(0x1A85, bxt_2x6, "Intel(R) HD Graphics (Broxton 2x6)")
 CHIPSET(0x5A84, bxt, "Intel(R) HD Graphics (Broxton)")
+CHIPSET(0x5A85, bxt_2x6, "Intel(R) HD Graphics (Broxton 2x6)")
-- 
2.7.4

___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

Re: [PATCH xserver] modesetting: Honor xorg.conf for 16bpp

2017-03-23 Thread Timo Aaltonen
On 21.03.2017 21:57, Adam Jackson wrote:
> The 32->24 support patch messed this up.
> 
> Bugzilla: https://bugs.freedesktop.org/100246
> Bugzilla: https://bugs.freedesktop.org/100295
> Signed-off-by: Adam Jackson 

'xinit -- -depth 16' still doesn't work, but xorg.conf does.


-- 
t
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

[PATCH 4/4] dix: Resize touch event history if the array is filled up

2017-03-16 Thread Timo Aaltonen
From: Maarten Lankhorst 

Signed-off-by: Maarten Lankhorst 
---
 dix/touch.c | 18 --
 1 file changed, 16 insertions(+), 2 deletions(-)

diff --git a/dix/touch.c b/dix/touch.c
index 37902bd..efc7ef9 100644
--- a/dix/touch.c
+++ b/dix/touch.c
@@ -430,11 +430,25 @@ TouchEventHistoryPush(TouchPointInfoPtr ti, const 
DeviceEvent *ev)
 if (ev->flags & (TOUCH_CLIENT_ID | TOUCH_REPLAYING))
 return;
 
+if (ti->history_elements == ti->history_size - 1) {
+DeviceEvent *hist = NULL;
+size_t sz = ti->history_size * 2;
+
+if (sz < 1) {
+hist = realloc(ti->history, sz * sizeof(*hist));
+
+if (hist) {
+ti->history = hist;
+ti->history_size = sz;
+memset([sz/2], 0, sizeof(*hist)*sz/2);
+}
+}
+}
+
 ti->history[ti->history_elements++] = *ev;
-/* FIXME: proper overflow fixes */
 if (ti->history_elements > ti->history_size - 1) {
 ti->history_elements = ti->history_size - 1;
-DebugF("source device %d: history size %zu overflowing for touch %u\n",
+ErrorF("source device %d: history size %zu overflowing for touch %u\n",
ti->sourceid, ti->history_size, ti->client_id);
 }
 }
-- 
2.7.4

___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

[PATCH 2/4] xfree86: Only set RR caps that are appropriate to main/gpu screen.

2017-03-16 Thread Timo Aaltonen
From: Maarten Lankhorst 

Ubuntu bug https://launchpad.net/bugs/1277014

Signed-off-by: Maarten Lankhorst 
---
 hw/xfree86/modes/xf86RandR12.c | 8 +++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/hw/xfree86/modes/xf86RandR12.c b/hw/xfree86/modes/xf86RandR12.c
index d834619..6d6977f 100644
--- a/hw/xfree86/modes/xf86RandR12.c
+++ b/hw/xfree86/modes/xf86RandR12.c
@@ -1671,10 +1671,16 @@ xf86RandR12CreateObjects12(ScreenPtr pScreen)
 }
 
 if (config->name) {
+uint32_t caps = pScrn->capabilities;
 config->randr_provider = RRProviderCreate(pScreen, config->name,
   strlen(config->name));
 
-RRProviderSetCapabilities(config->randr_provider, pScrn->capabilities);
+if (!pScreen->isGPU)
+caps &= RR_Capability_SinkOffload | RR_Capability_SourceOutput;
+else
+caps &= RR_Capability_SourceOffload | RR_Capability_SinkOutput;
+
+RRProviderSetCapabilities(config->randr_provider, caps);
 }
 
 return TRUE;
-- 
2.7.4

___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

[PATCH 1/4] xfree86: Don't bother probing -nv on Linux

2017-03-16 Thread Timo Aaltonen
From: Timo Aaltonen <tjaal...@debian.org>

For linux this driver is long obsolete now.  It may have some relevance
on non-linux systems.

Signed-off-by: Timo Aaltonen <tjaal...@ubuntu.com>
---
 hw/xfree86/common/xf86pciBus.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/hw/xfree86/common/xf86pciBus.c b/hw/xfree86/common/xf86pciBus.c
index 9adfee5..66e576e 100644
--- a/hw/xfree86/common/xf86pciBus.c
+++ b/hw/xfree86/common/xf86pciBus.c
@@ -1195,8 +1195,9 @@ xf86VideoPtrToDriverList(struct pci_device *dev,
 
 #ifdef __linux__
 driverList[idx++] = "nouveau";
-#endif
+#else
 driverList[idx++] = "nv";
+#endif
 break;
 }
 case 0x1106:
-- 
2.7.4

___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

[PATCH 3/4] xfree86: Do not bother registering xv/xvmc on gpu screens

2017-03-16 Thread Timo Aaltonen
From: Maarten Lankhorst 

Signed-off-by: Maarten Lankhorst 
---
 hw/xfree86/common/xf86xv.c   |  2 +-
 hw/xfree86/common/xf86xvmc.c | 10 +++---
 2 files changed, 8 insertions(+), 4 deletions(-)

diff --git a/hw/xfree86/common/xf86xv.c b/hw/xfree86/common/xf86xv.c
index d613d71..17f7214 100644
--- a/hw/xfree86/common/xf86xv.c
+++ b/hw/xfree86/common/xf86xv.c
@@ -230,7 +230,7 @@ xf86XVScreenInit(ScreenPtr pScreen, XF86VideoAdaptorPtr * 
adaptors, int num)
 ScrnInfoPtr pScrn;
 XF86XVScreenPtr ScreenPriv;
 
-if (num <= 0 || noXvExtension)
+if (num <= 0 || noXvExtension || pScreen->isGPU)
 return FALSE;
 
 if (Success != XvScreenInit(pScreen))
diff --git a/hw/xfree86/common/xf86xvmc.c b/hw/xfree86/common/xf86xvmc.c
index a0a94c7..9091a14 100644
--- a/hw/xfree86/common/xf86xvmc.c
+++ b/hw/xfree86/common/xf86xvmc.c
@@ -148,11 +148,15 @@ xf86XvMCScreenInit(ScreenPtr pScreen,
 {
 XvMCAdaptorPtr pAdapt;
 xf86XvMCScreenPtr pScreenPriv;
-XvScreenPtr pxvs = (XvScreenPtr) dixLookupPrivate(>devPrivates,
-  XF86XvScreenKey);
+XvScreenPtr pxvs;
 int i, j;
 
-if (noXvExtension)
+if (noXvExtension || pScreen->isGPU || !XF86XvScreenKey)
+return FALSE;
+
+pxvs = (XvScreenPtr) dixLookupPrivate(>devPrivates,
+  XF86XvScreenKey);
+if (!pxvs)
 return FALSE;
 
 if (!(pAdapt = xallocarray(num_adaptors, sizeof(XvMCAdaptorRec
-- 
2.7.4

___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

[PATCH xserver 0/4] Patches from Ubuntu

2017-03-16 Thread Timo Aaltonen
Here are some patches that are actually upstreamable, and should have
been sent quite some time ago.

Maarten Lankhorst (3):
  Only set RR caps that are appropriate to main/gpu screen.
  Do not bother registering xv/xvmc on gpu screens
  Input: Resize touch event history if the array is filled up

Timo Aaltonen (1):
  Don't bother probing -nv on Linux

 dix/touch.c| 18 --
 hw/xfree86/common/xf86pciBus.c |  3 ++-
 hw/xfree86/common/xf86xv.c |  2 +-
 hw/xfree86/common/xf86xvmc.c   | 10 +++---
 hw/xfree86/modes/xf86RandR12.c |  8 +++-
 5 files changed, 33 insertions(+), 8 deletions(-)

-- 
2.7.4

___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

Re: [PATCH xserver v3] autobind GPUs to the screen

2017-03-16 Thread Timo Aaltonen
On 06.12.2016 16:22, Hans de Goede wrote:
> From: Dave Airlie <airl...@redhat.com>
> 
> This is a modified version of a patch we've been carry-ing in Fedora and
> RHEL for years now. This patch automatically adds secondary GPUs to the
> master as output sink / offload source making e.g. the use of
> slave-outputs just work, with requiring the user to manually run
> "xrandr --setprovideroutputsource" before he can hookup an external
> monitor to his hybrid graphics laptop.
> 
> There is one problem with this patch, which is why it was not upstreamed
> before. What to do when a secondary GPU gets detected really is a policy
> decission (e.g. one may want to autobind PCI GPUs but not USB ones) and
> as such should be under control of the Desktop Environment.
> 
> Unconditionally adding autobinding support to the xserver will result
> in races between the DE dealing with the hotplug of a secondary GPU
> and the server itself dealing with it.
> 
> However we've waited for years for any Desktop Environments to actually
> start doing some sort of autoconfiguration of secondary GPUs and there
> is still not a single DE dealing with this, so I believe that it is
> time to upstream this now.
> 
> To avoid potential future problems if any DEs get support for doing
> secondary GPU configuration themselves, the new autobind functionality
> is made optional. Since no DEs currently support doing this themselves it
> is enabled by default. When DEs grow support for doing this themselves
> they can disable the servers autobinding through the servers cmdline or a
> xorg.conf snippet.
> 
> Signed-off-by: Dave Airlie <airl...@gmail.com>
> [hdego...@redhat.com: Make configurable, fix with nvidia, submit upstream]
> Signed-off-by: Hans de Goede <hdego...@redhat.com>
> ---
> Changes in v2:
> -Make the default enabled instead of installing a xorg.conf
>  snippet which enables it unconditionally
> Changes in v3:
> -Handle GPUScreen autoconfig in randr/rrprovider.c, looking at
>  rrScrPriv->provider, rather then in hw/xfree86/modes/xf86Crtc.c
>  looking at xf86CrtcConfig->provider. This fixes the autoconfig not
>  working with the nvidia binary driver

Tested-by: Timo Aaltonen <tjaal...@ubuntu.com>

Ubuntu has had the old version for some years, and now this one works
with 1.19.x so would like to see it upstream.


-- 
t
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

[PATCH xf86-video-siliconmotion] Stop accessing the attribute array using the attribute name enum.

2017-03-09 Thread Timo Aaltonen
From: Robert Ancell 

The array has only two elements but the clamping code was assuming it contained
all the elements in order. This means no clamping is now done but at least it
wont read off the end of the array.

Signed-off-by: Robert Ancell 
---
 src/smi_video.c | 4 
 1 file changed, 4 deletions(-)

diff --git a/src/smi_video.c b/src/smi_video.c
index 27df68d..a13668e 100644
--- a/src/smi_video.c
+++ b/src/smi_video.c
@@ -681,10 +681,6 @@ SetAttr(ScrnInfoPtr pScrn, int i, int value)
 
 if (i < XV_ENCODING || i > XV_HUE)
return BadMatch;
-
-/* clamps value to attribute range */
-value = CLAMP(value, SMI_VideoAttributes[i].min_value,
- SMI_VideoAttributes[i].max_value);
 
 if (i == XV_BRIGHTNESS) {
int my_value = (value <= 128? value + 128 : value - 128);
-- 
2.5.0

___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

[PATCH] Fix build against xorg server 1.17 on certain architectures

2017-03-09 Thread Timo Aaltonen
From: Maarten Lankhorst 

Fixes at least arm64, likely also hppa, m68k, sh4.

Signed-off-by: Maarten Lankhorst 
---
 src/regsmi.h   | 18 ++
 src/smi.h  |  2 ++
 src/smi_driver.c   | 19 +--
 src/smilynx_crtc.c |  6 +++---
 src/smilynx_hw.c   |  5 ++---
 5 files changed, 34 insertions(+), 16 deletions(-)

diff --git a/src/regsmi.h b/src/regsmi.h
index 5dd0320..69205ba 100644
--- a/src/regsmi.h
+++ b/src/regsmi.h
@@ -64,8 +64,13 @@ VGAIN8_INDEX(SMIPtr pSmi, int indexPort, int dataPort, CARD8 
index)
MMIO_OUT8(pSmi->IOBase, indexPort, index);
return(MMIO_IN8(pSmi->IOBase, dataPort));
 } else {
+#ifdef XSERVER_LIBPCIACCESS
+   pci_io_write8(pSmi->io, indexPort, index);
+   return pci_io_read8(pSmi->io, dataPort);
+#else
outb(pSmi->PIOBase + indexPort, index);
return(inb(pSmi->PIOBase + dataPort));
+#endif
 }
 }
 
@@ -76,8 +81,13 @@ VGAOUT8_INDEX(SMIPtr pSmi, int indexPort, int dataPort, 
CARD8 index, CARD8 data)
MMIO_OUT8(pSmi->IOBase, indexPort, index);
MMIO_OUT8(pSmi->IOBase, dataPort, data);
 } else {
+#ifdef XSERVER_LIBPCIACCESS
+   pci_io_write8(pSmi->io, indexPort, index);
+   pci_io_write8(pSmi->io, dataPort, data);
+#else
outb(pSmi->PIOBase + indexPort, index);
outb(pSmi->PIOBase + dataPort, data);
+#endif
 }
 }
 
@@ -87,7 +97,11 @@ VGAIN8(SMIPtr pSmi, int port)
 if (pSmi->IOBase) {
return(MMIO_IN8(pSmi->IOBase, port));
 } else {
+#ifdef XSERVER_LIBPCIACCESS
+   return pci_io_read8(pSmi->io, port);
+#else
return(inb(pSmi->PIOBase + port));
+#endif
 }
 }
 
@@ -97,7 +111,11 @@ VGAOUT8(SMIPtr pSmi, int port, CARD8 data)
 if (pSmi->IOBase) {
MMIO_OUT8(pSmi->IOBase, port, data);
 } else {
+#ifdef XSERVER_LIBPCIACCESS
+   pci_io_write8(pSmi->io, port, data);
+#else
outb(pSmi->PIOBase + port, data);
+#endif
 }
 }
 
diff --git a/src/smi.h b/src/smi.h
index 2742c8d..1f20a2d 100644
--- a/src/smi.h
+++ b/src/smi.h
@@ -171,6 +171,8 @@ typedef struct
 pciVideoPtrPciInfo;/* PCI info vars */
 #ifndef XSERVER_LIBPCIACCESS
 PCITAG PciTag;
+#else
+struct pci_io_handle *io;
 #endif
 intChipset;/* Chip info, set using PCI
   above */
diff --git a/src/smi_driver.c b/src/smi_driver.c
index 8949cae..6bdf64d 100644
--- a/src/smi_driver.c
+++ b/src/smi_driver.c
@@ -446,6 +446,9 @@ SMI_PreInit(ScrnInfoPtr pScrn, int flags)
pSmi->PIOBase = hwp->PIOOffset;
 #else
pSmi->PIOBase = 0;
+#ifdef XSERVER_LIBPCIACCESS
+   pSmi->io = hwp->io;
+#endif
 #endif
 
xf86ErrorFVerb(VERBLEV, "\tSMI_PreInit vgaCRIndex=%x, vgaIOBase=%x, "
@@ -2022,16 +2025,14 @@ SMI_EnableMmio(ScrnInfoPtr pScrn)
vgaHWSetStdFuncs(hwp);
 
/* Enable linear mode */
-   outb(pSmi->PIOBase + VGA_SEQ_INDEX, 0x18);
-   tmp = inb(pSmi->PIOBase + VGA_SEQ_DATA);
+   tmp = VGAIN8_INDEX(pSmi, VGA_SEQ_INDEX, VGA_SEQ_DATA, 0x18);
pSmi->SR18Value = tmp;  /* PDR#521 */
-   outb(pSmi->PIOBase + VGA_SEQ_DATA, tmp | 0x11);
+   VGAOUT8_INDEX(pSmi, VGA_SEQ_INDEX, VGA_SEQ_DATA, 0x18, tmp | 0x11);
 
/* Enable 2D/3D Engine and Video Processor */
-   outb(pSmi->PIOBase + VGA_SEQ_INDEX, 0x21);
-   tmp = inb(pSmi->PIOBase + VGA_SEQ_DATA);
+   tmp = VGAIN8_INDEX(pSmi, VGA_SEQ_INDEX, VGA_SEQ_DATA, 0x21);
pSmi->SR21Value = tmp;  /* PDR#521 */
-   outb(pSmi->PIOBase + VGA_SEQ_DATA, tmp & ~0x03);
+   VGAOUT8_INDEX(pSmi, VGA_SEQ_INDEX, VGA_SEQ_DATA, 0x21, tmp & ~0x03);
 }
 
 LEAVE();
@@ -2050,12 +2051,10 @@ SMI_DisableMmio(ScrnInfoPtr pScrn)
vgaHWSetStdFuncs(hwp);
 
/* Disable 2D/3D Engine and Video Processor */
-   outb(pSmi->PIOBase + VGA_SEQ_INDEX, 0x21);
-   outb(pSmi->PIOBase + VGA_SEQ_DATA, pSmi->SR21Value);/* PDR#521 */
+   VGAOUT8_INDEX(pSmi, VGA_SEQ_INDEX, VGA_SEQ_DATA, 0x21, 
pSmi->SR21Value);/* PDR#521 */
 
/* Disable linear mode */
-   outb(pSmi->PIOBase + VGA_SEQ_INDEX, 0x18);
-   outb(pSmi->PIOBase + VGA_SEQ_DATA, pSmi->SR18Value);/* PDR#521 */
+   VGAOUT8_INDEX(pSmi, VGA_SEQ_INDEX, VGA_SEQ_DATA, 0x18, 
pSmi->SR18Value);/* PDR#521 */
 }
 
 LEAVE();
diff --git a/src/smilynx_crtc.c b/src/smilynx_crtc.c
index fb7183c..f4d8b4e 100644
--- a/src/smilynx_crtc.c
+++ b/src/smilynx_crtc.c
@@ -619,9 +619,9 @@ SMILynx_CrtcModeSet_bios(xf86CrtcPtr crtc,
 xf86ExecX86int10(pSmi->pInt10);
 
 /* Enable linear mode. */
-outb(pSmi->PIOBase + VGA_SEQ_INDEX, 0x18);
-tmp = inb(pSmi->PIOBase + VGA_SEQ_DATA);
-outb(pSmi->PIOBase + VGA_SEQ_DATA, tmp | 0x01);
+VGAOUT8(pSmi, VGA_SEQ_INDEX, 0x18);
+tmp = VGAIN8(pSmi, VGA_SEQ_DATA);
+

Re: [PATCH xf86-video-siliconmotion] Fix build against xorg server 1.17 on certain architectures

2017-03-09 Thread Timo Aaltonen

bah, this is for xf86-video-siliconmotion

-- 
t
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

Re: Pull request for server-1.19.branch fixes ?

2017-10-01 Thread Timo Aaltonen
On 21.09.2017 17:21, Olivier Fourdan wrote:
> Hi all,
> 
> It appears the Xserver in 1.19 branch is missing quite a few fixes from 
> master, so I prepared a branch back-porting fixes at

Hi, please add this to the list:

commit fbd80b2c8ebe9fd41229dc5438524d107c071ff1
Author: Dawid Kurek 
Date:   Thu Jul 6 14:51:11 2017 +0200

modesetting: Blacklist EVDI devices from PRIME sync



-- 
t
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

[PULL] branch for 1.19.7

2018-02-13 Thread Timo Aaltonen

Hi

So here's a branch with the OutputClass commits backported, plus one animcur
commit which was missing from the others that already got cherry-picked?
(and I got asked to backport for Ubuntu..)


The following changes since commit 56547b196660e246e37132960723819972b99c8c:

  glx: Only assign 8 bpc fbconfigs for composite visuals. (2018-02-12 14:53:52 
-0500)

are available in the git repository at:

  git://people.freedesktop.org/~tjaalton/xserver for-1.19

for you to fetch changes up to e69c7fd6840e7e18061c7dfee1197e60e919bddb:

  animcur: Handle allocation failure for the animation timer (2018-02-13 
10:39:53 +0200)


Adam Jackson (1):
  animcur: Handle allocation failure for the animation timer

Hans De Goede (6):
  xfree86: Free devlist returned by xf86MatchDevice
  xfree86: Make OutputClassMatches take a xf86_platform_device
  xfree86: Add options support for OutputClass Options
  xfree86: xf86platformProbe: split finding pci-info and setting primary GPU
  xfree86: Allow overriding primary GPU detection from an OutputClass 
section
  xfree86: Add ModulePath support for OutputClass config Sections

Hans de Goede (3):
  xfree86: Remove redundant ServerIsNotSeat0 check from xf86CallDriverProbe
  xfree86: Make adding unclaimed devices as GPU devices a separate step
  xfree86: Try harder to find atleast 1 non GPU Screen

 hw/xfree86/common/xf86.h|   1 +
 hw/xfree86/common/xf86Bus.c |  32 +---
 hw/xfree86/common/xf86Globals.c |   1 +
 hw/xfree86/common/xf86Option.c  |   5 ++-
 hw/xfree86/common/xf86pciBus.c  |   4 ++
 hw/xfree86/common/xf86platformBus.c | 137 
++--
 hw/xfree86/common/xf86platformBus.h |   8 
 hw/xfree86/loader/loadmod.c |   1 +
 hw/xfree86/man/xorg.conf.man|  36 ++
 hw/xfree86/parser/OutputClass.c |  21 +++
 hw/xfree86/parser/xf86Parser.h  |   2 +
 render/animcur.c|  10 +++--
 12 files changed, 237 insertions(+), 21 deletions(-)


-- 
t
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

Re: [PULL] branch for 1.19.7

2018-02-13 Thread Timo Aaltonen
Adam Jackson kirjoitti 13.02.2018 klo 22:55:
> On Tue, 2018-02-13 at 17:44 +0200, Timo Aaltonen wrote:
>>  Hi
>>
>> So here's a branch with the OutputClass commits backported, plus one animcur
>> commit which was missing from the others that already got cherry-picked?
>> (and I got asked to backport for Ubuntu..)
> 
> Yeah, I'd skipped that one because I think it covers a case we don't
> hit:
> 
> https://lists.freedesktop.org/archives/xorg-devel/2018-January/03.html
> 
> No harm in including it though.
> 
>>   xfree86: Add options support for OutputClass Options
> 
> This one, though, we can't do. It adds a field in the middle of a
> struct in xf86Parser.h, which is ABI.
> 
>>   xfree86: Add ModulePath support for OutputClass config Sections
> 
> Same with this one.

Bah, you're right, I didn't check for that.. too bad.

But a5e9bcad7ad should be good, and apparently does fix #37858 I'm told.

-- 
t
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

Re: [PATCH xserver] glx: Only assign 8 bpc fbconfigs for composite visuals.

2018-02-09 Thread Timo Aaltonen
On 07.02.2018 16:18, Mario Kleiner wrote:
> On 02/06/2018 08:04 PM, Adam Jackson wrote:
>> On Mon, 2018-02-05 at 11:25 +0100, Thomas Hellstrom wrote:
>>> On 02/05/2018 11:20 AM, Mario Kleiner wrote:
 Commit 91c42093b248 ("glx: Duplicate relevant fbconfigs for
 compositing visuals") adds many new depth 32 fbconfigs as
 composite visuals. On a X-Screen running at depth 24, this
 also adds bgra 10-10-10-2 fbconigs, as they also have
 config.rgbBits == 32, but these are not displayable on a
 depth 24 screen, leading to visually corrupted desktops
 under some compositors, e.g., fdo bug 104597 "Compton
 weird colors" when running compton with
 "compton --backend glx".

 Be more conservative for now and only select fbconfigs with
 8 bpc red, green, blue components for composite visuals.

 Fixes: 91c42093b248 ("glx: Duplicate relevant fbconfigs for
     compositing visuals")
 Bugzilla:
 https://urldefense.proofpoint.com/v2/url?u=https-3A__bugs.freedesktop.org_show-5Fbug.cgi-3Fid-3D104597=DwIBAg=uilaK90D4TOVoH58JNXRgQ=wnSlgOCqfpNS4d02vP68_E9q2BNMCwfD2OZ_6dCFVQQ=IbtkCrmjzJVhB0PdaE0y9A3Zqx2CEYhUPvtI6PeGSEo=6MOlztrQC3tRtcJvqesPVJ1ri_ILRWLMh-iZbrs7NJ0=

 Signed-off-by: Mario Kleiner 
 Cc: Thomas Hellstrom 
 Cc: Adam Jackson 
>>>
>>> Reviewed-by: Thomas Hellstrom 
>>
>> remote: I: patch #202588 updated using rev
>> bebcc8477c8070ade9dd4be7299c718baeab3d7a.
>> remote: I: 1 patch(es) updated to state Accepted.
>> To ssh://git.freedesktop.org/git/xorg/xserver
>>     98edb9a35e..bebcc8477c  master -> master
>>
>> - ajax
>>
> 
> Thanks for the review and merge. This also needs to get picked into the
> server 1.19 branch. Are there plans to tag a new 1.19.7 release soon?
> I'm worried that if spring distro updates like Ubuntu 18.04 LTS would
> ship with Mesa 18.0 + server 1.19.6, instead of a 1.19.7 with these
> fixes, the 10 bpc related issues and the new sRGB Intel DRI stuff could
> cause quite a bit of pain for distro users without the fixes in the 1.19
> branch, e.g., disappering menus in firefox and GNU/Octave under desktop
> composition, depending on the ddx in use and the phase of the moon.

1.19.7 would be nice, my wishlist would also include the OutputClass
commits from last year, but that might be pushing too far..



-- 
t
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

Re: [PULL] branch for 1.19.7

2018-02-15 Thread Timo Aaltonen
On 14.02.2018 18:54, Adam Jackson wrote:
> On Tue, 2018-02-13 at 23:53 +0200, Timo Aaltonen wrote:
>> Adam Jackson kirjoitti 13.02.2018 klo 22:55:
>>> On Tue, 2018-02-13 at 17:44 +0200, Timo Aaltonen wrote:
>>>>
>>>>   xfree86: Add options support for OutputClass Options
>>>
>>> This one, though, we can't do. It adds a field in the middle of a
>>> struct in xf86Parser.h, which is ABI.
>>>
>>>>   xfree86: Add ModulePath support for OutputClass config Sections
>>>
>>> Same with this one.
>>
>> Bah, you're right, I didn't check for that.. too bad.
> 
> We could take the patches if the fields were added at the end, I
> believe. Wouldn't be a straight cherry-pick but that's fine.

Okay, I've reset the branch fixing the two commits and marking them
"backported from commit .." instead of a cherry-pick.

and the default modes patch I mentioned was already on the stable
branch, so that's good.


-- 
t
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

Re: [PATCH xserver 0/3] Use DRM GetFB2 ioctl

2019-11-20 Thread Timo Aaltonen
On 23.3.2018 15.50, Daniel Stone wrote:
> Hi,
> This short patchset makes modesetting use the shiny, new, and completely
> not at all merged GetFB2 DRM ioctl:
> https://lists.freedesktop.org/archives/dri-devel/2018-March/170512.html
> 
> When starting Xorg with -background none, it uses GetFB to interrogate
> the current framebuffer, importing it into a Glamor texture so it can
> copy back to its own storage. Unfortunately, if your buffer was
> multi-planar (e.g. new Intel with auxiliary compression buffer), or just
> too exotic to be described without a modifier (etnaviv in tiled mode),
> GetFB fell short of what we actually needed.
> 
> GetFB2 is the equivalent to AddFB2 (or AddFB2WithModifiers; both the
> same from an ioctl point of view), so this ports modesetting to use that
> where available and use with more complex buffers.
> 
> The kernel ABI rules require positive review from real userspace (not
> random hacked-up libdrm tests) before merging. Given that, I'd
> appreciate someone taking a look at the use of GetFB2 here, and
> following up with a statement that they think the ABI is actually good
> and long-term usable for what Xorg needs. (Or, well, some kind of
> constructive criticism.)
> 
> Happy new-kernel-ABI Friday!
> 
> Cheers,
> Daniel

Hi,

Is there a second version of patches 2 & 3 somewhere? AIUI this would
need to land in xserver before the kernel patches can be accepted?


-- 
t
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

Re: RFC: Minimum meson version for xserver 20

2020-03-31 Thread Timo Aaltonen
On 30.3.2020 18.42, Michel Dänzer wrote:
> On 2020-03-30 5:23 p.m., Adam Jackson wrote:
>> Does anyone have strong opinions on this? I would really like to bump
>> to at least 0.49 for the position-independent executable support. If
>> not that, 0.47 gives us 'feature' support for build options, which
>> addresses the "should we enable this by default or not" question in a
>> consistent way.
> 
> Even stock Debian stable has 0.49.2 (backports has 0.52.1), so 0.49
> seems fair game.

Yup, and Ubuntu 20.04 will ship with (at least) 0.53.2 so as long as
that's fresh enough for backports in the next two years, I'm happy.


-- 
t
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel