Re: [PATCH] list.h: don't crash when removing an element from a NULL list

2012-07-04 Thread Peter Hutterer
On Wed, Jul 04, 2012 at 11:32:38PM -0700, Keith Packard wrote: > Peter Hutterer writes: > > > Signed-off-by: Peter Hutterer > > --- > > Keith, please merge this directly if you're happy with it. > > It looks fine, but I don't see any place that this actually matters in > current code? no, but

Re: [PATCH] list.h: don't crash when removing an element from a NULL list

2012-07-04 Thread Keith Packard
Peter Hutterer writes: > Signed-off-by: Peter Hutterer > --- > Keith, please merge this directly if you're happy with it. It looks fine, but I don't see any place that this actually matters in current code? (the more I see of these twisty list macros, the more I prefer open-coded lists though;

Re: [PATCH] Replace padlength tables with inline functions from misc.h

2012-07-04 Thread Peter Hutterer
On Mon, Jul 02, 2012 at 08:30:49PM -0700, Alan Coopersmith wrote: > Adds new function padding_for_int32() and uses existing pad_to_int32() > depending on required results. > > Signed-off-by: Alan Coopersmith > --- > > On 07/ 2/12 10:58 AM, Keith Packard wrote: > > (also, we should get rid of the

[PATCH] dix: make inputInfo.all_devices and all_master_devices real devices (#50641)

2012-07-04 Thread Peter Hutterer
These devices are used as placeholders for devices in passive grabs and replaced with the real device once the grab activates. The current static allocation means they don't have devPrivates allocated. If SELinux is enabled and a client registers a passive grab on XIAll(Master)Devices, this causes

[PATCH] list.h: don't crash when removing an element from a NULL list

2012-07-04 Thread Peter Hutterer
Signed-off-by: Peter Hutterer --- Keith, please merge this directly if you're happy with it. include/list.h |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/list.h b/include/list.h index 96c0bcb..d54a207 100644 --- a/include/list.h +++ b/include/list.h @@ -453,7 +45

Re: Extending the merge window until monday

2012-07-04 Thread Peter Hutterer
On Wed, Jul 04, 2012 at 03:55:16PM -0700, Keith Packard wrote: > > I'm a softy and you all know it... > > Dave Airlie is busy cleaning up the RandR changes for a bit of output > device hotplug fun; the basic X server changes are mostly reviewed, he's > just rewriting the protocol at the last minu

Re: [v2] [PATCH 1/1] XSELinux: When SELinux is enabled the xserver seg faults

2012-07-04 Thread Peter Hutterer
On Fri, Jun 15, 2012 at 02:00:02PM +0100, Richard Haines wrote: > Note: [v2] patch fixes indentation > > This patch was created using xorg-server-1.12.0 source. > > When using Fedora 17 with xorg-server-1.12.0 and SELinux is enabled > ('setsebool xserver_object_manager on') the xserver will not l

Extending the merge window until monday

2012-07-04 Thread Keith Packard
I'm a softy and you all know it... Dave Airlie is busy cleaning up the RandR changes for a bit of output device hotplug fun; the basic X server changes are mostly reviewed, he's just rewriting the protocol at the last minute after review of that. It'd be nice to get that into 1.13 as it's a cool

[PATCH v2 29/29] Replace padlength tables with inline functions from misc.h

2012-07-04 Thread Alan Coopersmith
Adds new function padding_for_int32() and uses existing pad_to_int32() depending on required results. Signed-off-by: Alan Coopersmith Reviewed-by: Keith Packard --- dix/dispatch.c |4 +--- include/misc.h | 14 ++ os/io.c |6 ++ randr/rrscreen.c |5 +---

[PATCH v2 26/29] Set padding bytes to 0 in WriteToClient

2012-07-04 Thread Alan Coopersmith
Clear them out when needed instead of leaving whatever values were present in previously sent messages. Signed-off-by: Alan Coopersmith Reviewed-by: Keith Packard --- os/io.c |6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/os/io.c b/os/io.c index b67a5f3..8d0e5cc 100

[PATCH v2 25/29] Use C99 designated initializers in dix registry

2012-07-04 Thread Alan Coopersmith
Signed-off-by: Alan Coopersmith --- dix/registry.c |4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/dix/registry.c b/dix/registry.c index e9c19b0..5bad0fd 100644 --- a/dix/registry.c +++ b/dix/registry.c @@ -286,7 +286,7 @@ LookupResourceName(RESTYPE resource) void dixR

[PATCH v2 28/29] ephyrGLXQueryServerString: Stop making an unused copy of server_string

2012-07-04 Thread Alan Coopersmith
ephyrGLXQueryServerString() carefully allocated a buffer padded to the word-aligned string length for sending to the client, copied the string to it, and then forgot to use it, potentially reading a few bytes of garbage past the end of the server_string buffer. Since WriteToClient already handles

[PATCH v2 22/29] Use C99 designated initializers in xf86 extension Replies

2012-07-04 Thread Alan Coopersmith
Signed-off-by: Alan Coopersmith --- hw/xfree86/dixmods/extmod/xf86dga2.c | 141 +++--- hw/xfree86/dixmods/extmod/xf86vmode.c | 211 ++--- hw/xfree86/dri/xf86dri.c | 112 - hw/xfree86/dri2/dri2ext.c | 99 +++

[PATCH v2 27/29] Initialize padding bits to 0 in ErrorConnMax()

2012-07-04 Thread Alan Coopersmith
Signed-off-by: Alan Coopersmith --- os/connection.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/os/connection.c b/os/connection.c index 3441472..721ad65 100644 --- a/os/connection.c +++ b/os/connection.c @@ -892,7 +892,7 @@ ErrorConnMax(XtransConnInfo trans_conn) {

[PATCH v2 24/29] Use C99 designated initializers in extension Events

2012-07-04 Thread Alan Coopersmith
Signed-off-by: Alan Coopersmith --- Xext/saver.c | 23 --- Xext/security.c |8 +-- Xext/shape.c | 21 +++--- Xext/shm.c| 16 ++--- Xext/sync.c | 18 ++---

[PATCH v2 20/29] Use C99 designated initializers in dmx Replies

2012-07-04 Thread Alan Coopersmith
Signed-off-by: Alan Coopersmith --- hw/dmx/dmx.c | 213 +++-- hw/dmx/glxProxy/glxcmds.c | 110 - hw/dmx/glxProxy/glxcmdsswap.c | 14 +-- hw/dmx/glxProxy/glxsingle.c | 40 4 files changed, 216 insertions(

[PATCH v2 23/29] Use C99 designated initializers in dix Events

2012-07-04 Thread Alan Coopersmith
Signed-off-by: Alan Coopersmith --- dix/colormap.c | 34 +- dix/devices.c| 34 +- dix/enterleave.c | 14 ++-- dix/events.c | 89 + dix/inpututils.c | 13 ++-- dix/property.c | 13 ++-- dix/selection.c | 10 +-- dix/swapreq.c|

[PATCH v2 19/29] Use C99 designated initializers in randr Replies

2012-07-04 Thread Alan Coopersmith
Signed-off-by: Alan Coopersmith --- randr/rrcrtc.c | 69 + randr/rrdispatch.c |9 ++-- randr/rrmode.c | 13 +++--- randr/rroutput.c | 42 +- randr/rrproperty.c | 32 +- randr/rrscreen.c | 124

[PATCH v2 17/29] Use C99 designated initializers in glx Replies

2012-07-04 Thread Alan Coopersmith
Signed-off-by: Alan Coopersmith --- glx/glxcmds.c | 102 +++-- glx/single2.c | 14 glx/single2swap.c | 14 3 files changed, 75 insertions(+), 55 deletions(-) diff --git a/glx/glxcmds.c b/glx/glxcmds.c index a688c8f..6

[PATCH v2 21/29] Use C99 designated initializers in Xephyr Replies

2012-07-04 Thread Alan Coopersmith
Signed-off-by: Alan Coopersmith --- hw/kdrive/ephyr/ephyrdriext.c | 113 + hw/kdrive/ephyr/ephyrglxext.c | 70 ++--- 2 files changed, 99 insertions(+), 84 deletions(-) diff --git a/hw/kdrive/ephyr/ephyrdriext.c b/hw/kdrive/ephyr/ephy

[PATCH v2 15/29] Use C99 designated initializers in Xinput Replies

2012-07-04 Thread Alan Coopersmith
Signed-off-by: Alan Coopersmith --- Xi/chgdctl.c| 10 +--- Xi/getbmap.c| 12 + Xi/getdctl.c| 10 +--- Xi/getfctl.c| 12 + Xi/getfocus.c | 10 +--- Xi/getkmap.c| 12 + Xi/getmmap.c

[PATCH v2 18/29] Use C99 designated initializers in xkb Replies

2012-07-04 Thread Alan Coopersmith
Signed-off-by: Alan Coopersmith --- xkb/xkb.c | 324 +++-- 1 file changed, 164 insertions(+), 160 deletions(-) diff --git a/xkb/xkb.c b/xkb/xkb.c index b21815c..ad837c8 100644 --- a/xkb/xkb.c +++ b/xkb/xkb.c @@ -181,13 +181,14 @@ ProcXkbUs

[PATCH v2 16/29] Use C99 designated initializers in various extension Replies

2012-07-04 Thread Alan Coopersmith
Signed-off-by: Alan Coopersmith --- composite/compext.c | 29 + damageext/damageext.c | 10 ++ dbe/dbe.c | 34 ++ record/record.c | 27 +++ render/render.c | 10 +---

[PATCH v2 12/29] Use C99 designated initializers in SendErrorToClient

2012-07-04 Thread Alan Coopersmith
Let the compiler worry about 0-filling the rest of the fields, instead of memsetting the whole struct and then going back to overwrite some of the fields. Signed-off-by: Alan Coopersmith Reviewed-by: Keith Packard --- dix/dispatch.c | 15 +++ 1 file changed, 7 insertions(+), 8 del

[PATCH v2 10/29] xf86dga2.c & xf86vmode.c: Move REQUEST_SIZE_MATCH checks before using stuff

2012-07-04 Thread Alan Coopersmith
Seems silly waiting to check if the client failed to send us enough bytes until after we've already tried using them. Signed-off-by: Alan Coopersmith --- hw/xfree86/dixmods/extmod/xf86dga2.c | 81 +++-- hw/xfree86/dixmods/extmod/xf86vmode.c | 12 ++--- 2 files ch

[PATCH v2 07/29] Bug 51375: Xorg doesn't set status for RRGetOutputInfo

2012-07-04 Thread Alan Coopersmith
From: Jaroslav Šmíd https://bugs.freedesktop.org/show_bug.cgi?id=51375 https://bugs.freedesktop.org/attachment.cgi?id=63397 Signed-off-by: Alan Coopersmith --- randr/rroutput.c |1 + 1 file changed, 1 insertion(+) diff --git a/randr/rroutput.c b/randr/rroutput.c index fd03aab..3662a5a 100

[PATCH v2 14/29] Use C99 designated initializers in Xext Replies

2012-07-04 Thread Alan Coopersmith
Signed-off-by: Alan Coopersmith --- Xext/bigreq.c | 11 ++--- Xext/dpms.c | 55 Xext/geext.c | 18 Xext/panoramiX.c | 78 ++ Xext/panoramiXprocs.c | 42 +++ Xext/saver.c

[PATCH v2 11/29] Use calloc to zero fill buffers being allocated for replies & events

2012-07-04 Thread Alan Coopersmith
Ensures padding bytes are zero-filled Signed-off-by: Alan Coopersmith Reviewed-by: Keith Packard --- Xext/sync.c |2 +- Xext/xf86bigfont.c|2 +- glx/glxcmds.c |4 ++-- hw/xfree86/dixmods/extmod/xf86vmode.c |2

[PATCH v2 13/29] Use C99 designated initializers in dix Replies

2012-07-04 Thread Alan Coopersmith
Signed-off-by: Alan Coopersmith --- dix/devices.c | 102 +++--- dix/dispatch.c | 214 +-- dix/dixfonts.c | 22 +++--- dix/events.c| 54 +++--- dix/extension.c | 22 +++--- dix/property.c | 62 ++

[PATCH v2 09/29] ProcRRListOutputProperties: skip atom walk if the list is empty

2012-07-04 Thread Alan Coopersmith
pAtoms is only allocated if numProps was non-zero, so move the walk through the property list to copy atoms to it inside the if (numProps) Signed-off-by: Alan Coopersmith --- randr/rrproperty.c | 12 +++- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/randr/rrproperty.c

[PATCH v2 08/29] ProcRRGetScreenInfo: swap configTimestamp as well

2012-07-04 Thread Alan Coopersmith
Signed-off-by: Alan Coopersmith --- randr/rrscreen.c |1 + 1 file changed, 1 insertion(+) diff --git a/randr/rrscreen.c b/randr/rrscreen.c index 0ec608c..47147d6 100644 --- a/randr/rrscreen.c +++ b/randr/rrscreen.c @@ -685,6 +685,7 @@ ProcRRGetScreenInfo(ClientPtr client) swaps(&rep

[PATCH v2 00/29] Reworking initializion of data sent to clients

2012-07-04 Thread Alan Coopersmith
Version 2 of this series reworks the patches as requested by Keith, making them easier to review & see the changes. Mostly this was done by removing the addition of new blocks and instead using either existing blocks or inline anonymous structs/unions. A number of other changes are split out in

[PATCH v2 06/29] Use temporary variables instead of parts of reply structures

2012-07-04 Thread Alan Coopersmith
When passing variable pointers to functions or otherwise doing long sequences to compute values for replies, create & use some new temporary variables, to allow for simpler initialization of reply structures in the following patches. Move memsets & other initializations to group with the rest of t

[PATCH v2 05/29] ProcQueryKeymap: rework logic around permission to copy key states

2012-07-04 Thread Alan Coopersmith
Always initialize to zero, and then if permission is granted, copy the current key state maps, instead of always copying and then zeroing out if permission was denied. Signed-off-by: Alan Coopersmith --- dix/devices.c | 16 +--- 1 file changed, 9 insertions(+), 7 deletions(-) diff

[PATCH v2 04/29] Core events: invert check for permission to copy key states

2012-07-04 Thread Alan Coopersmith
Always initialize to zero, and then if permission is granted, copy the current key state maps. Use memcpy instead of memmove for the copy, since we're always copying to a newly allocated event on the stack, so guaranteed not to overlap with the device map structure. Signed-off-by: Alan Coopersmi

[PATCH v2 03/29] Rework reply initialization in ProcGetProperty & NullPropertyReply

2012-07-04 Thread Alan Coopersmith
Don't need to pass an empty reply to NullPropertyReply, let it make it's own. Move reply initialization code in remaining replies in ProcGetProperty to group with the rest of the fields. (Prepares for coming C99 designated initializer conversion.) Signed-off-by: Alan Coopersmith --- dix/prop

[PATCH v2 02/29] Fix more poorly indented/wrapped comments & code

2012-07-04 Thread Alan Coopersmith
Signed-off-by: Alan Coopersmith --- Xext/shm.c|2 +- Xext/sync.c | 11 ++- Xi/exevents.c | 13 ++--- Xi/extinit.c |5 +++-- composite/compwindow.c|

[PATCH 3/9] glx: Implement GLX_ARB_create_context_profile

2012-07-04 Thread Ian Romanick
From: Ian Romanick Most of the infrastructure was already in place. This just adds: * Validate values specified with the GLX_CONTEXT_PROFILE_MASK_ARB attribute. * Select a DRI2 "api" based on the setting of GLX_CONTEXT_PROFILE_MASK_ARB. * Enable GLX_ARB_create_context_

[PATCH 9/9] glx/dri2: Enable GLX_ARB_create_context_robustness

2012-07-04 Thread Ian Romanick
From: Ian Romanick If the driver supports __DRI2_ROBUSTNESS, then enable GLX_ARB_create_cotnext_robustness as well. If robustness values are passed to glXCreateContextAttribsARB and the driver doesn't support __DRI2_ROBUSTNESS, existing drivers will already generate the correct error values (so

[PATCH 4/9] glx: Implement GLX_EXT_create_context_es2_profile

2012-07-04 Thread Ian Romanick
From: Ian Romanick This patch builds on the infrastucture put in place for GLX_ARB_create_context_profile. If GLX_CONTEXT_ES2_PROFILE_BIT_EXT is specified and the requested version is 2.0, create a context with the __DRI_API_GLES2 API. This change assumes that any DRI2 driver can handle (possib

[PATCH 7/9] glx: Track the reset notification strategy for a context

2012-07-04 Thread Ian Romanick
From: Ian Romanick Also require that the reset notification for a new context and the other context in the share group match. There isn't yet any way to specify a non-default reset notification strategy, but that will come. Signed-off-by: Ian Romanick --- glx/createcontext.c | 16 ++

[PATCH 2/9] glx: Implement GLX SetClientInfo2ARB protocol

2012-07-04 Thread Ian Romanick
From: Ian Romanick The protocol is almost identical to SetClientInfoARB. The only difference is the GL versions include an extra 4 bytes for the supported profile. Signed-off-by: Ian Romanick Reviewed-by: Dave Airlie --- glx/clientinfo.c | 27 --- 1 files changed, 2

[PATCH 5/9] glx: Reject creations of indirect contexts with unsupportable versions.

2012-07-04 Thread Ian Romanick
From: Ian Romanick Signed-off-by: Ian Romanick Reviewed-by: Dave Airlie --- glx/createcontext.c | 17 + 1 files changed, 17 insertions(+), 0 deletions(-) diff --git a/glx/createcontext.c b/glx/createcontext.c index 2ba0e18..205a919 100644 --- a/glx/createcontext.c +++ b/glx/

[PATCH 8/9] glx: Allow attributes and flags from GLX_ARB_create_context_robustness

2012-07-04 Thread Ian Romanick
From: Ian Romanick The assumtion is that if the underlying provider (e.g., glxdri2.c) doesn't support this extension, it will generate BadMatch for these flags and attributes. Signed-off-by: Ian Romanick --- glx/createcontext.c | 11 ++- 1 files changed, 10 insertions(+), 1 deletions

[PATCH 6/9] glx: Add extension string tracking for GLX_ARB_create_context_robustness

2012-07-04 Thread Ian Romanick
From: Ian Romanick Signed-off-by: Ian Romanick --- glx/extension_string.c |1 + glx/extension_string.h |1 + 2 files changed, 2 insertions(+), 0 deletions(-) diff --git a/glx/extension_string.c b/glx/extension_string.c index 2d550a9..ee9864e 100644 --- a/glx/extension_string.c +++ b/gl

[PATCH 0/9] GLX features and minor cleanups

2012-07-04 Thread Ian Romanick
Patches 1 through 5 have previously been posted. The only change to patch 1 is the commit message. Patches 6 through 9 add the framework for supporting GLX_ARB_create_context_robustness. Similar framework patches for Mesa have been sent to the mesa-dev list for review. We hope to have reset not

[PATCH 1/9] glx: Don't request prototypes for GL extension functions

2012-07-04 Thread Ian Romanick
From: Ian Romanick The server does not want GL extension prototypes. It never links with anything that could possibly provide implementations of these functions. It *is* the provide, and it does not provde these symbols. All this does is create hundreds of warnings like: incude/GL/glext.h:557

Re: [PATCH v2] Look for ModuleData only in appropriate library

2012-07-04 Thread Peter Hutterer
On Thu, Jun 28, 2012 at 05:17:12PM +0200, Michal Srb wrote: > LoaderSymbol calls dlsym with RTLD_DEFAULT pseudo handle making it search in > every loaded library. In addition glibc adds NODELETE flag to the library > containing the symbol. > > It's used in doLoadModule to locate ModuleData symbol,

Re: [PATCH] xfree86: add framework for provider support in ddx. (v2)

2012-07-04 Thread Keith Packard
Dave Airlie writes: > From: Dave Airlie > > This adds the framework for DDX provider support. > > v2: as per keithp's suggestion remove the xf86 provider object > and just store it in the toplevel object. > > Signed-off-by: Dave Airlie Looks good. Reviewed-by: Keith Packard -- keith.pack..

Re: [PULL] coverity fixes and sigito handling changes

2012-07-04 Thread Keith Packard
Peter Hutterer writes: > And I scooped up Michal's patch as well since it had two reviews > already. Thanks! > Michal Srb (1): > Look for ModuleData only in appropriate library > > Peter Hutterer (11): > xfree86: always enable SIGIO on OsVendorInit (#50957) > os: add OsBlockSI

[PATCH] xfree86: add framework for provider support in ddx. (v2)

2012-07-04 Thread Dave Airlie
From: Dave Airlie This adds the framework for DDX provider support. v2: as per keithp's suggestion remove the xf86 provider object and just store it in the toplevel object. Signed-off-by: Dave Airlie --- hw/xfree86/common/xf86str.h|4 +++ hw/xfree86/modes/xf86Crtc.c| 27

[PATCH] dri2: Pass AsyncSwap [swap_interval=0] requests to the drivers

2012-07-04 Thread Chris Wilson
Currently, the midlayer dri2 code intercepts swap_interval=0 (ala vblank_mode=0) SwapBuffers and converts it to a CopyRegion request. This prevents the backend from doing anything meaningful in this case and typically ends up being vsync'ed since the drivers cannot distinguish it from a regular Cop

Re: [PATCH 04/36] dix: introduce gpu screens. (v3)

2012-07-04 Thread Dave Airlie
On Wed, Jul 4, 2012 at 1:07 AM, Aaron Plattner wrote: > On 07/02/2012 03:12 AM, Dave Airlie wrote: >> >> From: Dave Airlie >> > >> diff --git a/render/glyph.c b/render/glyph.c >> index acb573f..c121e64 100644 >> --- a/render/glyph.c >> +++ b/render/glyph.c >> @@ -687,6 +687,8 @@ miGlyphs(CARD8 op

[PULL] coverity fixes and sigito handling changes

2012-07-04 Thread Peter Hutterer
And I scooped up Michal's patch as well since it had two reviews already. The following changes since commit 24525d96a3b9dba67eb75042500b2f208a2cc246: Merge branch 'sigsafe-logging-varargs' (2012-07-02 22:35:39 -0700) are available in the git repository at: git://people.freedesktop.org/~wh

Re: [PATCH xorg-gtest 09/16] environment: remove default settings

2012-07-04 Thread Peter Hutterer
On Tue, Jul 03, 2012 at 10:53:28AM -0700, Chase Douglas wrote: > On 07/02/2012 11:44 PM, Peter Hutterer wrote: > >Keep those in the server only, not the environment. And only override the > >build-in ones when they've been set by main. > > > >Signed-off-by: Peter Hutterer > >--- > > src/environme

Re: [PATCH] glx: Pass GLX drawable ID to DRI2CreateDrawable().

2012-07-04 Thread Michel Dänzer
On Fre, 2012-06-29 at 19:09 +0200, Michel Dänzer wrote: > On Fre, 2012-06-29 at 12:58 -0400, Kristian Høgsberg wrote: > > On Fri, Jun 29, 2012 at 12:30 PM, Michel Dänzer wrote: > > > On Fre, 2012-06-29 at 12:20 -0400, Kristian Høgsberg wrote: > > >> On Thu, Jun 28, 2012 at 7:39 AM, Michel Dänzer