Re: [PATCH] glx: Add _glapi_create_table_from_handle

2011-06-28 Thread Jon TURNEY

On 27/06/2011 18:38, Jeremy Huddleston wrote:

Those bits in the NoOp stub can be left out on Win32 (or you can tell me the 
Win32 way of figuring that out).  It's just used to provide extra info to give 
a hint as to which call was unimplemented.


Looking at this a bit more I notice that we already have the autoconf 
machinery to check if backtrace() is available, so let's use that, rather than 
trying to come up with a list of targets which have those functions.


There's no easy way to implement equivalent functionality to backtrace() on 
Win32, which is why cygwin doesn't have a backtrace() function yet :-)


Patch attached, although obviously it's the code generator for this file which 
should be fixed...



From a9a5b3b9b01c4258ca1f2d63b6a05efd2238ad5c Mon Sep 17 00:00:00 2001
From: Jon TURNEY jon.tur...@dronecode.org.uk
Date: Mon, 27 Jun 2011 15:06:16 +0100
Subject: [PATCH] Guard use of backtrace() with HAVE_BACKTRACE

Guard the use of backtrace() with HAVE_BACKTRACE, since we already
have the autoconf machinery for setting that.

For the moment, assume dladdr() is available when backtrace() is

Signed-off-by: Jon TURNEY jon.tur...@dronecode.org.uk
---
 glx/glapi_gentable.c |6 ++
 1 files changed, 6 insertions(+), 0 deletions(-)

diff --git a/glx/glapi_gentable.c b/glx/glapi_gentable.c
index a9ba3af..b49ae20 100644
--- a/glx/glapi_gentable.c
+++ b/glx/glapi_gentable.c
@@ -31,7 +31,10 @@
 #include dix-config.h
 #endif
 
+#ifdef HAVE_BACKTRACE
 #include execinfo.h
+#endif
+
 #include dlfcn.h
 #include stdlib.h
 #include stdio.h
@@ -46,6 +49,8 @@
 static void
 __glapi_gentable_NoOp(void) {
 const char *fstr = Unknown;
+
+#ifdef HAVE_BACKTRACE
 void *frames[2];
 
 if(backtrace(frames, 2) == 2) {
@@ -54,6 +59,7 @@ __glapi_gentable_NoOp(void) {
 if(info.dli_sname)
 fstr = info.dli_sname;
 }
+#endif
 
 LogMessage(X_ERROR, GLX: Call to unimplemented API: %s\n, fstr);
 }
-- 
1.7.5.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:xf86-video-v4l] Bump version for development.

2011-06-28 Thread Cyril Brulebois
Signed-off-by: Cyril Brulebois k...@debian.org
---
 configure.ac |2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

The version number wasn't bumped after 0.2.0; given the big changes from
Mauro Carvalho Chehab to support V4L2, having 0.3.0 as the next version
number looks reasonable, so bump version number accordingly.

diff --git a/configure.ac b/configure.ac
index c490919..ac4d611 100644
--- a/configure.ac
+++ b/configure.ac
@@ -23,7 +23,7 @@
 # Initialize Autoconf
 AC_PREREQ([2.60])
 AC_INIT([xf86-video-v4l],
-[0.2.0],
+[0.2.99],
 [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg],
 [xf86-video-v4l])
 AC_CONFIG_SRCDIR([Makefile.am])
-- 
1.7.5.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: [PULL] Kill libxorg

2011-06-28 Thread Daniel Stone
Hi,

On Thu, Jun 23, 2011 at 05:52:47AM -0700, Dan Nicholson wrote:
 Having now played around with trying to kill libxservertest, I
 realized that this patchset isn't quite as robust as I thought. It
 turns out that getting all the Xorg convenience libraries to link
 without putting them into a massive convenience library isn't strictly
 possible. Code in libcommon uses symbols from libxorgos and vice versa
 for example, so there's no way to order the libraries correctly at
 link time to make the symbols resolve.
 
 The only reason this patch works is because of sdksyms.c. Since it
 references every symbol, if it's linked as an object into Xorg, it
 will make all subsequent symbols in the link resolve correctly. The
 point being that if sdksyms.c ever went away, Xorg would stop linking.

Right.  For all its flaws (of which there are so very many), it does
keep things hanging together nicely.

 I think there's another way to keep the speedup that would be more
 robust: keep libxorg.la but make it build all of hw/xfree86
 non-recursively to avoid convenience libraries of convenience
 libraries. That would be really intrusive, though.

Heh.  Feel free. :)

 Anyway, I think what I've done right now is fine for the foreseeable
 future. I just wanted to share my thoughts before this goes in.

Seems fair; killing sdksyms.c would be a large enough endeavour that I
think the benefits of this patchset still strongly, strongly outweigh
the downsides.  I'd be very happy to see it pulled (nudge, nudge).

Cheers,
Daniel
___
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 RESEND synaptics 1/2] Revert build: collapse all Makefile.am files into a single non-recursive one.

2011-06-28 Thread Gaetan Nadon
This reverts commit 39afe69ad7d2258d4043044d1283bd6e311e48da.

Conflicts:

.gitignore
Makefile.am

This patch is to review non-recursive make commit 39afe69ad7.
This will formalize the review being held on xorg-devel list.

http://lists.x.org/archives/xorg-devel/2011-June/023321.html
http://lists.x.org/archives/xorg-devel/2011-June/023233.html

There are a couple of minor code changes unrelated to makefile recursiveness
which can be resubmitted should the revert be accepted:
  @DRIVER_NAME@_drv_ladir = @inputdir@ to
input_LTLIBRARIES = @DRIVER_NAME@_drv.la
  noinst_PROGRAMS to check_PROGRAMS

Signed-off-by: Gaetan Nadon mems...@videotron.ca
---
 .gitignore  |4 --
 Makefile.am |   96 ++-
 conf/Makefile.am|   27 ++
 configure.ac|6 +++
 include/Makefile.am |   21 +++
 man/Makefile.am |   47 +
 src/Makefile.am |   52 +++
 test/.gitignore |6 +++
 test/Makefile.am|   15 
 tools/.gitignore|3 ++
 tools/Makefile.am   |   31 
 11 files changed, 211 insertions(+), 97 deletions(-)
 create mode 100644 conf/Makefile.am
 create mode 100644 include/Makefile.am
 create mode 100644 man/Makefile.am
 create mode 100644 src/Makefile.am
 create mode 100644 test/.gitignore
 create mode 100644 test/Makefile.am
 create mode 100644 tools/.gitignore
 create mode 100644 tools/Makefile.am

diff --git a/.gitignore b/.gitignore
index 39e3f35..c496323 100644
--- a/.gitignore
+++ b/.gitignore
@@ -76,7 +76,3 @@ core
 #  Edit the following section as needed
 # For example, !report.pc overrides *.pc. See 'man gitignore'
 # 
-eventcomm-test
-synclient
-syndaemon
-.dirstamp
\ No newline at end of file
diff --git a/Makefile.am b/Makefile.am
index e94fe19..256c738 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -18,6 +18,8 @@
 #  IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
 #  CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 
+SUBDIRS = include src man tools conf test
+
 # During distcheck, system locations (as provided by pkg-config) are
 # not writable; provide instead relative locations.
 DISTCHECK_CONFIGURE_FLAGS = \
@@ -29,99 +31,7 @@ MAINTAINERCLEANFILES = ChangeLog INSTALL
 pkgconfigdir = $(libdir)/pkgconfig
 pkgconfig_DATA = xorg-synaptics.pc
 
-sdk_HEADERS = include/synaptics.h include/synaptics-properties.h
-
-input_LTLIBRARIES = @DRIVER_NAME@_drv.la
-
-# -module lets us name the module exactly how we want
-# -avoid-version prevents gratuitous .0.0.0 version numbers on the end
-# -shared avoid building the static archive
-@DRIVER_NAME@_drv_la_LDFLAGS = -module -avoid-version -shared
-@DRIVER_NAME@_drv_la_CPPFLAGS = -I$(top_srcdir)/include
-@DRIVER_NAME@_drv_la_CFLAGS = $(XORG_CFLAGS)
-
-@DRIVER_NAME@_drv_la_SOURCES = src/@DRIVER_NAME@.c src/synapticsstr.h \
-   src/synproto.h \
-   src/properties.c
-
-if BUILD_PS2COMM
-@DRIVER_NAME@_drv_la_SOURCES += \
-   src/alpscomm.c \
-   src/ps2comm.c src/ps2comm.h
-endif
-
-if BUILD_EVENTCOMM
-@DRIVER_NAME@_drv_la_SOURCES += \
-   src/eventcomm.c src/eventcomm.h
-endif
-
-if BUILD_PSMCOMM
-@DRIVER_NAME@_drv_la_SOURCES += \
-   src/psmcomm.c
-endif
-
-bin_PROGRAMS = synclient syndaemon
-
-synclient_SOURCES = tools/synclient.c
-synclient_CFLAGS = -I$(top_srcdir)/include $(XORG_CFLAGS) $(XI_CFLAGS)
-synclient_LDADD = $(XI_LIBS)
-
-syndaemon_SOURCES = tools/syndaemon.c
-syndaemon_CFLAGS = -I$(top_srcdir)/include $(XORG_CFLAGS) $(XI_CFLAGS) 
$(XTST_CFLAGS)
-syndaemon_LDADD = $(XI_LIBS) $(XTST_LIBS)
-
-if HAS_XORG_CONF_DIR
-dist_config_DATA = conf/50-synaptics.conf
-else
-fdidir = $(datadir)/hal/fdi/policy/20thirdparty
-dist_fdi_DATA = conf/11-x11-synaptics.fdi
-endif
-
-if ENABLE_UNIT_TESTS
-if BUILD_EVENTCOMM
-check_PROGRAMS = eventcomm-test
-
-eventcomm_test_CPPFLAGS = -I$(top_srcdir)/src -I$(top_srcdir)/include
-eventcomm_test_CFLAGS = $(XORG_CFLAGS) $(CWARNFLAGS)
-eventcomm_test_SOURCES = test/eventcomm-test.c\
-src/eventcomm.c \
-test/fake-symbols.c test/fake-symbols.h
-
-TESTS = $(check_PROGRAMS)
-endif
-endif
-
-synclientmandir = $(APP_MAN_DIR)
-synclientman_PRE = man/synclient.man
-synclientman_DATA = $(synclientman_PRE:man=@APP_MAN_SUFFIX@)
-
-syndaemonmandir = $(APP_MAN_DIR)
-syndaemonman_PRE = man/syndaemon.man
-syndaemonman_DATA = $(syndaemonman_PRE:man=@APP_MAN_SUFFIX@)
-
-drivermandir = $(DRIVER_MAN_DIR)
-driverman_PRE = man/@DRIVER_NAME@.man
-driverman_DATA = $(driverman_PRE:man=@DRIVER_MAN_SUFFIX@)
-
-EXTRA_DIST = man/@DRIVER_NAME@.man man/synclient.man man/syndaemon.man
-
-CLEANFILES = $(driverman_DATA) $(synclientman_DATA) $(syndaemonman_DATA)
-
-SUFFIXES = .$(DRIVER_MAN_SUFFIX) .man
-
-.PHONY: ChangeLog INSTALL mandir
-
-mandir:
-   $(MKDIR_P) man
-
-# String replacements in MAN_SUBSTS now come from xorg-macros.m4 via 

[PATCH RESEND synaptics 2/2] Revert build: create object files following the sources' structure.

2011-06-28 Thread Gaetan Nadon
This reverts commit dac624ad2b3a67ab93c11d8ee0a91b217fc1afe6.

Conflicts:

.gitignore

This patch is part of the non-recursive make reversal.
It was added later to write object code in each subdirectories.

Signed-off-by: Gaetan Nadon mems...@videotron.ca
---
 configure.ac |2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/configure.ac b/configure.ac
index 0878287..006d56c 100644
--- a/configure.ac
+++ b/configure.ac
@@ -31,7 +31,7 @@ AC_CONFIG_HEADERS([config.h])
 AC_CONFIG_AUX_DIR(.)
 
 # Initialize Automake
-AM_INIT_AUTOMAKE([foreign dist-bzip2 subdir-objects])
+AM_INIT_AUTOMAKE([foreign dist-bzip2])
 AM_MAINTAINER_MODE
 
 # Initialize libtool
-- 
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 RESEND synaptics 1/2] Revert build: collapse all Makefile.am files into a single non-recursive one.

2011-06-28 Thread Daniel Stone
On Tue, Jun 28, 2011 at 11:19:40AM -0400, Gaetan Nadon wrote:
 This reverts commit 39afe69ad7d2258d4043044d1283bd6e311e48da.
 
 Conflicts:
 
   .gitignore
   Makefile.am
 
 This patch is to review non-recursive make commit 39afe69ad7.
 This will formalize the review being held on xorg-devel list.
 
 http://lists.x.org/archives/xorg-devel/2011-June/023321.html
 http://lists.x.org/archives/xorg-devel/2011-June/023233.html
 
 There are a couple of minor code changes unrelated to makefile recursiveness
 which can be resubmitted should the revert be accepted:
   @DRIVER_NAME@_drv_ladir = @inputdir@ to
 input_LTLIBRARIES = @DRIVER_NAME@_drv.la
   noinst_PROGRAMS to check_PROGRAMS
 
 Signed-off-by: Gaetan Nadon mems...@videotron.ca

For both patches:
Acked-by: Daniel Stone dan...@fooishbar.org

The changes seem to have broken ChangeLog generation too, such that:
make -C build; sudo make -C build install; make -C build
will cause a warning about overwriting ChangeLog due to permissions, as
it gets generated by both make all and make install.

Either way, I don't have an issue with the changes per se, but they
should definitely be coming through the list, and we should try to keep
the drivers as common as possible.

Cheers,
Daniel
___
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


[PULL] XQuartz misc + XWin glapi build fix

2011-06-28 Thread Jeremy Huddleston
The following changes since commit 4dbed2625431a92e20bede7b8cef847b5d5d99ba:

  xfree86: Only log the serial bytes if debug is on. (2011-06-27 12:21:45 -0700)

are available in the git repository at:
  git://people.freedesktop.org/~jeremyhu/xserver master

Jeremy Huddleston (2):
  XQuartz: Make a call to activateIgnoringOtherApps in our 
NSApplicationActivatedEventType handler
  XQuartz: Fix Makefile dependencies

Jon TURNEY (1):
  Guard use of backtrace() with HAVE_BACKTRACE

 configure.ac|4 ++--
 glx/glapi_gentable.c|6 ++
 hw/xquartz/X11Application.m |   25 -
 hw/xquartz/mach-startup/Makefile.am |4 +++-
 4 files changed, 27 insertions(+), 12 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


Re: [PATCH] glx: Add _glapi_create_table_from_handle

2011-06-28 Thread Jeremy Huddleston
Thanks.  It's in the pull request I just sent.

The generator script is in mesa, so I'll try to figure this out in mesa as well.

--Jeremy

On Jun 28, 2011, at 6:24 AM, Jon TURNEY wrote:

 On 27/06/2011 18:38, Jeremy Huddleston wrote:
 Those bits in the NoOp stub can be left out on Win32 (or you can tell me the 
 Win32 way of figuring that out).  It's just used to provide extra info to 
 give a hint as to which call was unimplemented.
 
 Looking at this a bit more I notice that we already have the autoconf 
 machinery to check if backtrace() is available, so let's use that, rather 
 than trying to come up with a list of targets which have those functions.
 
 There's no easy way to implement equivalent functionality to backtrace() on 
 Win32, which is why cygwin doesn't have a backtrace() function yet :-)
 
 Patch attached, although obviously it's the code generator for this file 
 which should be fixed...
 
 
 0001-Guard-use-of-backtrace-with-HAVE_BACKTRACE.patch

___
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] Kill libxorg

2011-06-28 Thread Keith Packard
On Thu, 23 Jun 2011 05:52:47 -0700, Dan Nicholson dbn.li...@gmail.com wrote:

 Anyway, I think what I've done right now is fine for the foreseeable
 future. I just wanted to share my thoughts before this goes in.

I've merged it, along with a fix-up for 'make distcheck' (somehow I had
a feeling that might be broken by this change).

- 9d568450b1319e9057319ebb37e76003bcba447d

-- 
keith.pack...@intel.com


pgpzxhBF9jeZp.pgp
Description: 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

[PATCH input-synaptics] Revert build: install documentation as part of make install.

2011-06-28 Thread Gaetan Nadon
This reverts commit d27b4e560ccf61b94f067156c6d5c1e3d3e5e1eb.

ChangeLog is generated from git and should be created at dist time only.
The original patch creates it at make time multiple times and fails
when user permissions change such as when using sudo.

Some have expressed a desire to install files such as ChangeLog and README.
This reversal does not dismiss the idea, but simply reverts a non-essential
change that happens to have an implementation bug just before making a module
release.

Anyone is welcome to promote the idea in the context of the X.Org project
where all modules would exhibit the same behaviour. The current behaviour of
ChangeLog, although not perfect, has been thoroughly reviewed and widely
accepted for several years.

As for the files in docs, they should be re-submitted for reviews to determine
if they constitute users docs that should be installed as opposed to
developers docs which are not.

Reported-by: Daniel Stone dan...@fooishbar.org
Signed-off-by: Gaetan Nadon mems...@videotron.ca
---
 Makefile.am |3 ---
 1 files changed, 0 insertions(+), 3 deletions(-)

diff --git a/Makefile.am b/Makefile.am
index 256c738..70657ff 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -40,6 +40,3 @@ ChangeLog:
$(CHANGELOG_CMD)
 
 dist-hook: ChangeLog INSTALL
-
-dist_doc_DATA = ChangeLog README docs/README.alps  \
-   docs/trouble-shooting.txt docs/tapndrag.dia
-- 
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 3/6] XWin: Remove executable bit from headers

2011-06-28 Thread Cyril Brulebois
Daniel Stone dan...@fooishbar.org (22/06/2011):
 Headers don't really need to be mode 0755.
 
 Signed-off-by: Daniel Stone dan...@fooishbar.org

oh yeah.

Reviewed-by: Cyril Brulebois k...@debian.org

Mraw,
KiBi.


signature.asc
Description: Digital 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: [PATCH 4/6] DMX: Remove useless miPointerUpdateSprite call

2011-06-28 Thread Cyril Brulebois
Daniel Stone dan...@fooishbar.org (22/06/2011):
 miPointerUpdateSprite is already called from mieqProcessInputEvents, so
 calling it by hand immediately after isn't massively helpful.

Reviewed-by: Cyril Brulebois k...@debian.org

Mraw,
KiBi.


signature.asc
Description: Digital 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: [PATCH 5/6] KDrive: Remove useless miPointerUpdateSprite call

2011-06-28 Thread Cyril Brulebois
Daniel Stone dan...@fooishbar.org (22/06/2011):
 miPointerUpdateSprite is already called from mieqProcessInputEvents, so
 calling it by hand immediately after isn't massively helpful.
 
 Signed-off-by: Daniel Stone dan...@fooishbar.org

Reviewed-by: Cyril Brulebois k...@debian.org

Mraw,
KiBi.


signature.asc
Description: Digital 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

[PATCH 01/37] Add a common ARRAY_SIZE macro to dix.h

2011-06-28 Thread Daniel Stone
Does what it says on the box, replacing those from Xi/ and glx/.

Signed-off-by: Daniel Stone dan...@fooishbar.org
---
 Xi/extinit.c   |2 --
 glx/glxdricommon.c |2 --
 include/dix.h  |2 ++
 3 files changed, 2 insertions(+), 4 deletions(-)

diff --git a/Xi/extinit.c b/Xi/extinit.c
index 0905e18..1e30b3c 100644
--- a/Xi/extinit.c
+++ b/Xi/extinit.c
@@ -49,8 +49,6 @@ SOFTWARE.
  *  Dispatch routines and initialization routines for the X input extension.
  *
  */
-#define ARRAY_SIZE(_a)(sizeof((_a)) / sizeof((_a)[0]))
-
 #define NUMTYPES 15
 
 #ifdef HAVE_DIX_CONFIG_H
diff --git a/glx/glxdricommon.c b/glx/glxdricommon.c
index 9149e0d..0e977e4 100644
--- a/glx/glxdricommon.c
+++ b/glx/glxdricommon.c
@@ -105,8 +105,6 @@ static const struct { unsigned int attrib, offset; } 
attribMap[] = {
 __ATTRIB(__DRI_ATTRIB_YINVERTED,   yInverted),
 };
 
-#define ARRAY_SIZE(a) (sizeof (a) / sizeof ((a)[0]))
-
 static void
 setScalar(__GLXconfig *config, unsigned int attrib, unsigned int value)
 {
diff --git a/include/dix.h b/include/dix.h
index b1bf9ed..cb47d23 100644
--- a/include/dix.h
+++ b/include/dix.h
@@ -65,6 +65,8 @@ SOFTWARE.
 #define REQUEST(type) \
type *stuff = (type *)client-requestBuffer
 
+#define ARRAY_SIZE(a)  (sizeof((a)) / sizeof((a)[0]))
+
 
 #define REQUEST_SIZE_MATCH(req)\
 if ((sizeof(req)  2) != client-req_len)\
-- 
1.7.5.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


[PATCH 0/37] Extension handling cleanup, death to extmod

2011-06-28 Thread Daniel Stone
Hi,
The following patch series cleans up extension handling pretty
substantially: it kills extmod, removes about half of miinitext.c to
give us one unified set of extension definitions, and removes all other
Xorg extension modules except for GLX, which is huge.

This also adds a localOnly argument to AddExtension, which if true, will
hide these extensions from remote clients (hi ajax!).

After I'd done this series, I discovered[0] Tomas Carnecky's patch series
which got rid of extmod, although with a slightly different approach.
I've switched the author tags to him for the identical patches we'd come
up with, but they are split a bit more aggressively, and we took a
different approach to the Xorg-specific extensions, and XSELinux.

All of the above seems to work fine on my local machine; the extension
list remains the same, all the extensions I tried are still working
fine, and this is the result of local vs. remote xdpyinfo:
--- local   2011-06-28 00:14:49.722077586 +0100
+++ remote  2011-06-28 00:14:57.321353687 +0100
@@ -1,4 +1,4 @@
-name of display::0
+name of display:192.168.224.239:0
 version number:11.0
 vendor string:The X.Org Foundation
 vendor release number:11099901
@@ -18,17 +18,15 @@
 depth 32, bits_per_pixel 32, scanline_pad 32
 keycode range:minimum 8, maximum 255
 focus:  window 0x2400057, revert to Parent
-number of extensions:26
+number of extensions:24
 BIG-REQUESTS
 Composite
 DAMAGE
 DOUBLE-BUFFER
 DPMS
-DRI2
 GLX
 Generic Event Extension
 MIT-SCREEN-SAVER
-MIT-SHM
 RANDR
 RECORD
 RENDER

Patch #37 is still a WIP, as noted, as it will break enabling and
disabling of any module not in miinitext.c.  Regardless, the rest should
be OK, so please review.

Cheers,
Daniel

[0]: While googling for the SELinux xorg.conf options to see if anyone
 ever used them.

___
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 02/37] Make extension.h self-contained, remove C++ externs

2011-06-28 Thread Daniel Stone
externsion.h required bits from Xfuncproto.h and dixstruct.h, but
included neither; fix that.

It also had _XFUNCPROTOBEGIN and _XFUNCPROTOEND wrappers, which is a bit
pointless for a server-only library, as it's only needed for C++.

Signed-off-by: Daniel Stone dan...@fooishbar.org
---
 include/extension.h |6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/include/extension.h b/include/extension.h
index 29a11c3..d24301d 100644
--- a/include/extension.h
+++ b/include/extension.h
@@ -48,7 +48,9 @@ SOFTWARE.
 #ifndef EXTENSION_H
 #define EXTENSION_H 
 
-_XFUNCPROTOBEGIN
+#include X11/Xfuncproto.h
+
+#include dixstruct.h
 
 extern _X_EXPORT unsigned short StandardMinorOpcode(ClientPtr /*client*/);
 
@@ -62,6 +64,4 @@ extern _X_EXPORT void InitExtensions(int argc, char **argv);
 
 extern _X_EXPORT void CloseDownExtensions(void);
 
-_XFUNCPROTOEND
-
 #endif /* EXTENSION_H */
-- 
1.7.5.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


[PATCH 03/37] Xinerama: Fix ExtensionInit prototype

2011-06-28 Thread Daniel Stone
Huh, so I guess INITARGS used to be int argc, char *argv then.  Either
way, it's now void, so fix that ...

Signed-off-by: Daniel Stone dan...@fooishbar.org
---
 Xext/panoramiX.c|2 +-
 hw/xfree86/dixmods/extmod/modinit.h |2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/Xext/panoramiX.c b/Xext/panoramiX.c
index 00afe94..9481438 100644
--- a/Xext/panoramiX.c
+++ b/Xext/panoramiX.c
@@ -438,7 +438,7 @@ void XineramaReinitData(ScreenPtr pScreen)
  * Initialize global variables.
  */ 
 
-void PanoramiXExtensionInit(int argc, char *argv[])
+void PanoramiXExtensionInit(void)
 {
 inti;
 Bool   success = FALSE;
diff --git a/hw/xfree86/dixmods/extmod/modinit.h 
b/hw/xfree86/dixmods/extmod/modinit.h
index 588..adbcdd5 100644
--- a/hw/xfree86/dixmods/extmod/modinit.h
+++ b/hw/xfree86/dixmods/extmod/modinit.h
@@ -78,7 +78,7 @@ extern void SecurityExtensionInit(INITARGS);
 #endif
 
 #if 1
-extern void PanoramiXExtensionInit(int argc, char *argv[]);
+extern void PanoramiXExtensionInit(INITARGS);
 #endif
 
 #if 1
-- 
1.7.5.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


[PATCH 11/37] Move DPMS from extmod to built-in

2011-06-28 Thread Daniel Stone
From: Tomas Carnecky t...@dbservice.com

Always build DPMS support into the core server, rather than letting it
languish in extmod.

Signed-off-by: Tomas Carnecky t...@dbservice.com
Reviewed-by: Daniel Stone dan...@fooishbar.org
---
 Xext/Makefile.am|2 +-
 Xext/dpms.c |2 ++
 hw/xfree86/dixmods/extmod/modinit.c |9 -
 mi/miinitext.c  |6 ++
 4 files changed, 9 insertions(+), 10 deletions(-)

diff --git a/Xext/Makefile.am b/Xext/Makefile.am
index a443a64..adea06e 100644
--- a/Xext/Makefile.am
+++ b/Xext/Makefile.am
@@ -103,7 +103,7 @@ endif
 # DPMS extension
 DPMS_SRCS = dpms.c dpmsproc.h
 if DPMSExtension
-MODULE_SRCS += $(DPMS_SRCS)
+BUILTIN_SRCS += $(DPMS_SRCS)
 endif
 
 # Now take all of the above, mix well, bake for 10 minutes and get libXext*.la
diff --git a/Xext/dpms.c b/Xext/dpms.c
index 32f33b3..d09fd0a 100644
--- a/Xext/dpms.c
+++ b/Xext/dpms.c
@@ -41,6 +41,8 @@ Equipment Corporation.
 #include dpmsproc.h
 #include modinit.h
 
+extern void DPMSExtensionInit(void);
+
 static int
 ProcDPMSGetVersion(ClientPtr client)
 {
diff --git a/hw/xfree86/dixmods/extmod/modinit.c 
b/hw/xfree86/dixmods/extmod/modinit.c
index 4441899..6625f26 100644
--- a/hw/xfree86/dixmods/extmod/modinit.c
+++ b/hw/xfree86/dixmods/extmod/modinit.c
@@ -65,15 +65,6 @@ static ExtensionModule extensionModules[] = {
NULL
 },
 #endif
-#ifdef DPMSExtension
-{
-   DPMSExtensionInit,
-   DPMSExtensionName,
-   noDPMSExtension,
-   NULL,
-   NULL
-},
-#endif
 #ifdef XV
 {
XvExtensionInit,
diff --git a/mi/miinitext.c b/mi/miinitext.c
index c75c140..79786aa 100644
--- a/mi/miinitext.c
+++ b/mi/miinitext.c
@@ -186,6 +186,9 @@ typedef void (*InitExtension)(void);
 #ifdef SCREENSAVER
 #include X11/extensions/saver.h
 #endif
+#ifdef DPMSExtension
+#include X11/extensions/dpmsconst.h
+#endif
 
 /* FIXME: this whole block of externs should be from the appropriate headers */
 #ifdef MITSHM
@@ -524,6 +527,9 @@ static ExtensionModule staticExtensions[] = {
 #ifdef XRECORD
 { RecordExtensionInit, RECORD, noTestExtensions, NULL },
 #endif
+#ifdef DPMSExtension
+{ DPMSExtensionInit, DPMSExtensionName, noDPMSExtension, NULL },
+#endif
 { NULL, NULL, NULL, NULL, NULL }
 };
 
-- 
1.7.5.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


[PATCH 08/37] Move DBE from an external module to built-in

2011-06-28 Thread Daniel Stone
From: Tomas Carnecky t...@dbservice.com

If DBE support is compiled in the server, just man up and build it into
the server, rather than having it as an external module.

Signed-off-by: Tomas Carnecky t...@dbservice.com
Reviewed-by: Daniel Stone dan...@fooishbar.org
---
 configure.ac   |5 ++-
 hw/xfree86/common/xf86Config.c |3 --
 hw/xfree86/dixmods/Makefile.am |   10 
 hw/xfree86/dixmods/dbemodule.c |   46 
 hw/xfree86/loader/loadmod.c|1 +
 hw/xfree86/sdksyms.sh  |4 +-
 mi/miinitext.c |3 ++
 7 files changed, 9 insertions(+), 63 deletions(-)
 delete mode 100644 hw/xfree86/dixmods/dbemodule.c

diff --git a/configure.ac b/configure.ac
index 67a7f13..d525e21 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1117,6 +1117,7 @@ AM_CONDITIONAL(DBE, [test x$DBE = xyes])
 if test x$DBE = xyes; then
AC_DEFINE(DBE, 1, [Support DBE extension])
DBE_LIB='$(top_builddir)/dbe/libdbe.la'
+   DBE_INC='-I$(top_srcdir)/dbe'
 fi
 
 AM_CONDITIONAL(XF86BIGFONT, [test x$XF86BIGFONT = xyes])
@@ -1454,7 +1455,7 @@ AC_EGREP_CPP([I_AM_SVR4],[
 AC_DEFINE([SVR4],1,[Define to 1 on systems derived from System V Release 4])
 AC_MSG_RESULT([yes])], AC_MSG_RESULT([no]))
 
-XSERVER_CFLAGS=$XSERVER_CFLAGS $CORE_INCS $XEXT_INC $COMPOSITE_INC 
$DAMAGE_INC $FIXES_INC $XI_INC $MI_INC $MIEXT_SYNC_INC $MIEXT_SHADOW_INC 
$MIEXT_LAYER_INC $MIEXT_DAMAGE_INC $RENDER_INC $RANDR_INC $FB_INC
+XSERVER_CFLAGS=$XSERVER_CFLAGS $CORE_INCS $XEXT_INC $COMPOSITE_INC 
$DAMAGE_INC $FIXES_INC $XI_INC $MI_INC $MIEXT_SYNC_INC $MIEXT_SHADOW_INC 
$MIEXT_LAYER_INC $MIEXT_DAMAGE_INC $RENDER_INC $RANDR_INC $FB_INC $DBE_INC
 
 dnl ---
 dnl DDX section.
@@ -1516,7 +1517,7 @@ if test x$XORG = xyes; then
XORG_OSINCS='-I$(top_srcdir)/hw/xfree86/os-support 
-I$(top_srcdir)/hw/xfree86/os-support/bus -I$(top_srcdir)/os'
XORG_INCS=$XORG_DDXINCS $XORG_OSINCS
XORG_CFLAGS=$XORGSERVER_CFLAGS -DHAVE_XORG_CONFIG_H
-   XORG_LIBS=$COMPOSITE_LIB $FIXES_LIB $XEXTXORG_LIB $GLX_LIBS $RANDR_LIB 
$RENDER_LIB $DAMAGE_LIB $MIEXT_SYNC_LIB $MIEXT_DAMAGE_LIB $MIEXT_SHADOW_LIB 
$XI_LIB $XKB_LIB
+   XORG_LIBS=$COMPOSITE_LIB $FIXES_LIB $XEXTXORG_LIB $DBE_LIB $GLX_LIBS 
$RANDR_LIB $RENDER_LIB $DAMAGE_LIB $MIEXT_SYNC_LIB $MIEXT_DAMAGE_LIB 
$MIEXT_SHADOW_LIB $XI_LIB $XKB_LIB
 
dnl ==
dnl symbol visibility
diff --git a/hw/xfree86/common/xf86Config.c b/hw/xfree86/common/xf86Config.c
index 114bdc3..6e93be8 100644
--- a/hw/xfree86/common/xf86Config.c
+++ b/hw/xfree86/common/xf86Config.c
@@ -110,9 +110,6 @@
 
 static ModuleDefault ModuleDefaults[] = {
 {.name = extmod,   .toLoad = TRUE,.load_opt=NULL},
-#ifdef DBE
-{.name = dbe,  .toLoad = TRUE,.load_opt=NULL},
-#endif
 #ifdef GLXEXT
 {.name = glx,  .toLoad = TRUE,.load_opt=NULL},
 #endif
diff --git a/hw/xfree86/dixmods/Makefile.am b/hw/xfree86/dixmods/Makefile.am
index 1a162ab..3e7354c 100644
--- a/hw/xfree86/dixmods/Makefile.am
+++ b/hw/xfree86/dixmods/Makefile.am
@@ -6,10 +6,6 @@ if GLX
 GLXMODS = libglx.la
 endif
 
-if DBE
-DBEMOD = libdbe.la
-endif
-
 if RECORD
 RECORDMOD = librecord.la
 endif
@@ -20,20 +16,14 @@ module_LTLIBRARIES = libfb.la \
 
 extsmoduledir = $(moduledir)/extensions
 extsmodule_LTLIBRARIES = $(RECORDMOD) \
-$(DBEMOD) \
  $(GLXMODS)
 
 AM_CFLAGS = @XORG_CFLAGS@ @DIX_CFLAGS@
 INCLUDES = @XORG_INCS@ \
-   -I$(top_srcdir)/dbe \
-I$(top_srcdir)/hw/xfree86/loader \
-I$(top_srcdir)/miext/shadow \
-I$(top_srcdir)/glx
 
-libdbe_la_LDFLAGS = -avoid-version
-libdbe_la_LIBADD = $(top_builddir)/dbe/libdbe.la
-libdbe_la_SOURCES = dbemodule.c
-
 libfb_la_LDFLAGS = -avoid-version
 libfb_la_LIBADD = $(top_builddir)/fb/libfb.la
 libfb_la_SOURCES = $(top_builddir)/fb/fbcmap_mi.c fbmodule.c
diff --git a/hw/xfree86/dixmods/dbemodule.c b/hw/xfree86/dixmods/dbemodule.c
deleted file mode 100644
index 436a7b1..000
--- a/hw/xfree86/dixmods/dbemodule.c
+++ /dev/null
@@ -1,46 +0,0 @@
-#ifdef HAVE_XORG_CONFIG_H
-#include xorg-config.h
-#endif
-
-#include xf86Module.h
-#include globals.h
-
-static MODULESETUPPROTO(dbeSetup);
-
-extern void DbeExtensionInit(void);
-
-static ExtensionModule dbeExt = {
-DbeExtensionInit,
-DOUBLE-BUFFER,
-noDbeExtension,
-NULL,
-NULL
-};
-
-static XF86ModuleVersionInfo VersRec =
-{
-   dbe,
-   MODULEVENDORSTRING,
-   MODINFOSTRING1,
-   MODINFOSTRING2,
-   XORG_VERSION_CURRENT,
-   1, 0, 0,
-   ABI_CLASS_EXTENSION,
-   ABI_EXTENSION_VERSION,
-   MOD_CLASS_EXTENSION,
-   {0,0,0,0}
-};
-
-/*
- * Data for the loader
- */
-_X_EXPORT XF86ModuleData dbeModuleData = { VersRec, dbeSetup, NULL };
-
-static pointer
-dbeSetup(pointer module, pointer 

[PATCH 06/37] Loader: Drop EXTERN_MODULE flag

2011-06-28 Thread Daniel Stone
EXTERN_MODULE was used to specify that we shouldn't worry about modules
lacking a ModuleData object.  It was also completely unused.  *shrug*

Signed-off-by: Daniel Stone dan...@fooishbar.org
---
 hw/xfree86/common/xf86Module.h |3 ---
 hw/xfree86/doc/ddxDesign.xml   |9 -
 hw/xfree86/loader/loadmod.c|4 
 3 files changed, 0 insertions(+), 16 deletions(-)

diff --git a/hw/xfree86/common/xf86Module.h b/hw/xfree86/common/xf86Module.h
index 599f25f..655a256 100644
--- a/hw/xfree86/common/xf86Module.h
+++ b/hw/xfree86/common/xf86Module.h
@@ -55,9 +55,6 @@ typedef enum {
 
 #define DEFAULT_LIST ((char *)-1)
 
-/* This indicates a special module that doesn't have the usual entry point */
-#define EXTERN_MODULE ((pointer)-1)
-
 /* Built-in ABI classes.  These definitions must not be changed. */
 #define ABI_CLASS_NONE NULL
 #define ABI_CLASS_ANSICX.Org ANSI C Emulation
diff --git a/hw/xfree86/doc/ddxDesign.xml b/hw/xfree86/doc/ddxDesign.xml
index 0290960..87666b1 100644
--- a/hw/xfree86/doc/ddxDesign.xml
+++ b/hw/xfree86/doc/ddxDesign.xml
@@ -5375,15 +5375,6 @@ XFree86 common layer.
  way by modules loaded directly by the XFree86 common
  layer.  However, it may be used for application-specific
  parameter passing in other situations.
-   /para
-
-   para
- When loading quoteexternal/quote modules (modules that 
don't
- have the standard entry point, for example a
- special shared library) the options parameter can be
- set to constantEXTERN_MODULE/constant to tell the
- loader not to reject the module when it doesn't find
- the standard entry point.
/para/listitem/varlistentry
 
 
diff --git a/hw/xfree86/loader/loadmod.c b/hw/xfree86/loader/loadmod.c
index 9f82099..8ee01f2 100644
--- a/hw/xfree86/loader/loadmod.c
+++ b/hw/xfree86/loader/loadmod.c
@@ -973,10 +973,6 @@ doLoadModule(const char *module, const char *path, const 
char **subdirlist,
ret-TearDownProc = teardown;
ret-VersionInfo = vers;
 } else {
-   /* No initdata is OK for external modules */
-   if (options == EXTERN_MODULE)
-   goto LoadModule_exit;
-
/* no initdata, fail the load */
xf86Msg(X_ERROR, LoadModule: Module %s does not have a %s 
data object.\n, module, p);
-- 
1.7.5.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


[PATCH 13/37] Move Xv and XvMC from extmod to built-in

2011-06-28 Thread Daniel Stone
From: Tomas Carnecky t...@dbservice.com

Always build these extensions into the core server, rather than letting
them languish in extmod.

Signed-off-by: Tomas Carnecky t...@dbservice.com
Reviewed-by: Daniel Stone dan...@fooishbar.org
---
 Xext/Makefile.am  |2 +-
 Xext/xvdix.h  |9 +++--
 Xext/xvmain.c |   15 +++
 Xext/xvmcext.h|5 +
 hw/kdrive/src/kxv.c   |4 
 hw/xfree86/common/xf86xv.c|5 -
 hw/xfree86/common/xf86xv.h|4 
 hw/xfree86/common/xf86xvmc.c  |5 -
 hw/xfree86/dixmods/extmod/Makefile.am |7 +--
 hw/xfree86/dixmods/extmod/modinit.c   |   16 
 hw/xfree86/dixmods/extmod/xvmod.c |   23 ---
 hw/xfree86/dixmods/extmod/xvmodproc.h |   13 -
 hw/xfree86/sdksyms.sh |4 +---
 mi/miinitext.c|9 +
 14 files changed, 35 insertions(+), 86 deletions(-)
 delete mode 100644 hw/xfree86/dixmods/extmod/xvmod.c
 delete mode 100644 hw/xfree86/dixmods/extmod/xvmodproc.h

diff --git a/Xext/Makefile.am b/Xext/Makefile.am
index 04e1b36..acbcc17 100644
--- a/Xext/Makefile.am
+++ b/Xext/Makefile.am
@@ -46,7 +46,7 @@ endif
 # XVideo extension
 XV_SRCS = xvmain.c xvdisp.c xvmc.c xvdix.h xvmcext.h xvdisp.h
 if XV
-MODULE_SRCS  += $(XV_SRCS)
+BUILTIN_SRCS  += $(XV_SRCS)
 endif
 
 # XResource extension: lets clients get data about per-client resource usage
diff --git a/Xext/xvdix.h b/Xext/xvdix.h
index e9c22bf..fc35935 100644
--- a/Xext/xvdix.h
+++ b/Xext/xvdix.h
@@ -55,7 +55,6 @@ SOFTWARE.
 #include scrnintstr.h
 #include X11/extensions/Xvproto.h
 
-#ifndef XorgLoader
 extern _X_EXPORT unsigned long XvExtensionGeneration;
 extern _X_EXPORT unsigned long XvScreenGeneration;
 extern _X_EXPORT unsigned long XvResourceGeneration;
@@ -70,7 +69,12 @@ extern _X_EXPORT RESTYPE XvRTGrab;
 extern _X_EXPORT RESTYPE XvRTVideoNotify;
 extern _X_EXPORT RESTYPE XvRTVideoNotifyList;
 extern _X_EXPORT RESTYPE XvRTPortNotify;
-#endif
+
+extern DevPrivateKey (*XvGetScreenKeyProc)(void);
+extern unsigned long (*XvGetRTPortProc)(void);
+extern int (*XvScreenInitProc)(ScreenPtr);
+typedef struct _XvMCAdaptor *XvMCAdaptorPtr;
+extern int (*XvMCScreenInitProc)(ScreenPtr, int, XvMCAdaptorPtr);
 
 typedef struct {
   int numerator;
@@ -269,6 +273,7 @@ extern _X_EXPORT int XvdiPreemptVideo(ClientPtr, XvPortPtr, 
DrawablePtr);
 extern _X_EXPORT int XvdiMatchPort(XvPortPtr, DrawablePtr);
 extern _X_EXPORT int XvdiGrabPort(ClientPtr, XvPortPtr, Time, int *);
 extern _X_EXPORT int XvdiUngrabPort( ClientPtr, XvPortPtr, Time);
+extern void XvRegister(void);
 #endif /* XorgLoader */
 
 #endif /* XVDIX_H */
diff --git a/Xext/xvmain.c b/Xext/xvmain.c
index d21a56c..c86f911 100644
--- a/Xext/xvmain.c
+++ b/Xext/xvmain.c
@@ -199,6 +199,21 @@ XvExtensionInit(void)
 }
 }
 
+DevPrivateKey (*XvGetScreenKeyProc)(void) = NULL;
+unsigned long (*XvGetRTPortProc)(void) = NULL;
+int (*XvScreenInitProc)(ScreenPtr) = NULL;
+int (*XvMCScreenInitProc)(ScreenPtr, int, XvMCAdaptorPtr) = NULL;
+extern int XvMCScreenInit(ScreenPtr, int, XvMCAdaptorPtr);
+
+void
+XvRegister(void)
+{
+XvScreenInitProc = XvScreenInit;
+XvGetScreenKeyProc = XvGetScreenKey;
+XvGetRTPortProc = XvGetRTPort;
+XvMCScreenInitProc = XvMCScreenInit;
+}
+
 static Bool
 CreateResourceTypes(void)
 
diff --git a/Xext/xvmcext.h b/Xext/xvmcext.h
index 5b43126..b6c7749 100644
--- a/Xext/xvmcext.h
+++ b/Xext/xvmcext.h
@@ -87,7 +87,7 @@ typedef void (*XvMCDestroySubpictureProcPtr) (
 );
 
 
-typedef struct {
+typedef struct _XvMCAdaptor {
   XvAdaptorPtr xv_adaptor;
   int  num_surfaces;
   XvMCSurfaceInfoPtr   *surfaces;
@@ -101,7 +101,6 @@ typedef struct {
   XvMCDestroySubpictureProcPtr  DestroySubpicture;
 } XvMCAdaptorRec, *XvMCAdaptorPtr;
 
-#ifndef XorgLoader
 extern _X_EXPORT void XvMCExtensionInit(void);
 
 extern _X_EXPORT int XvMCScreenInit(ScreenPtr pScreen,
@@ -113,6 +112,4 @@ extern _X_EXPORT XvImagePtr XvMCFindXvImage(XvPortPtr 
pPort, CARD32 id);
 extern _X_EXPORT int xf86XvMCRegisterDRInfo(ScreenPtr pScreen, char *name,
   char *busID, int major, int minor, 
   int patchLevel);
-#endif
-
 #endif /* _XVMC_H */
diff --git a/hw/kdrive/src/kxv.c b/hw/kdrive/src/kxv.c
index 50dc235..5162ea1 100644
--- a/hw/kdrive/src/kxv.c
+++ b/hw/kdrive/src/kxv.c
@@ -109,10 +109,6 @@ static DevPrivateKey KdXvScreenKey;
 static unsigned long KdXVGeneration = 0;
 static unsigned long PortResource = 0;
 
-DevPrivateKey (*XvGetScreenKeyProc)(void) = XvGetScreenKey;
-unsigned long (*XvGetRTPortProc)(void) = XvGetRTPort;
-int (*XvScreenInitProc)(ScreenPtr) = XvScreenInit;
-
 #define GET_XV_SCREEN(pScreen) ((XvScreenPtr) \
 dixLookupPrivate((pScreen)-devPrivates, KdXvScreenKey))
 
diff 

[PATCH 20/37] Xext: Only build one library

2011-06-28 Thread Daniel Stone
Now that libXextmodule.la is both empty and unused, we can just build
the one libXext.la for everyone, rather than having Xorg be special and
unique.

Signed-off-by: Daniel Stone dan...@fooishbar.org
---
 Xext/Makefile.am |   28 ++--
 configure.ac |3 +--
 2 files changed, 3 insertions(+), 28 deletions(-)

diff --git a/Xext/Makefile.am b/Xext/Makefile.am
index 86d40e1..2488bbc 100644
--- a/Xext/Makefile.am
+++ b/Xext/Makefile.am
@@ -1,16 +1,4 @@
-# libXext.la:includes all extensions and should be linked into Xvfb,
-#Xnest, Xdmx and Xprt
-# libXextbuiltin.la: includes those extensions that are built directly into
-#Xorg by default
-# libXextmodule.la:  includes those extensions that are built into a module
-#that Xorg loads
-if XORG
-noinst_LTLIBRARIES = libXext.la libXextbuiltin.la libXextmodule.la
-else
 noinst_LTLIBRARIES = libXext.la
-endif
-
-INCLUDES = -I$(top_srcdir)/hw/xfree86/dixmods/extmod
 
 AM_CFLAGS = $(DIX_CFLAGS)
 
@@ -32,10 +20,6 @@ BUILTIN_SRCS =   \
xtest.c
 BUILTIN_LIBS =
 
-# Sources always included in libXextmodule.la  libXext.la. That's right, zero.
-MODULE_SRCS =
-MODULE_LIBS =
-
 # Optional sources included if extension enabled by configure.ac rules
 
 # MIT Shared Memory extension
@@ -109,16 +93,8 @@ endif
 
 # Now take all of the above, mix well, bake for 10 minutes and get libXext*.la
 
-libXext_la_SOURCES =   $(BUILTIN_SRCS) $(MODULE_SRCS)
-libXext_la_LIBADD =$(BUILTIN_LIBS) $(MODULE_LIBS)
-
-if XORG
-libXextbuiltin_la_SOURCES =$(BUILTIN_SRCS)
-libXextbuiltin_la_LIBADD = $(BUILTIN_LIBS)
-
-libXextmodule_la_SOURCES = $(MODULE_SRCS)
-libXextmodule_la_LIBADD =  $(MODULE_LIBS)
-endif
+libXext_la_SOURCES =   $(BUILTIN_SRCS)
+libXext_la_LIBADD =$(BUILTIN_LIBS)
 
 EXTRA_DIST = \
$(MITSHM_SRCS) \
diff --git a/configure.ac b/configure.ac
index 61a6a2c..a4e2ea1 100644
--- a/configure.ac
+++ b/configure.ac
@@ -765,7 +765,6 @@ dnl Extension section
 dnl ---
 XEXT_INC='-I$(top_srcdir)/Xext'
 XEXT_LIB='$(top_builddir)/Xext/libXext.la'
-XEXTXORG_LIB='$(top_builddir)/Xext/libXextbuiltin.la'
 
 dnl Optional modules
 VIDEOPROTO=videoproto
@@ -1517,7 +1516,7 @@ if test x$XORG = xyes; then
XORG_OSINCS='-I$(top_srcdir)/hw/xfree86/os-support 
-I$(top_srcdir)/hw/xfree86/os-support/bus -I$(top_srcdir)/os'
XORG_INCS=$XORG_DDXINCS $XORG_OSINCS
XORG_CFLAGS=$XORGSERVER_CFLAGS -DHAVE_XORG_CONFIG_H
-   XORG_LIBS=$COMPOSITE_LIB $FIXES_LIB $XEXTXORG_LIB $DBE_LIB $RECORD_LIB 
$GLX_LIBS $RANDR_LIB $RENDER_LIB $DAMAGE_LIB $MIEXT_SYNC_LIB $MIEXT_DAMAGE_LIB 
$MIEXT_SHADOW_LIB $XI_LIB $XKB_LIB
+   XORG_LIBS=$COMPOSITE_LIB $FIXES_LIB $XEXT_LIB $DBE_LIB $RECORD_LIB 
$GLX_LIBS $RANDR_LIB $RENDER_LIB $DAMAGE_LIB $MIEXT_SYNC_LIB $MIEXT_DAMAGE_LIB 
$MIEXT_SHADOW_LIB $XI_LIB $XKB_LIB
 
dnl ==
dnl symbol visibility
-- 
1.7.5.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


[PATCH 07/37] Add xf86ExtensionInit for DDX extension configuration

2011-06-28 Thread Daniel Stone
xf86ExtensionInit is called after configuration file parsing, so it can
perform the two parts of extension initialisation currently done by
extmod: enabling and disabling of extensions through an 'omit' option,
and SELinux configuration.

Signed-off-by: Daniel Stone dan...@fooishbar.org
---
 hw/xfree86/common/Makefile.am  |2 +-
 hw/xfree86/common/xf86.h   |3 ++
 hw/xfree86/common/xf86Extensions.c |   56 
 hw/xfree86/common/xf86Init.c   |2 +
 4 files changed, 62 insertions(+), 1 deletions(-)
 create mode 100644 hw/xfree86/common/xf86Extensions.c

diff --git a/hw/xfree86/common/Makefile.am b/hw/xfree86/common/Makefile.am
index c031d4b..5853661 100644
--- a/hw/xfree86/common/Makefile.am
+++ b/hw/xfree86/common/Makefile.am
@@ -36,7 +36,7 @@ libcommon_la_SOURCES = xf86Configure.c xf86ShowOpts.c 
xf86Bus.c xf86Config.c \
   xf86Option.c xf86Init.c xf86VGAarbiter.c \
   xf86VidMode.c xf86fbman.c xf86cmap.c \
   xf86Helper.c xf86PM.c xf86Xinput.c xisb.c \
-  xf86Mode.c xorgHelper.c \
+  xf86Mode.c xorgHelper.c xf86Extensions.c \
   $(XVSOURCES) $(BUSSOURCES) $(RANDRSOURCES)
 nodist_libcommon_la_SOURCES = xf86DefModeSet.c xf86Build.h
 libcommon_la_LIBADD = $(top_builddir)/config/libconfig.la
diff --git a/hw/xfree86/common/xf86.h b/hw/xfree86/common/xf86.h
index 54332e3..e29e958 100644
--- a/hw/xfree86/common/xf86.h
+++ b/hw/xfree86/common/xf86.h
@@ -348,6 +348,9 @@ extern _X_EXPORT Bool 
xf86RandRSetNewVirtualAndDimensions(ScreenPtr pScreen,
 
 extern _X_EXPORT Bool VidModeExtensionInit(ScreenPtr pScreen);
 
+/* xf86Extensions.c */
+extern void xf86ExtensionInit(void);
+
 #endif /* _NO_XF86_PROTOTYPES */
 
 #endif /* _XF86_H */
diff --git a/hw/xfree86/common/xf86Extensions.c 
b/hw/xfree86/common/xf86Extensions.c
new file mode 100644
index 000..b430d32
--- /dev/null
+++ b/hw/xfree86/common/xf86Extensions.c
@@ -0,0 +1,56 @@
+/*
+ * Copyright © 2011 Daniel Stone
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a
+ * copy of this software and associated documentation files (the Software),
+ * to deal in the Software without restriction, including without limitation
+ * the rights to use, copy, modify, merge, publish, distribute, sublicense,
+ * and/or sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice (including the next
+ * paragraph) shall be included in all copies or substantial portions of the
+ * Software.
+ *
+ * THE SOFTWARE IS PROVIDED AS IS, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
+ * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+ * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
+ * DEALINGS IN THE SOFTWARE.
+ *
+ * Author: Daniel Stone dan...@fooishbar.org
+ */
+
+#ifdef HAVE_XORG_CONFIG_H
+#include xorg-config.h
+#endif
+
+#include extension.h
+#include globals.h
+
+#include xf86.h
+#include xf86Config.h
+#include xf86Opt.h
+
+void
+xf86ExtensionInit(void)
+{
+if (xf86configptr-conf_modules) {
+XF86LoadPtr modp = xf86configptr-conf_modules-mod_load_lst;
+for (modp = xf86configptr-conf_modules-mod_load_lst; modp;
+ modp = modp-list.next) {
+XF86OptionPtr opt;
+if (strcmp(modp-load_name, extmod) != 0)
+continue;
+for (opt = modp-load_opt; opt; opt = opt-list.next) {
+if (strncmp(opt-opt_name, omit, 4) != 0 ||
+strlen(opt-opt_name)  5)
+continue;
+if (EnableDisableExtension(opt-opt_name + 4, FALSE))
+xf86MarkOptionUsed(opt);
+}
+   }
+}
+}
diff --git a/hw/xfree86/common/xf86Init.c b/hw/xfree86/common/xf86Init.c
index 53f763a..5535396 100644
--- a/hw/xfree86/common/xf86Init.c
+++ b/hw/xfree86/common/xf86Init.c
@@ -404,6 +404,8 @@ InitOutput(ScreenInfo *pScreenInfo, int argc, char **argv)
 xf86OSPMClose = xf86OSPMOpen();
 #endif
 
+xf86ExtensionInit();
+
 /* Load all modules specified explicitly in the config file */
 if ((modulelist = xf86ModulelistFromConfig(optionlist))) {
   xf86LoadModules(modulelist, optionlist);
-- 
1.7.5.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

[PATCH 04/37] Replace INITARGS with void

2011-06-28 Thread Daniel Stone
From: Tomas Carnecky t...@dbservice.com

It was defined to void anyway. Everyone but panoramix used INITARGS, but
PanoramiXExtensionInit() had hardcoded argc/argv. Replace that with void
as well.

Signed-off-by: Tomas Carnecky t...@dbservice.com
Reviewed-by: Daniel Stone dan...@fooishbar.org
---
 Xext/bigreq.c|4 +-
 Xext/dpms.c  |2 +-
 Xext/saver.c |2 +-
 Xext/security.c  |2 +-
 Xext/shm.c   |2 +-
 Xext/xcmisc.c|2 +-
 Xext/xres.c  |2 +-
 Xext/xselinux_ext.c  |2 +-
 Xext/xtest.c |2 +-
 hw/xfree86/common/xf86Module.h   |2 +-
 hw/xfree86/dixmods/dbemodule.c   |2 +-
 hw/xfree86/dixmods/extmod/modinit.h  |   40 ++
 hw/xfree86/dixmods/extmod/xf86dga2.c |4 +-
 hw/xfree86/dixmods/recordmod.c   |2 +-
 hw/xfree86/dri/drimodule.c   |2 +-
 mi/miinitext.c   |   63 -
 16 files changed, 65 insertions(+), 70 deletions(-)

diff --git a/Xext/bigreq.c b/Xext/bigreq.c
index a540bcb..ecfbe93 100644
--- a/Xext/bigreq.c
+++ b/Xext/bigreq.c
@@ -40,7 +40,7 @@ from The Open Group.
 #include opaque.h
 #include modinit.h
 
-void BigReqExtensionInit(INITARGS);
+void BigReqExtensionInit(void);
 
 static int
 ProcBigReqDispatch (ClientPtr client)
@@ -70,7 +70,7 @@ ProcBigReqDispatch (ClientPtr client)
 }
 
 void
-BigReqExtensionInit(INITARGS)
+BigReqExtensionInit(void)
 {
 AddExtension(XBigReqExtensionName, 0, 0,
 ProcBigReqDispatch, ProcBigReqDispatch,
diff --git a/Xext/dpms.c b/Xext/dpms.c
index 33a6e26..32f33b3 100644
--- a/Xext/dpms.c
+++ b/Xext/dpms.c
@@ -371,7 +371,7 @@ SProcDPMSDispatch (ClientPtr client)
 }
 
 void
-DPMSExtensionInit(INITARGS)
+DPMSExtensionInit(void)
 {
 AddExtension(DPMSExtensionName, 0, 0,
 ProcDPMSDispatch, SProcDPMSDispatch,
diff --git a/Xext/saver.c b/Xext/saver.c
index 1888603..0c4426c 100644
--- a/Xext/saver.c
+++ b/Xext/saver.c
@@ -1480,7 +1480,7 @@ SProcScreenSaverDispatch (ClientPtr client)
 }
 
 void
-ScreenSaverExtensionInit(INITARGS)
+ScreenSaverExtensionInit(void)
 {
 ExtensionEntry *extEntry;
 inti;
diff --git a/Xext/security.c b/Xext/security.c
index 8673880..adec862 100644
--- a/Xext/security.c
+++ b/Xext/security.c
@@ -1089,7 +1089,7 @@ SecurityResetProc(
  */
 
 void
-SecurityExtensionInit(INITARGS)
+SecurityExtensionInit(void)
 {
 ExtensionEntry *extEntry;
 int ret = TRUE;
diff --git a/Xext/shm.c b/Xext/shm.c
index b08af82..a67ce8b 100644
--- a/Xext/shm.c
+++ b/Xext/shm.c
@@ -1275,7 +1275,7 @@ SProcShmDispatch (ClientPtr client)
 }
 
 void
-ShmExtensionInit(INITARGS)
+ShmExtensionInit(void)
 {
 ExtensionEntry *extEntry;
 int i;
diff --git a/Xext/xcmisc.c b/Xext/xcmisc.c
index 378afcc..ea85570 100644
--- a/Xext/xcmisc.c
+++ b/Xext/xcmisc.c
@@ -199,7 +199,7 @@ SProcXCMiscDispatch (ClientPtr client)
 }
 
 void
-XCMiscExtensionInit(INITARGS)
+XCMiscExtensionInit(void)
 {
 AddExtension(XCMiscExtensionName, 0, 0,
 ProcXCMiscDispatch, SProcXCMiscDispatch,
diff --git a/Xext/xres.c b/Xext/xres.c
index 06639a2..8d0ef30 100644
--- a/Xext/xres.c
+++ b/Xext/xres.c
@@ -375,7 +375,7 @@ SProcResDispatch (ClientPtr client)
 }
 
 void
-ResExtensionInit(INITARGS)
+ResExtensionInit(void)
 {
 (void) AddExtension(XRES_NAME, 0, 0,
 ProcResDispatch, SProcResDispatch,
diff --git a/Xext/xselinux_ext.c b/Xext/xselinux_ext.c
index 374571c..5ab35e0 100644
--- a/Xext/xselinux_ext.c
+++ b/Xext/xselinux_ext.c
@@ -700,7 +700,7 @@ SELinuxResetProc(ExtensionEntry *extEntry)
 }
 
 void
-SELinuxExtensionInit(INITARGS)
+SELinuxExtensionInit(void)
 {
 ExtensionEntry *extEntry;
 
diff --git a/Xext/xtest.c b/Xext/xtest.c
index daa6430..2aa27de 100644
--- a/Xext/xtest.c
+++ b/Xext/xtest.c
@@ -680,7 +680,7 @@ GetXTestDevice(DeviceIntPtr master)
 }
 
 void
-XTestExtensionInit(INITARGS)
+XTestExtensionInit(void)
 {
 AddExtension(XTestExtensionName, 0, 0,
 ProcXTestDispatch, SProcXTestDispatch,
diff --git a/hw/xfree86/common/xf86Module.h b/hw/xfree86/common/xf86Module.h
index 2a5c805..599f25f 100644
--- a/hw/xfree86/common/xf86Module.h
+++ b/hw/xfree86/common/xf86Module.h
@@ -171,7 +171,7 @@ typedef struct {
 
 #define INITARGS void
 
-typedef void (*InitExtension)(INITARGS);
+typedef void (*InitExtension)(void);
 
 typedef struct {
 InitExtension  initFunc;
diff --git a/hw/xfree86/dixmods/dbemodule.c b/hw/xfree86/dixmods/dbemodule.c
index 7363988..436a7b1 100644
--- a/hw/xfree86/dixmods/dbemodule.c
+++ b/hw/xfree86/dixmods/dbemodule.c
@@ -7,7 +7,7 @@
 
 static MODULESETUPPROTO(dbeSetup);
 
-extern void DbeExtensionInit(INITARGS);
+extern void DbeExtensionInit(void);
 
 static ExtensionModule dbeExt = {
 DbeExtensionInit,

[PATCH 12/37] Move XRes from extmod to built-in

2011-06-28 Thread Daniel Stone
From: Tomas Carnecky t...@dbservice.com

Always build XRes support into the core server, rather than letting it
languish in extmod.

Signed-off-by: Tomas Carnecky t...@dbservice.com
Reviewed-by: Daniel Stone dan...@fooishbar.org
---
 Xext/Makefile.am|2 +-
 Xext/xres.c |2 ++
 hw/xfree86/dixmods/extmod/modinit.c |9 -
 mi/miinitext.c  |3 +++
 4 files changed, 6 insertions(+), 10 deletions(-)

diff --git a/Xext/Makefile.am b/Xext/Makefile.am
index adea06e..04e1b36 100644
--- a/Xext/Makefile.am
+++ b/Xext/Makefile.am
@@ -52,7 +52,7 @@ endif
 # XResource extension: lets clients get data about per-client resource usage
 RES_SRCS = xres.c
 if RES
-MODULE_SRCS  += $(RES_SRCS)
+BUILTIN_SRCS  += $(RES_SRCS)
 endif
 
 # MIT ScreenSaver extension
diff --git a/Xext/xres.c b/Xext/xres.c
index 8d0ef30..c9487a3 100644
--- a/Xext/xres.c
+++ b/Xext/xres.c
@@ -23,6 +23,8 @@
 #include modinit.h
 #include protocol-versions.h
 
+extern void ResExtensionInit(void);
+
 static int
 ProcXResQueryVersion (ClientPtr client)
 {
diff --git a/hw/xfree86/dixmods/extmod/modinit.c 
b/hw/xfree86/dixmods/extmod/modinit.c
index 6625f26..9a3b811 100644
--- a/hw/xfree86/dixmods/extmod/modinit.c
+++ b/hw/xfree86/dixmods/extmod/modinit.c
@@ -81,15 +81,6 @@ static ExtensionModule extensionModules[] = {
 NULL
 },
 #endif
-#ifdef RES
-{
-ResExtensionInit,
-XRES_NAME, 
-noResExtension,
-NULL,
-NULL
-},
-#endif
 {  /* DON'T delete this entry ! */
NULL,
NULL,
diff --git a/mi/miinitext.c b/mi/miinitext.c
index 79786aa..4e76c8e 100644
--- a/mi/miinitext.c
+++ b/mi/miinitext.c
@@ -530,6 +530,9 @@ static ExtensionModule staticExtensions[] = {
 #ifdef DPMSExtension
 { DPMSExtensionInit, DPMSExtensionName, noDPMSExtension, NULL },
 #endif
+#ifdef RES
+{ ResExtensionInit, XRES_NAME, noResExtension, NULL },
+#endif
 { NULL, NULL, NULL, NULL, NULL }
 };
 
-- 
1.7.5.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


[PATCH 29/37] Remove Xorg-specific extensions from non-Xorg miinitext

2011-06-28 Thread Daniel Stone
miinitext.c had a completely separate codepath for non-Xorg servers,
which included tests for Xorg-specific extensions such as
XFree86-VidMode, which were external even to the Xorg DDX.  So we can
just remove them, and the associated #undefs.

Signed-off-by: Daniel Stone dan...@fooishbar.org
---
 mi/miinitext.c |   32 +---
 1 files changed, 1 insertions(+), 31 deletions(-)

diff --git a/mi/miinitext.c b/mi/miinitext.c
index 544dce2..9d359e7 100644
--- a/mi/miinitext.c
+++ b/mi/miinitext.c
@@ -84,9 +84,6 @@ SOFTWARE.
 #include dmx-config.h
 #undef XV
 #undef DBE
-#undef XF86VIDMODE
-#undef XFreeXDGA
-#undef XF86DRI
 #undef SCREENSAVER
 #undef RANDR
 #undef XFIXES
@@ -103,17 +100,10 @@ SOFTWARE.
 
 #ifdef HAVE_KDRIVE_CONFIG_H
 #include kdrive-config.h
-/* there must be a better way... */
-#undef XFreeXDGA
-#undef XF86DRI
-#undef XF86VIDMODE
 #endif
 
 #ifdef HAVE_XGL_CONFIG_H
 #include xgl-config.h
-#undef XFreeXDGA
-#undef XF86DRI
-#undef XF86VIDMODE
 #endif
 
 #include misc.h
@@ -155,15 +145,6 @@ extern Bool noResExtension;
 #ifdef XF86BIGFONT
 extern Bool noXFree86BigfontExtension;
 #endif
-#ifdef XFreeXDGA
-extern Bool noXFree86DGAExtension;
-#endif
-#ifdef XF86DRI
-extern Bool noXFree86DRIExtension;
-#endif
-#ifdef XF86VIDMODE
-extern Bool noXFree86VidModeExtension;
-#endif
 #ifdef XFIXES
 extern Bool noXFixesExtension;
 #endif
@@ -469,17 +450,9 @@ InitExtensions(int argc, char *argv[])
 if (!noScreenSaverExtension) ScreenSaverExtensionInit ();
 #endif
 
-#if !defined(NO_HW_ONLY_EXTS)
-#if defined(XF86VIDMODE)
-if (!noXFree86VidModeExtension) XFree86VidModeExtensionInit();
-#endif
-#if defined(XFreeXDGA)
-if (!noXFree86DGAExtension) XFree86DGAExtensionInit();
-#endif
-#if defined(DPMSExtension)
+#if !defined(NO_HW_ONLY_EXTS)  defined(DPMSExtension)
 if (!noDPMSExtension) DPMSExtensionInit();
 #endif
-#endif
 
 #ifdef XV
 if (!noXvExtension) {
@@ -496,9 +469,6 @@ InitExtensions(int argc, char *argv[])
 #ifdef DBE
 if (!noDbeExtension) DbeExtensionInit();
 #endif
-#if !defined(NO_HW_ONLY_EXTS)  defined(XF86DRI)
-if (!noXFree86DRIExtension) XFree86DRIExtensionInit();
-#endif
 #ifdef DMXEXT
 DMXExtensionInit(); /* server-specific extension, cannot be disabled */
 #endif
-- 
1.7.5.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


[PATCH 19/37] Remove the last remnants of extmod

2011-06-28 Thread Daniel Stone
extmod was originally a big pointless module.  Now it's an empty,
pointless module.  This commit makes it unexist.

Signed-off-by: Daniel Stone dan...@fooishbar.org
---
 Xext/bigreq.c |1 -
 Xext/dpms.c   |1 -
 Xext/panoramiX.c  |3 +-
 Xext/saver.c  |6 ++-
 Xext/security.c   |1 -
 Xext/shape.c  |1 -
 Xext/shm.c|3 +-
 Xext/sync.c   |2 -
 Xext/xcmisc.c |2 +-
 Xext/xres.c   |1 -
 Xext/xselinux_ext.c   |1 -
 Xext/xtest.c  |4 +-
 configure.ac  |1 -
 hw/xfree86/common/xf86Config.c|1 -
 hw/xfree86/common/xf86DGA.c   |2 -
 hw/xfree86/dixmods/Makefile.am|2 -
 hw/xfree86/dixmods/extmod/Makefile.am |   13 -
 hw/xfree86/dixmods/extmod/modinit.c   |   61 -
 hw/xfree86/dixmods/extmod/modinit.h   |   81 -
 hw/xfree86/loader/loadmod.c   |1 +
 20 files changed, 11 insertions(+), 177 deletions(-)
 delete mode 100644 hw/xfree86/dixmods/extmod/Makefile.am
 delete mode 100644 hw/xfree86/dixmods/extmod/modinit.c
 delete mode 100644 hw/xfree86/dixmods/extmod/modinit.h

diff --git a/Xext/bigreq.c b/Xext/bigreq.c
index ecfbe93..2a3becd 100644
--- a/Xext/bigreq.c
+++ b/Xext/bigreq.c
@@ -38,7 +38,6 @@ from The Open Group.
 #include extnsionst.h
 #include X11/extensions/bigreqsproto.h
 #include opaque.h
-#include modinit.h
 
 void BigReqExtensionInit(void);
 
diff --git a/Xext/dpms.c b/Xext/dpms.c
index d09fd0a..2eb28ef 100644
--- a/Xext/dpms.c
+++ b/Xext/dpms.c
@@ -39,7 +39,6 @@ Equipment Corporation.
 #include opaque.h
 #include X11/extensions/dpmsproto.h
 #include dpmsproc.h
-#include modinit.h
 
 extern void DPMSExtensionInit(void);
 
diff --git a/Xext/panoramiX.c b/Xext/panoramiX.c
index 9481438..277b637 100644
--- a/Xext/panoramiX.c
+++ b/Xext/panoramiX.c
@@ -59,7 +59,6 @@ Equipment Corporation.
 #ifdef COMPOSITE
 #include compint.h
 #endif
-#include modinit.h
 #include protocol-versions.h
 
 #ifdef GLXPROXY
@@ -68,6 +67,8 @@ extern VisualPtr glxMatchVisual(ScreenPtr pScreen,
ScreenPtr pMatchScreen);
 #endif
 
+extern void PanoramiXExtensionInit(void);
+
 /*
  * PanoramiX data declarations
  */
diff --git a/Xext/saver.c b/Xext/saver.c
index 0c4426c..0544506 100644
--- a/Xext/saver.c
+++ b/Xext/saver.c
@@ -58,8 +58,6 @@ in this Software without prior written authorization from the 
X Consortium.
 
 #include stdio.h
 
-#include modinit.h
-
 static int ScreenSaverEventBase = 0;
 
 
@@ -94,6 +92,10 @@ static void SScreenSaverNotifyEvent (
xScreenSaverNotifyEvent * /* to */
);
 
+extern void ScreenSaverExtensionInit (
+   void
+   );
+
 static RESTYPE SuspendType;  /* resource type for suspension records */
 
 typedef struct _ScreenSaverSuspension *ScreenSaverSuspensionPtr;
diff --git a/Xext/security.c b/Xext/security.c
index adec862..5e0a734 100644
--- a/Xext/security.c
+++ b/Xext/security.c
@@ -38,7 +38,6 @@ in this Software without prior written authorization from The 
Open Group.
 #include xacestr.h
 #include securitysrv.h
 #include X11/extensions/securproto.h
-#include modinit.h
 #include protocol-versions.h
 
 /* Extension stuff */
diff --git a/Xext/shape.c b/Xext/shape.c
index 115fc07..5f471d3 100644
--- a/Xext/shape.c
+++ b/Xext/shape.c
@@ -44,7 +44,6 @@ in this Software without prior written authorization from The 
Open Group.
 #include X11/extensions/shapeproto.h
 #include regionstr.h
 #include gcstruct.h
-#include modinit.h
 #include protocol-versions.h
 
 typedefRegionPtr (*CreateDftPtr)(
diff --git a/Xext/shm.c b/Xext/shm.c
index a67ce8b..09371f0 100644
--- a/Xext/shm.c
+++ b/Xext/shm.c
@@ -88,8 +88,6 @@ in this Software without prior written authorization from The 
Open Group.
 #include panoramiXsrv.h
 #endif
 
-#include modinit.h
-
 typedef struct _ShmDesc {
 struct _ShmDesc *next;
 int shmid;
@@ -119,6 +117,7 @@ static void SShmCompletionEvent(
 );
 
 static Bool ShmDestroyPixmap (PixmapPtr pPixmap);
+extern void ShmExtensionInit(void);
 
 
 static unsigned char ShmReqCode;
diff --git a/Xext/sync.c b/Xext/sync.c
index 36dd278..8f604d5 100644
--- a/Xext/sync.c
+++ b/Xext/sync.c
@@ -76,8 +76,6 @@ PERFORMANCE OF THIS SOFTWARE.
 #include sys/time.h
 #endif
 
-#include modinit.h
-
 /*
  * Local Global Variables
  */
diff --git a/Xext/xcmisc.c b/Xext/xcmisc.c
index ea85570..9357941 100644
--- a/Xext/xcmisc.c
+++ b/Xext/xcmisc.c
@@ -38,7 +38,6 @@ from The Open Group.
 #include extnsionst.h
 #include swaprep.h
 #include X11/extensions/xcmiscproto.h
-#include modinit.h
 
 #if HAVE_STDINT_H
 #include stdint.h
@@ -46,6 +45,7 @@ from The Open Group.
 #define UINT32_MAX 0xU
 #endif
 
+extern 

[PATCH 21/37] Move DRI1 from external module to built-in

2011-06-28 Thread Daniel Stone
Rather than building the tiny amount of code required for XFree86-DRI as
an external module, build it in if it's enabled at configure time.

Signed-off-by: Daniel Stone dan...@fooishbar.org
---
 configure.ac   |2 +-
 hw/xfree86/Makefile.am |2 +
 hw/xfree86/common/xf86Config.c |3 -
 hw/xfree86/common/xf86Extensions.c |   13 +
 hw/xfree86/dri/Makefile.am |5 +--
 hw/xfree86/dri/drimodule.c |   93 
 hw/xfree86/loader/Makefile.am  |4 +-
 hw/xfree86/loader/loadmod.c|1 +
 hw/xfree86/sdksyms.sh  |2 -
 9 files changed, 20 insertions(+), 105 deletions(-)
 delete mode 100644 hw/xfree86/dri/drimodule.c

diff --git a/configure.ac b/configure.ac
index a4e2ea1..33dfb2b 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1569,7 +1569,7 @@ if test x$XORG = xyes; then
AC_CHECK_FUNCS([pci_device_vgaarb_init])
LIBS=$SAVE_LIBS
CFLAGS=$SAVE_CFLAGS
-   XORG_SYS_LIBS=$XORG_SYS_LIBS $PCIACCESS_LIBS $GLX_SYS_LIBS
+   XORG_SYS_LIBS=$XORG_SYS_LIBS $PCIACCESS_LIBS $GLX_SYS_LIBS 
$LIBDRM_LIBS
XORG_CFLAGS=$XORG_CFLAGS $PCIACCESS_CFLAGS
 
case $host_os in
diff --git a/hw/xfree86/Makefile.am b/hw/xfree86/Makefile.am
index e3ef14f..71b2b9e 100644
--- a/hw/xfree86/Makefile.am
+++ b/hw/xfree86/Makefile.am
@@ -1,6 +1,7 @@
 
 if DRI
 DRI_SUBDIR = dri
+DRI_LIB = dri/libdri.la
 endif
 
 if DRI2
@@ -58,6 +59,7 @@ LOCAL_LIBS = \
 i2c/libi2c.la \
 dixmods/libxorgxkb.la \
 $(XORG_LIBS) \
+$(DRI_LIB) \
 $(top_builddir)/mi/libmi.la \
 $(top_builddir)/os/libos.la
 Xorg_LDADD = \
diff --git a/hw/xfree86/common/xf86Config.c b/hw/xfree86/common/xf86Config.c
index da1a39b..6ccbf58 100644
--- a/hw/xfree86/common/xf86Config.c
+++ b/hw/xfree86/common/xf86Config.c
@@ -112,9 +112,6 @@ static ModuleDefault ModuleDefaults[] = {
 #ifdef GLXEXT
 {.name = glx,  .toLoad = TRUE,.load_opt=NULL},
 #endif
-#ifdef XF86DRI
-{.name = dri,  .toLoad = TRUE,.load_opt=NULL},
-#endif
 #ifdef DRI2
 {.name = dri2, .toLoad = TRUE,.load_opt=NULL},
 #endif
diff --git a/hw/xfree86/common/xf86Extensions.c 
b/hw/xfree86/common/xf86Extensions.c
index 5d11e61..0f43c6b 100644
--- a/hw/xfree86/common/xf86Extensions.c
+++ b/hw/xfree86/common/xf86Extensions.c
@@ -40,6 +40,10 @@
 #include vidmodeproc.h
 #endif
 
+#ifdef XF86DRI
+extern void XFree86DRIExtensionInit(void);
+#endif
+
 /*
  * DDX-specific extensions.
  */
@@ -62,6 +66,15 @@ static ExtensionModule extensionModules[] = {
NULL
 },
 #endif
+#ifdef XF86DRI
+{
+XFree86DRIExtensionInit,
+XFree86-DRI,
+noXFree86DRIExtension,
+NULL,
+NULL
+},
+#endif
 };
 
 void
diff --git a/hw/xfree86/dri/Makefile.am b/hw/xfree86/dri/Makefile.am
index a7b491c..d611f66 100644
--- a/hw/xfree86/dri/Makefile.am
+++ b/hw/xfree86/dri/Makefile.am
@@ -1,4 +1,4 @@
-libdri_la_LTLIBRARIES = libdri.la
+noinst_LTLIBRARIES = libdri.la
 libdri_la_CFLAGS = -I$(top_srcdir)/hw/xfree86/common \
-I$(top_srcdir)/hw/xfree86/os-support \
-I$(top_srcdir)/hw/xfree86/modes \
@@ -12,12 +12,9 @@ libdri_la_CFLAGS = -I$(top_srcdir)/hw/xfree86/common \
@DIX_CFLAGS@ @XORG_CFLAGS@ @DRIPROTO_CFLAGS@ \
@LIBDRM_CFLAGS@ \
@DRI_CFLAGS@
-libdri_la_LDFLAGS = -module -avoid-version @LIBDRM_LIBS@
-libdri_ladir = $(moduledir)/extensions
 libdri_la_SOURCES = \
dri.c \
dri.h \
-   drimodule.c \
dristruct.h \
sarea.h \
xf86dri.c
diff --git a/hw/xfree86/dri/drimodule.c b/hw/xfree86/dri/drimodule.c
deleted file mode 100644
index 40e3aca..000
--- a/hw/xfree86/dri/drimodule.c
+++ /dev/null
@@ -1,93 +0,0 @@
-/**
-
-Copyright 1999 Precision Insight, Inc., Cedar Park, Texas.
-All Rights Reserved.
-
-Permission is hereby granted, free of charge, to any person obtaining a
-copy of this software and associated documentation files (the
-Software), to deal in the Software without restriction, including
-without limitation the rights to use, copy, modify, merge, publish,
-distribute, sub license, and/or sell copies of the Software, and to
-permit persons to whom the Software is furnished to do so, subject to
-the following conditions:
-
-The above copyright notice and this permission notice (including the
-next paragraph) shall be included in all copies or substantial portions
-of the Software.
-
-THE SOFTWARE IS PROVIDED AS IS, WITHOUT WARRANTY OF ANY KIND, EXPRESS
-OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
-MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
-IN NO EVENT SHALL PRECISION INSIGHT AND/OR ITS SUPPLIERS BE LIABLE FOR
-ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
-TORT 

[PATCH 22/37] XFree86: DRI: Don't use per-target CFLAGS

2011-06-28 Thread Daniel Stone
AM_CFLAGS will suffice, given we only have one target in this directory.

Signed-off-by: Daniel Stone dan...@fooishbar.org
---
 hw/xfree86/dri/Makefile.am |   25 -
 1 files changed, 12 insertions(+), 13 deletions(-)

diff --git a/hw/xfree86/dri/Makefile.am b/hw/xfree86/dri/Makefile.am
index d611f66..26fa436 100644
--- a/hw/xfree86/dri/Makefile.am
+++ b/hw/xfree86/dri/Makefile.am
@@ -1,17 +1,16 @@
 noinst_LTLIBRARIES = libdri.la
-libdri_la_CFLAGS = -I$(top_srcdir)/hw/xfree86/common \
-   -I$(top_srcdir)/hw/xfree86/os-support \
-   -I$(top_srcdir)/hw/xfree86/modes \
-   -I$(top_srcdir)/hw/xfree86/ddc \
-   -I$(top_srcdir)/hw/xfree86/i2c \
-   -I$(top_srcdir)/hw/xfree86/parser \
-   -I$(top_srcdir)/hw/xfree86/ramdac \
-   -I$(top_srcdir)/hw/xfree86/os-support/bus \
-   -I$(top_srcdir)/glx \
-   -DHAVE_XORG_CONFIG_H \
-   @DIX_CFLAGS@ @XORG_CFLAGS@ @DRIPROTO_CFLAGS@ \
-   @LIBDRM_CFLAGS@ \
-   @DRI_CFLAGS@
+AM_CFLAGS = -I$(top_srcdir)/hw/xfree86/common \
+-I$(top_srcdir)/hw/xfree86/os-support \
+-I$(top_srcdir)/hw/xfree86/modes \
+-I$(top_srcdir)/hw/xfree86/ddc \
+-I$(top_srcdir)/hw/xfree86/i2c \
+-I$(top_srcdir)/hw/xfree86/parser \
+-I$(top_srcdir)/hw/xfree86/ramdac \
+-I$(top_srcdir)/hw/xfree86/os-support/bus \
+-I$(top_srcdir)/glx \
+-DHAVE_XORG_CONFIG_H \
+@DIX_CFLAGS@ @XORG_CFLAGS@ @DRIPROTO_CFLAGS@ \
+@LIBDRM_CFLAGS@ @DRI_CFLAGS@
 libdri_la_SOURCES = \
dri.c \
dri.h \
-- 
1.7.5.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


[PATCH 27/37] Loader: Move ExtensionModule types to DIX

2011-06-28 Thread Daniel Stone
In preparation for gutting loadext.c, move the ExtensionModule struct to
the DIX, and unexport ExtensionModuleList (why, why, why, why was this
ever exported in the first place, tbqh).

Signed-off-by: Daniel Stone dan...@fooishbar.org
---
 hw/xfree86/common/xf86Module.h |   13 +---
 include/extension.h|   41 +++-
 mi/miinitext.c |1 -
 3 files changed, 41 insertions(+), 14 deletions(-)

diff --git a/hw/xfree86/common/xf86Module.h b/hw/xfree86/common/xf86Module.h
index 655a256..28ddc78 100644
--- a/hw/xfree86/common/xf86Module.h
+++ b/hw/xfree86/common/xf86Module.h
@@ -42,6 +42,7 @@
 #define _XF86MODULE_H
 
 #include misc.h
+#include extension.h
 #ifndef NULL
 #define NULL ((void *)0)
 #endif
@@ -168,18 +169,6 @@ typedef struct {
 
 #define INITARGS void
 
-typedef void (*InitExtension)(void);
-
-typedef struct {
-InitExtension  initFunc;
-const char *   name;
-Bool   *disablePtr;
-InitExtension  setupFunc;  
-const char **  initDependencies;
-} ExtensionModule;
-
-extern _X_EXPORT ExtensionModule *ExtensionModuleList;
-
 /* Prototypes for Loader functions that are exported to modules */
 extern _X_EXPORT pointer LoadSubModule(pointer, const char *, const char **,
  const char **, pointer, const XF86ModReqInfo *,
diff --git a/include/extension.h b/include/extension.h
index d24301d..4bf5ad4 100644
--- a/include/extension.h
+++ b/include/extension.h
@@ -45,6 +45,33 @@ SOFTWARE.
 
 **/
 
+/*
+ * Copyright (c) 1997-2003 by The XFree86 Project, Inc.
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a
+ * copy of this software and associated documentation files (the Software),
+ * to deal in the Software without restriction, including without limitation
+ * the rights to use, copy, modify, merge, publish, distribute, sublicense,
+ * and/or sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in
+ * all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED AS IS, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
+ * THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR
+ * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
+ * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+ *
+ * Except as contained in this notice, the name of the copyright holder(s)
+ * and author(s) shall not be used in advertising or otherwise to promote
+ * the sale, use or other dealings in this Software without prior written
+ * authorization from the copyright holder(s) and author(s).
+ */
+
 #ifndef EXTENSION_H
 #define EXTENSION_H 
 
@@ -52,6 +79,18 @@ SOFTWARE.
 
 #include dixstruct.h
 
+typedef void (*InitExtension)(void);
+
+typedef struct {
+InitExtension  initFunc;
+const char *   name;
+Bool   *disablePtr;
+InitExtension  setupFunc;  
+const char **  initDependencies;
+} ExtensionModule;
+
+extern ExtensionModule *ExtensionModuleList;
+
 extern _X_EXPORT unsigned short StandardMinorOpcode(ClientPtr /*client*/);
 
 extern _X_EXPORT unsigned short MinorOpcodeOfRequest(ClientPtr /*client*/);
@@ -64,4 +103,4 @@ extern _X_EXPORT void InitExtensions(int argc, char **argv);
 
 extern _X_EXPORT void CloseDownExtensions(void);
 
-#endif /* EXTENSION_H */
+#endif
diff --git a/mi/miinitext.c b/mi/miinitext.c
index dc84319..2542c79 100644
--- a/mi/miinitext.c
+++ b/mi/miinitext.c
@@ -155,7 +155,6 @@ extern Bool noXvExtension;
 extern Bool noGEExtension;
 
 #ifndef XFree86LOADER
-typedef void (*InitExtension)(void);
 #else /* XFree86Loader */
 #include loaderProcs.h
 #endif
-- 
1.7.5.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


[PATCH 28/37] Move the remnants of loadext.c to miinitext.c

2011-06-28 Thread Daniel Stone
There was nothing XFree86-specific or loader-specific about this, aside
from using xf86MsgVerb instead of ErrorF.

Signed-off-by: Daniel Stone dan...@fooishbar.org
---
 hw/xfree86/common/xf86Module.h |1 -
 hw/xfree86/loader/Makefile.am  |1 -
 hw/xfree86/loader/loadext.c|   94 
 include/extension.h|4 +-
 mi/miinitext.c |   81 ++-
 5 files changed, 82 insertions(+), 99 deletions(-)
 delete mode 100644 hw/xfree86/loader/loadext.c

diff --git a/hw/xfree86/common/xf86Module.h b/hw/xfree86/common/xf86Module.h
index 28ddc78..f9976e9 100644
--- a/hw/xfree86/common/xf86Module.h
+++ b/hw/xfree86/common/xf86Module.h
@@ -179,7 +179,6 @@ extern _X_EXPORT pointer LoaderSymbol(const char *);
 extern _X_EXPORT char **LoaderListDirs(const char **, const char **);
 extern _X_EXPORT void LoaderFreeDirList(char **);
 extern _X_EXPORT void LoaderErrorMsg(const char *, const char *, int, int);
-extern _X_EXPORT void LoadExtension(ExtensionModule *, Bool);
 extern _X_EXPORT void LoaderGetOS(const char **name, int *major, int *minor, 
int *teeny);
 extern _X_EXPORT Bool LoaderShouldIgnoreABI(void);
 extern _X_EXPORT int LoaderGetABIVersion(const char *abiclass);
diff --git a/hw/xfree86/loader/Makefile.am b/hw/xfree86/loader/Makefile.am
index 475e3e8..2d9884d 100644
--- a/hw/xfree86/loader/Makefile.am
+++ b/hw/xfree86/loader/Makefile.am
@@ -14,7 +14,6 @@ EXTRA_DIST = \
 libloader_la_SOURCES = \
loader.c \
loaderProcs.h \
-   loadext.c \
 loadmod.c \
os.c
 
diff --git a/hw/xfree86/loader/loadext.c b/hw/xfree86/loader/loadext.c
deleted file mode 100644
index 5995ad1..000
--- a/hw/xfree86/loader/loadext.c
+++ /dev/null
@@ -1,94 +0,0 @@
-/*
- * Copyright (c) 2000 by The XFree86 Project, Inc.
- *
- * Permission is hereby granted, free of charge, to any person obtaining a
- * copy of this software and associated documentation files (the Software),
- * to deal in the Software without restriction, including without limitation
- * the rights to use, copy, modify, merge, publish, distribute, sublicense,
- * and/or sell copies of the Software, and to permit persons to whom the
- * Software is furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be included in
- * all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED AS IS, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
- * THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR
- * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
- * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
- * OTHER DEALINGS IN THE SOFTWARE.
- *
- * Except as contained in this notice, the name of the copyright holder(s)
- * and author(s) shall not be used in advertising or otherwise to promote
- * the sale, use or other dealings in this Software without prior written
- * authorization from the copyright holder(s) and author(s).
- */
-
-/* Maybe this file belongs elsewhere? */
-
-#define LOADERDECLARATIONS
-#ifdef HAVE_XORG_CONFIG_H
-#include xorg-config.h
-#endif
-
-#include loaderProcs.h
-#include misc.h
-#include xf86.h
-
-/*
- * This should be static, but miinitext wants it.  FIXME: make extension
- * initialization not completely terrible.
- */
-ExtensionModule *ExtensionModuleList = NULL;
-static int numExtensionModules = 0;
-
-static ExtensionModule *
-NewExtensionModule(void)
-{
-ExtensionModule *save = ExtensionModuleList;
-int n;
-
-/* Sanity check */
-if (!ExtensionModuleList)
-   numExtensionModules = 0;
-
-n = numExtensionModules + 1;
-ExtensionModuleList = realloc(ExtensionModuleList,
-  (n + 1) * sizeof(ExtensionModule));
-if (ExtensionModuleList == NULL) {
-   ExtensionModuleList = save;
-   return NULL;
-} else {
-   numExtensionModules++;
-   ExtensionModuleList[numExtensionModules].name = NULL;
-   return ExtensionModuleList + (numExtensionModules - 1);
-}
-}
-
-void
-LoadExtension(ExtensionModule * e, Bool builtin)
-{
-ExtensionModule *newext;
-
-if (e == NULL || e-name == NULL)
-   return;
-
-if (!(newext = NewExtensionModule()))
-   return;
-
-if (builtin)
-   xf86MsgVerb(X_INFO, 2, Initializing built-in extension %s\n,
-   e-name);
-else
-   xf86MsgVerb(X_INFO, 2, Loading extension %s\n, e-name);
-
-newext-name = e-name;
-newext-initFunc = e-initFunc;
-newext-disablePtr = e-disablePtr;
-newext-setupFunc = e-setupFunc;
-newext-initDependencies = e-initDependencies;
-
-if (e-setupFunc != NULL)
-   e-setupFunc();
-}
diff --git a/include/extension.h b/include/extension.h

[PATCH 14/37] Xv: Remove excessive module-induced indirection

2011-06-28 Thread Daniel Stone
From: Tomas Carnecky t...@dbservice.com

Xv used to call XvScreenInit and co. through function pointers, as
XvScreenInit may have been sitting on the other side of a module
boundary from xf86XvScreenInit.  Why this was so is a mystery, but make
it not so any more.

Signed-off-by: Tomas Carnecky t...@dbservice.com
Reviewed-by: Daniel Stone dan...@fooishbar.org
---
 Xext/xvdix.h|7 ---
 Xext/xvmain.c   |   15 ---
 hw/kdrive/src/kxv.c |8 
 hw/xfree86/common/xf86xv.c  |9 -
 hw/xfree86/common/xf86xvmc.c|4 ++--
 hw/xfree86/common/xf86xvmc.h|3 ---
 hw/xfree86/dixmods/extmod/modinit.h |1 -
 mi/miinitext.c  |2 +-
 8 files changed, 11 insertions(+), 38 deletions(-)

diff --git a/Xext/xvdix.h b/Xext/xvdix.h
index fc35935..f171d39 100644
--- a/Xext/xvdix.h
+++ b/Xext/xvdix.h
@@ -70,12 +70,6 @@ extern _X_EXPORT RESTYPE XvRTVideoNotify;
 extern _X_EXPORT RESTYPE XvRTVideoNotifyList;
 extern _X_EXPORT RESTYPE XvRTPortNotify;
 
-extern DevPrivateKey (*XvGetScreenKeyProc)(void);
-extern unsigned long (*XvGetRTPortProc)(void);
-extern int (*XvScreenInitProc)(ScreenPtr);
-typedef struct _XvMCAdaptor *XvMCAdaptorPtr;
-extern int (*XvMCScreenInitProc)(ScreenPtr, int, XvMCAdaptorPtr);
-
 typedef struct {
   int numerator;
   int denominator;
@@ -273,7 +267,6 @@ extern _X_EXPORT int XvdiPreemptVideo(ClientPtr, XvPortPtr, 
DrawablePtr);
 extern _X_EXPORT int XvdiMatchPort(XvPortPtr, DrawablePtr);
 extern _X_EXPORT int XvdiGrabPort(ClientPtr, XvPortPtr, Time, int *);
 extern _X_EXPORT int XvdiUngrabPort( ClientPtr, XvPortPtr, Time);
-extern void XvRegister(void);
 #endif /* XorgLoader */
 
 #endif /* XVDIX_H */
diff --git a/Xext/xvmain.c b/Xext/xvmain.c
index c86f911..d21a56c 100644
--- a/Xext/xvmain.c
+++ b/Xext/xvmain.c
@@ -199,21 +199,6 @@ XvExtensionInit(void)
 }
 }
 
-DevPrivateKey (*XvGetScreenKeyProc)(void) = NULL;
-unsigned long (*XvGetRTPortProc)(void) = NULL;
-int (*XvScreenInitProc)(ScreenPtr) = NULL;
-int (*XvMCScreenInitProc)(ScreenPtr, int, XvMCAdaptorPtr) = NULL;
-extern int XvMCScreenInit(ScreenPtr, int, XvMCAdaptorPtr);
-
-void
-XvRegister(void)
-{
-XvScreenInitProc = XvScreenInit;
-XvGetScreenKeyProc = XvGetScreenKey;
-XvGetRTPortProc = XvGetRTPort;
-XvMCScreenInitProc = XvMCScreenInit;
-}
-
 static Bool
 CreateResourceTypes(void)
 
diff --git a/hw/kdrive/src/kxv.c b/hw/kdrive/src/kxv.c
index 5162ea1..32ded06 100644
--- a/hw/kdrive/src/kxv.c
+++ b/hw/kdrive/src/kxv.c
@@ -191,16 +191,16 @@ KdXVScreenInit(
   if (KdXVGeneration != serverGeneration)
   KdXVGeneration = serverGeneration;
 
-  if(!XvGetScreenKeyProc || !XvGetRTPortProc || !XvScreenInitProc)
+  if(noXvExtension)
return FALSE;
 
   if (!dixRegisterPrivateKey(KdXVWindowKeyRec, PRIVATE_WINDOW, 0))
   return FALSE;
 
-  if(Success != (*XvScreenInitProc)(pScreen)) return FALSE;
+  if(Success != XvScreenInit(pScreen)) return FALSE;
 
-  KdXvScreenKey = (*XvGetScreenKeyProc)();
-  PortResource = (*XvGetRTPortProc)();
+  KdXvScreenKey = XvGetScreenKey();
+  PortResource = XvGetRTPort();
 
   pxvs = GET_XV_SCREEN(pScreen);
 
diff --git a/hw/xfree86/common/xf86xv.c b/hw/xfree86/common/xf86xv.c
index 50b6be5..eaf4fb3 100644
--- a/hw/xfree86/common/xf86xv.c
+++ b/hw/xfree86/common/xf86xv.c
@@ -245,18 +245,17 @@ xf86XVScreenInit(
   XF86XVScreenPtr ScreenPriv;
   XvScreenPtr pxvs;
 
-  if(num = 0 ||
- !XvGetScreenKeyProc || !XvGetRTPortProc || !XvScreenInitProc)
+  if(num = 0 || noXvExtension)
return FALSE;
 
-  if(Success != (*XvScreenInitProc)(pScreen)) return FALSE;
+  if(Success != XvScreenInit(pScreen)) return FALSE;
 
   if (!dixRegisterPrivateKey(XF86XVWindowKeyRec, PRIVATE_WINDOW, 0))
   return FALSE;
 
-  XF86XvScreenKey = (*XvGetScreenKeyProc)();
+  XF86XvScreenKey = XvGetScreenKey();
 
-  PortResource = (*XvGetRTPortProc)();
+  PortResource = XvGetRTPort();
 
   pxvs = GET_XV_SCREEN(pScreen);
 
diff --git a/hw/xfree86/common/xf86xvmc.c b/hw/xfree86/common/xf86xvmc.c
index da64d1e..e97f8a3 100644
--- a/hw/xfree86/common/xf86xvmc.c
+++ b/hw/xfree86/common/xf86xvmc.c
@@ -162,7 +162,7 @@ Bool xf86XvMCScreenInit(
XF86XvScreenKey);
int i, j;
 
-   if(!XvMCScreenInitProc) return FALSE;
+   if(noXvExtension) return FALSE;
 
if(!(pAdapt = malloc(sizeof(XvMCAdaptorRec) * num_adaptors)))
return FALSE;
@@ -210,7 +210,7 @@ Bool xf86XvMCScreenInit(
adaptors++;
}
 
-   if(Success != (*XvMCScreenInitProc)(pScreen, num_adaptors, pAdapt))
+   if(Success != XvMCScreenInit(pScreen, num_adaptors, pAdapt))
return FALSE;
 
return TRUE;
diff --git a/hw/xfree86/common/xf86xvmc.h b/hw/xfree86/common/xf86xvmc.h
index 902b4f8..e6c4de4 100644
--- a/hw/xfree86/common/xf86xvmc.h
+++ b/hw/xfree86/common/xf86xvmc.h
@@ -160,7 +160,4 @@ extern _X_EXPORT Bool xf86XvMCScreenInit(
 extern 

[PATCH 35/37] Ignore local-only requests from remote clients

2011-06-28 Thread Daniel Stone
Even though we hide local-only extensions from remote clients in the
extension list, make doubly sure they can't make a local-only request.

Signed-off-by: Daniel Stone dan...@fooishbar.org
---
 dix/dispatch.c |   11 +++
 1 files changed, 7 insertions(+), 4 deletions(-)

diff --git a/dix/dispatch.c b/dix/dispatch.c
index 192c8c3..835a4e4 100644
--- a/dix/dispatch.c
+++ b/dix/dispatch.c
@@ -427,10 +427,13 @@ Dispatch(void)
if (result  (maxBigRequestSize  2))
result = BadLength;
else {
-   result = XaceHookDispatch(client, MAJOROP);
-   if (result == Success)
-   result = (* client-requestVector[MAJOROP])(client);
-   XaceHookAuditEnd(client, result);
+ExtensionEntry *ext = GetExtensionEntry(MAJOROP);
+if (!ext || !ext-localOnly || LocalClient(client)) {
+result = XaceHookDispatch(client, MAJOROP);
+if (result == Success)
+result = (* 
client-requestVector[MAJOROP])(client);
+XaceHookAuditEnd(client, result);
+}
}
 #ifdef XSERVER_DTRACE
XSERVER_REQUEST_DONE(LookupMajorName(MAJOROP), MAJOROP,
-- 
1.7.5.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


[PATCH 26/37] Loader: Remove extension initialisation sorting

2011-06-28 Thread Daniel Stone
Extensions could previously declare initialisation dependencies on other
extensions, which would then get nicely sorted by the loader.  We only
had one user for this, GLX, which had one pointless (Composite) and one
possibly useful dependency (DBE).  As DBE is now a built-in, it will
always be sorted by GLX, so we no longer have any users for it.

Signed-off-by: Daniel Stone dan...@fooishbar.org
---
 COPYING |2 +-
 hw/xfree86/loader/loaderProcs.h |1 -
 hw/xfree86/loader/loadext.c |  346 ---
 mi/miinitext.c  |3 -
 4 files changed, 1 insertions(+), 351 deletions(-)

diff --git a/COPYING b/COPYING
index cd9e80a..7aa0df0 100644
--- a/COPYING
+++ b/COPYING
@@ -1788,7 +1788,7 @@ TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE 
USE OR
 PERFORMANCE OF THIS SOFTWARE.
 
 
-Copyright (c) 1989, 1990, 1993, 1994
+Copyright (c) 1987, 1990, 1993
  The Regents of the University of California.  All rights reserved.
 
 This code is derived from software contributed to Berkeley by
diff --git a/hw/xfree86/loader/loaderProcs.h b/hw/xfree86/loader/loaderProcs.h
index 0b67c5f..69d9189 100644
--- a/hw/xfree86/loader/loaderProcs.h
+++ b/hw/xfree86/loader/loaderProcs.h
@@ -80,7 +80,6 @@ ModuleDescPtr LoadModule(const char *, const char *, const 
char **,
 ModuleDescPtr DuplicateModule(ModuleDescPtr mod, ModuleDescPtr parent);
 void UnloadDriver(ModuleDescPtr);
 void LoaderSetPath(const char *path);
-void LoaderSortExtensions(void);
 
 void LoaderUnload(const char *, void *);
 unsigned long LoaderGetModuleVersion(ModuleDescPtr mod);
diff --git a/hw/xfree86/loader/loadext.c b/hw/xfree86/loader/loadext.c
index 4078b77..5995ad1 100644
--- a/hw/xfree86/loader/loadext.c
+++ b/hw/xfree86/loader/loadext.c
@@ -92,349 +92,3 @@ LoadExtension(ExtensionModule * e, Bool builtin)
 if (e-setupFunc != NULL)
e-setupFunc();
 }
-
-/*
- * Sort ExtensionModuleList according to the initialisation order
- * dependencies.  The code for this is taken from BSD's tsort,
- * and carries the following copyright/license:
- *
- *
- * Copyright (c) 1989, 1993, 1994
- *  The Regents of the University of California.  All rights reserved.
- *
- * This code is derived from software contributed to Berkeley by
- * Michael Rendell of Memorial University of Newfoundland.
- *
- * 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. All advertising materials mentioning features or use of this software
- *must display the following acknowledgement:
- *  This product includes software developed by the University of
- *  California, Berkeley and its contributors.
- * 4. Neither the name of the University nor the names of its contributors
- *may be used to endorse or promote products derived from this software
- *without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``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 REGENTS OR CONTRIBUTORS 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.
- */
-
-#defineNF_MARK 0x1 /* marker for cycle detection */
-#defineNF_ACYCLIC  0x2 /* this node is cycle free */
-#defineNF_NODEST   0x4 /* Unreachable */
-
-typedef struct node_str NODE;
-struct node_str {
-NODE **n_prevp;/* pointer to previous node's n_next */
-NODE *n_next;  /* next node in graph */
-NODE **n_arcs; /* array of arcs to other nodes */
-int n_narcs;   /* number of arcs in n_arcs[] */
-int n_arcsize; /* size of n_arcs[] array */
-int n_refcnt;  /* # of arcs pointing to this node */
-int n_flags;   /* NF_* */
-const char *n_name;/* name of this node */
-};
-
-static NODE *graph = NULL, **cycle_buf = NULL, **longest_cycle = NULL;
-static int longest = 0;

[PATCH 31/37] Remove initDependencies from ExtensionModule

2011-06-28 Thread Daniel Stone
This is now just an unused field, so remove it.

Signed-off-by: Daniel Stone dan...@fooishbar.org
---
 hw/xfree86/common/xf86Extensions.c |4 
 hw/xfree86/dixmods/glxmodule.c |1 -
 include/extension.h|1 -
 mi/miinitext.c |   33 -
 4 files changed, 16 insertions(+), 23 deletions(-)

diff --git a/hw/xfree86/common/xf86Extensions.c 
b/hw/xfree86/common/xf86Extensions.c
index b18c2ab..200dd0e 100644
--- a/hw/xfree86/common/xf86Extensions.c
+++ b/hw/xfree86/common/xf86Extensions.c
@@ -58,7 +58,6 @@ static ExtensionModule extensionModules[] = {
XFree86VidModeExtensionInit,
XF86VIDMODENAME,
noXFree86VidModeExtension,
-   NULL,
NULL
 },
 #endif
@@ -67,7 +66,6 @@ static ExtensionModule extensionModules[] = {
XFree86DGAExtensionInit,
XF86DGANAME,
noXFree86DGAExtension,
-   NULL,
NULL
 },
 #endif
@@ -76,7 +74,6 @@ static ExtensionModule extensionModules[] = {
 XFree86DRIExtensionInit,
 XFree86-DRI,
 noXFree86DRIExtension,
-NULL,
 NULL
 },
 #endif
@@ -85,7 +82,6 @@ static ExtensionModule extensionModules[] = {
 DRI2ExtensionInit,
 DRI2_NAME,
 noDRI2Extension,
-NULL,
 NULL
 }
 #endif
diff --git a/hw/xfree86/dixmods/glxmodule.c b/hw/xfree86/dixmods/glxmodule.c
index bd195ba..6bc3788 100644
--- a/hw/xfree86/dixmods/glxmodule.c
+++ b/hw/xfree86/dixmods/glxmodule.c
@@ -50,7 +50,6 @@ static ExtensionModule GLXExt =
 GlxExtensionInit,
 GLX,
 noGlxExtension,
-NULL,
 NULL
 };
 
diff --git a/include/extension.h b/include/extension.h
index 9bab5d3..cca00bc 100644
--- a/include/extension.h
+++ b/include/extension.h
@@ -86,7 +86,6 @@ typedef struct {
 const char *   name;
 Bool   *disablePtr;
 InitExtension  setupFunc;  
-const char **  initDependencies;
 } ExtensionModule;
 
 extern _X_EXPORT unsigned short StandardMinorOpcode(ClientPtr /*client*/);
diff --git a/mi/miinitext.c b/mi/miinitext.c
index c1141fb..6caaa50 100644
--- a/mi/miinitext.c
+++ b/mi/miinitext.c
@@ -394,35 +394,35 @@ void EnableDisableExtensionError(char *name, Bool enable)
 
 /* List of built-in (statically linked) extensions */
 static ExtensionModule staticExtensions[] = {
-{ GEExtensionInit, Generic Event Extension, noGEExtension, NULL, NULL},
-{ ShapeExtensionInit, SHAPE, NULL, NULL, NULL },
+{ GEExtensionInit, Generic Event Extension, noGEExtension, NULL },
+{ ShapeExtensionInit, SHAPE, NULL, NULL },
 #ifdef MITSHM
-{ ShmExtensionInit, SHMNAME, noMITShmExtension, NULL, NULL },
+{ ShmExtensionInit, SHMNAME, noMITShmExtension, NULL },
 #endif
-{ XInputExtensionInit, XInputExtension, NULL, NULL, NULL },
+{ XInputExtensionInit, XInputExtension, NULL, NULL },
 #ifdef XTEST
-{ XTestExtensionInit, XTestExtensionName, noTestExtensions, NULL, NULL },
+{ XTestExtensionInit, XTestExtensionName, noTestExtensions, NULL },
 #endif
-{ BigReqExtensionInit, BIG-REQUESTS, NULL, NULL, NULL },
-{ SyncExtensionInit, SYNC, NULL, NULL, NULL },
-{ XkbExtensionInit, XkbName, NULL, NULL, NULL },
-{ XCMiscExtensionInit, XC-MISC, NULL, NULL, NULL },
+{ BigReqExtensionInit, BIG-REQUESTS, NULL, NULL },
+{ SyncExtensionInit, SYNC, NULL, NULL },
+{ XkbExtensionInit, XkbName, NULL, NULL },
+{ XCMiscExtensionInit, XC-MISC, NULL, NULL },
 #ifdef XCSECURITY
-{ SecurityExtensionInit, SECURITY_EXTENSION_NAME, noSecurityExtension, 
NULL, NULL },
+{ SecurityExtensionInit, SECURITY_EXTENSION_NAME, noSecurityExtension, 
NULL },
 #endif
 #ifdef PANORAMIX
-{ PanoramiXExtensionInit, PANORAMIX_PROTOCOL_NAME, noPanoramiXExtension, 
NULL, NULL },
+{ PanoramiXExtensionInit, PANORAMIX_PROTOCOL_NAME, noPanoramiXExtension, 
NULL },
 #endif
 #ifdef XFIXES
 /* must be before Render to layer DisplayCursor correctly */
-{ XFixesExtensionInit, XFIXES, noXFixesExtension, NULL, NULL },
+{ XFixesExtensionInit, XFIXES, noXFixesExtension, NULL },
 #endif
 #ifdef XF86BIGFONT
-{ XFree86BigfontExtensionInit, XF86BIGFONTNAME, 
noXFree86BigfontExtension, NULL, NULL },
+{ XFree86BigfontExtensionInit, XF86BIGFONTNAME, 
noXFree86BigfontExtension, NULL },
 #endif
-{ RenderExtensionInit, RENDER, noRenderExtension, NULL, NULL },
+{ RenderExtensionInit, RENDER, noRenderExtension, NULL },
 #ifdef RANDR
-{ RRExtensionInit, RANDR, noRRExtension, NULL, NULL },
+{ RRExtensionInit, RANDR, noRRExtension, NULL },
 #endif
 #ifdef COMPOSITE
 { CompositeExtensionInit, COMPOSITE, noCompositeExtension, NULL },
@@ -452,7 +452,7 @@ static ExtensionModule staticExtensions[] = {
 #ifdef XSELINUX
 { SELinuxExtensionInit, SELINUX_EXTENSION_NAME, noSELinuxExtension, NULL 
},
 #endif
-{ NULL, NULL, NULL, NULL, NULL }
+{ NULL, NULL, NULL, NULL }
 };
 
 static ExtensionModule *ExtensionModuleList = 

[PATCH 23/37] DRI2: Remove prototype for DRI2DestroyDrawable

2011-06-28 Thread Daniel Stone
DRI2DestroyDrawable() was still being _X_EXPORTed, but hasn't existed
since 1da1f33f last year.

Signed-off-by: Daniel Stone dan...@fooishbar.org
---
 hw/xfree86/dri2/dri2.h |2 --
 1 files changed, 0 insertions(+), 2 deletions(-)

diff --git a/hw/xfree86/dri2/dri2.h b/hw/xfree86/dri2/dri2.h
index fe0bf6c..b61753a 100644
--- a/hw/xfree86/dri2/dri2.h
+++ b/hw/xfree86/dri2/dri2.h
@@ -214,8 +214,6 @@ extern _X_EXPORT int DRI2CreateDrawable(ClientPtr client,
DRI2InvalidateProcPtr invalidate,
void *priv);
 
-extern _X_EXPORT void DRI2DestroyDrawable(DrawablePtr pDraw);
-
 extern _X_EXPORT DRI2BufferPtr *DRI2GetBuffers(DrawablePtr pDraw,
 int *width,
 int *height,
-- 
1.7.5.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


[PATCH 34/37] Hide local-only extensions from remote clients

2011-06-28 Thread Daniel Stone
If an extension is declared as being for local use only, don't show it
to remote clients in the extension list.

Signed-off-by: Daniel Stone dan...@fooishbar.org
---
 dix/extension.c |9 ++---
 1 files changed, 6 insertions(+), 3 deletions(-)

diff --git a/dix/extension.c b/dix/extension.c
index 0fa177a..59b7849 100644
--- a/dix/extension.c
+++ b/dix/extension.c
@@ -286,7 +286,8 @@ ProcQueryExtension(ClientPtr client)
 else
 {
i = FindExtension((char *)stuff[1], stuff-nbytes);
-if (i  0 || XaceHook(XACE_EXT_ACCESS, client, extensions[i]))
+if (i  0 || XaceHook(XACE_EXT_ACCESS, client, extensions[i]) ||
+(extensions[i]-localOnly  !LocalClient(client)))
 reply.present = xFalse;
 else
 {
@@ -323,7 +324,8 @@ ProcListExtensions(ClientPtr client)
 for (i=0;  iNumExtensions; i++)
{
/* call callbacks to find out whether to show extension */
-   if (XaceHook(XACE_EXT_ACCESS, client, extensions[i]) != Success)
+   if (XaceHook(XACE_EXT_ACCESS, client, extensions[i]) != Success ||
+(extensions[i]-localOnly  !LocalClient(client)))
continue;
 
total_length += strlen(extensions[i]-name) + 1;
@@ -338,7 +340,8 @@ ProcListExtensions(ClientPtr client)
 for (i=0;  iNumExtensions; i++)
 {
int len;
-   if (XaceHook(XACE_EXT_ACCESS, client, extensions[i]) != Success)
+   if (XaceHook(XACE_EXT_ACCESS, client, extensions[i]) != Success ||
+(extensions[i]-localOnly  !LocalClient(client)))
continue;
 
 *bufptr++ = len = strlen(extensions[i]-name);
-- 
1.7.5.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


[PATCH 15/37] Move SELinux from extmod to built-in

2011-06-28 Thread Daniel Stone
Instead of letting it languish in extmod just because we want to
configure bits of it from xf86, move XSELinux to the builtin part of
Xext, and do its configuration from xf86ExtensionInit.

Signed-off-by: Daniel Stone dan...@fooishbar.org
---
 Xext/Makefile.am|8 +---
 hw/xfree86/common/xf86Extensions.c  |   19 +++
 hw/xfree86/dixmods/extmod/modinit.c |   29 -
 mi/miinitext.c  |3 +++
 4 files changed, 27 insertions(+), 32 deletions(-)

diff --git a/Xext/Makefile.am b/Xext/Makefile.am
index acbcc17..86d40e1 100644
--- a/Xext/Makefile.am
+++ b/Xext/Makefile.am
@@ -30,6 +30,7 @@ BUILTIN_SRCS =\
syncsrv.h   \
xcmisc.c\
xtest.c
+BUILTIN_LIBS =
 
 # Sources always included in libXextmodule.la  libXext.la. That's right, zero.
 MODULE_SRCS =
@@ -84,8 +85,8 @@ endif
 # requires X-ACE extension
 XSELINUX_SRCS = xselinux_ext.c xselinux_hooks.c xselinux_label.c xselinux.h 
xselinuxint.h
 if XSELINUX
-MODULE_SRCS += $(XSELINUX_SRCS)
-MODULE_LIBS += $(SELINUX_LIBS)
+BUILTIN_SRCS += $(XSELINUX_SRCS)
+BUILTIN_LIBS += $(SELINUX_LIBS)
 endif
 
 # Security extension: multi-level security to protect clients from each other
@@ -109,10 +110,11 @@ endif
 # Now take all of the above, mix well, bake for 10 minutes and get libXext*.la
 
 libXext_la_SOURCES =   $(BUILTIN_SRCS) $(MODULE_SRCS)
-libXext_la_LIBADD =$(MODULE_LIBS)
+libXext_la_LIBADD =$(BUILTIN_LIBS) $(MODULE_LIBS)
 
 if XORG
 libXextbuiltin_la_SOURCES =$(BUILTIN_SRCS)
+libXextbuiltin_la_LIBADD = $(BUILTIN_LIBS)
 
 libXextmodule_la_SOURCES = $(MODULE_SRCS)
 libXextmodule_la_LIBADD =  $(MODULE_LIBS)
diff --git a/hw/xfree86/common/xf86Extensions.c 
b/hw/xfree86/common/xf86Extensions.c
index b430d32..5b2f631 100644
--- a/hw/xfree86/common/xf86Extensions.c
+++ b/hw/xfree86/common/xf86Extensions.c
@@ -51,6 +51,25 @@ xf86ExtensionInit(void)
 if (EnableDisableExtension(opt-opt_name + 4, FALSE))
 xf86MarkOptionUsed(opt);
 }
+
+#ifdef XSELINUX
+if (! strcmp(SELINUX_EXTENSION_NAME, extensionModules[i].name)) {
+pointer o;
+
+if ((o = xf86FindOption(modp-load_opt, SELinux mode 
disabled))) {
+xf86MarkOptionUsed(o);
+selinuxEnforcingState = SELINUX_MODE_DISABLED;
+}
+if ((o = xf86FindOption(modp-load_opt, SELinux mode 
permissive))) {
+xf86MarkOptionUsed(o);
+selinuxEnforcingState = SELINUX_MODE_PERMISSIVE;
+}
+if ((o = xf86FindOption(modp-load_opt, SELinux mode 
enforcing))) {
+xf86MarkOptionUsed(o);
+selinuxEnforcingState = SELINUX_MODE_ENFORCING;
+}
+}
+#endif
}
 }
 }
diff --git a/hw/xfree86/dixmods/extmod/modinit.c 
b/hw/xfree86/dixmods/extmod/modinit.c
index 3dfacf1..673dcd4 100644
--- a/hw/xfree86/dixmods/extmod/modinit.c
+++ b/hw/xfree86/dixmods/extmod/modinit.c
@@ -38,15 +38,6 @@ static MODULESETUPPROTO(extmodSetup);
  * Array describing extensions to be initialized
  */
 static ExtensionModule extensionModules[] = {
-#ifdef XSELINUX
-{
-   SELinuxExtensionInit,
-   SELINUX_EXTENSION_NAME,
-   noSELinuxExtension,
-   NULL,
-   NULL
-},
-#endif
 #ifdef XF86VIDMODE
 {
XFree86VidModeExtensionInit,
@@ -114,26 +105,6 @@ extmodSetup(pointer module, pointer opts, int *errmaj, int 
*errmin)
}
}
 
-#ifdef XSELINUX
-   if (! strcmp(SELINUX_EXTENSION_NAME, extensionModules[i].name)) {
-   pointer o;
-   selinuxEnforcingState = SELINUX_MODE_DEFAULT;
-
-   if ((o = xf86FindOption(opts, SELinux mode disabled))) {
-   xf86MarkOptionUsed(o);
-   selinuxEnforcingState = SELINUX_MODE_DISABLED;
-   }
-   if ((o = xf86FindOption(opts, SELinux mode permissive))) {
-   xf86MarkOptionUsed(o);
-   selinuxEnforcingState = SELINUX_MODE_PERMISSIVE;
-   }
-   if ((o = xf86FindOption(opts, SELinux mode enforcing))) {
-   xf86MarkOptionUsed(o);
-   selinuxEnforcingState = SELINUX_MODE_ENFORCING;
-   }
-   }
-#endif
-
LoadExtension(extensionModules[i], FALSE);
 }
 /* Need a non-NULL return */
diff --git a/mi/miinitext.c b/mi/miinitext.c
index 9fb5ec8..2090c2d 100644
--- a/mi/miinitext.c
+++ b/mi/miinitext.c
@@ -542,6 +542,9 @@ static ExtensionModule staticExtensions[] = {
 { XvExtensionInit, XvName, noXvExtension, NULL },
 { XvMCExtensionInit, XvMCName, noXvExtension, NULL },
 #endif
+#ifdef XSELINUX
+{ SELinuxExtensionInit, SELINUX_EXTENSION_NAME, noSELinuxExtension, NULL 
},
+#endif
 { NULL, NULL, NULL, NULL, NULL }
 };
 
-- 
1.7.5.4


[PATCH 36/37] Remove LocalClient checks from local-only extensions

2011-06-28 Thread Daniel Stone
We already hide the extension from clients and deny their requests, so I
doubt we'll be needing the LocalClient() check anymore.

Signed-off-by: Daniel Stone dan...@fooishbar.org
---
 hw/kdrive/ephyr/ephyrdriext.c |9 +
 hw/xfree86/common/xf86DGA.c   |3 ---
 hw/xfree86/dri/xf86dri.c  |9 +
 hw/xfree86/dri2/dri2ext.c |6 --
 hw/xquartz/applewm.c  |   11 ---
 hw/xquartz/xpr/appledri.c |   14 --
 6 files changed, 2 insertions(+), 50 deletions(-)

diff --git a/hw/kdrive/ephyr/ephyrdriext.c b/hw/kdrive/ephyr/ephyrdriext.c
index 38335c4..ced483e 100644
--- a/hw/kdrive/ephyr/ephyrdriext.c
+++ b/hw/kdrive/ephyr/ephyrdriext.c
@@ -588,7 +588,7 @@ ProcXF86DRIQueryDirectRenderingCapable (register ClientPtr 
client)
 }
 rep.isCapable = isCapable;
 
-if (!LocalClient(client) || client-swapped)
+if (client-swapped)
rep.isCapable = 0;
 
 if (client-swapped) {
@@ -1253,13 +1253,6 @@ ProcXF86DRIDispatch (register ClientPtr  client)
 EPHYR_LOG (leave\n) ;
 return ProcXF86DRIQueryDirectRenderingCapable(client);
 }
-}
-
-if (!LocalClient(client))
-return DRIErrorBase + XF86DRIClientNotLocal;
-
-switch (stuff-data)
-{
 case X_XF86DRIOpenConnection: {
 EPHYR_LOG (leave\n) ;
 return ProcXF86DRIOpenConnection(client);
diff --git a/hw/xfree86/common/xf86DGA.c b/hw/xfree86/common/xf86DGA.c
index 1661106..a3f4334 100644
--- a/hw/xfree86/common/xf86DGA.c
+++ b/hw/xfree86/common/xf86DGA.c
@@ -2136,9 +2136,6 @@ ProcXDGADispatch (ClientPtr client)
 {
 REQUEST(xReq);
 
-if (!LocalClient(client))
-   return DGAErrorBase + XF86DGAClientNotLocal;
-
 #ifdef DGA_REQ_DEBUG
 if (stuff-data = X_XDGACreateColormap)
fprintf (stderr, DGA %s\n, dgaMinor[stuff-data]);
diff --git a/hw/xfree86/dri/xf86dri.c b/hw/xfree86/dri/xf86dri.c
index 740c83b..660330e 100644
--- a/hw/xfree86/dri/xf86dri.c
+++ b/hw/xfree86/dri/xf86dri.c
@@ -132,7 +132,7 @@ ProcXF86DRIQueryDirectRenderingCapable(
 }
 rep.isCapable = isCapable;
 
-if (!LocalClient(client) || client-swapped)
+if (client-swapped)
rep.isCapable = 0;
 
 if (client-swapped) {
@@ -557,13 +557,6 @@ ProcXF86DRIDispatch (
return ProcXF86DRIQueryVersion(client);
 case X_XF86DRIQueryDirectRenderingCapable:
return ProcXF86DRIQueryDirectRenderingCapable(client);
-}
-
-if (!LocalClient(client))
-   return DRIErrorBase + XF86DRIClientNotLocal;
-
-switch (stuff-data)
-{
 case X_XF86DRIOpenConnection:
return ProcXF86DRIOpenConnection(client);
 case X_XF86DRICloseConnection:
diff --git a/hw/xfree86/dri2/dri2ext.c b/hw/xfree86/dri2/dri2ext.c
index 2734748..43e2a04 100644
--- a/hw/xfree86/dri2/dri2ext.c
+++ b/hw/xfree86/dri2/dri2ext.c
@@ -544,12 +544,6 @@ ProcDRI2Dispatch (ClientPtr client)
 switch (stuff-data) {
 case X_DRI2QueryVersion:
return ProcDRI2QueryVersion(client);
-}
-
-if (!LocalClient(client))
-   return BadRequest;
-
-switch (stuff-data) {
 case X_DRI2Connect:
return ProcDRI2Connect(client);
 case X_DRI2Authenticate:
diff --git a/hw/xquartz/applewm.c b/hw/xquartz/applewm.c
index 6aa6421..e3b7e5e 100644
--- a/hw/xquartz/applewm.c
+++ b/hw/xquartz/applewm.c
@@ -629,13 +629,6 @@ ProcAppleWMDispatch (
 {
 case X_AppleWMQueryVersion:
 return ProcAppleWMQueryVersion(client);
-}
-
-if (!LocalClient(client))
-return WMErrorBase + AppleWMClientNotLocal;
-
-switch (stuff-data)
-{
 case X_AppleWMSelectInput:
 return ProcAppleWMSelectInput(client);
 case X_AppleWMDisableUpdate:
@@ -694,10 +687,6 @@ SProcAppleWMDispatch (
 {
 REQUEST(xReq);
 
-/* It is bound to be non-local when there is byte swapping */
-if (!LocalClient(client))
-return WMErrorBase + AppleWMClientNotLocal;
-
 /* only local clients are allowed WM access */
 switch (stuff-data)
 {
diff --git a/hw/xquartz/xpr/appledri.c b/hw/xquartz/xpr/appledri.c
index 8149cd1..9df717c 100644
--- a/hw/xquartz/xpr/appledri.c
+++ b/hw/xquartz/xpr/appledri.c
@@ -131,9 +131,6 @@ ProcAppleDRIQueryDirectRenderingCapable(
 }
 rep.isCapable = isCapable;
 
-if (!LocalClient(client))
-rep.isCapable = 0;
-
 WriteToClient(client, 
 sizeof(xAppleDRIQueryDirectRenderingCapableReply), (char *)rep);
 return Success;
@@ -331,13 +328,6 @@ ProcAppleDRIDispatch (
 return ProcAppleDRIQueryVersion(client);
 case X_AppleDRIQueryDirectRenderingCapable:
 return ProcAppleDRIQueryDirectRenderingCapable(client);
-}
-
-if (!LocalClient(client))
-return DRIErrorBase + AppleDRIClientNotLocal;
-
-switch (stuff-data)
-{
 case X_AppleDRIAuthConnection:
 return ProcAppleDRIAuthConnection(client);
 case X_AppleDRICreateSurface:
@@ -385,10 +375,6 @@ SProcAppleDRIDispatch (
 

[PATCH 10/37] Move MIT-SCREEN-SAVER from extmod to built-in

2011-06-28 Thread Daniel Stone
From: Tomas Carnecky t...@dbservice.com

If we've built MIT-SCREEN-SAVER support, then just build it into the
main binary, rather than leaving it in extmod.

Signed-off-by: Tomas Carnecky t...@dbservice.com
Reviewed-by: Daniel Stone dan...@fooishbar.org
---
 Xext/Makefile.am|2 +-
 hw/xfree86/dixmods/extmod/modinit.c |9 -
 mi/miinitext.c  |6 ++
 3 files changed, 7 insertions(+), 10 deletions(-)

diff --git a/Xext/Makefile.am b/Xext/Makefile.am
index cb432e0..a443a64 100644
--- a/Xext/Makefile.am
+++ b/Xext/Makefile.am
@@ -58,7 +58,7 @@ endif
 # MIT ScreenSaver extension
 SCREENSAVER_SRCS = saver.c
 if SCREENSAVER
-MODULE_SRCS  += $(SCREENSAVER_SRCS)
+BUILTIN_SRCS  += $(SCREENSAVER_SRCS)
 endif
 
 # Xinerama extension: making multiple video devices act as one virtual screen
diff --git a/hw/xfree86/dixmods/extmod/modinit.c 
b/hw/xfree86/dixmods/extmod/modinit.c
index a415e5f..4441899 100644
--- a/hw/xfree86/dixmods/extmod/modinit.c
+++ b/hw/xfree86/dixmods/extmod/modinit.c
@@ -47,15 +47,6 @@ static ExtensionModule extensionModules[] = {
NULL
 },
 #endif
-#ifdef SCREENSAVER
-{
-   ScreenSaverExtensionInit,
-   ScreenSaverName,
-   noScreenSaverExtension,
-   NULL,
-   NULL
-},
-#endif
 #ifdef XF86VIDMODE
 {
XFree86VidModeExtensionInit,
diff --git a/mi/miinitext.c b/mi/miinitext.c
index d46b59d..c75c140 100644
--- a/mi/miinitext.c
+++ b/mi/miinitext.c
@@ -183,6 +183,9 @@ typedef void (*InitExtension)(void);
 #ifdef RES
 #include X11/extensions/XResproto.h
 #endif
+#ifdef SCREENSAVER
+#include X11/extensions/saver.h
+#endif
 
 /* FIXME: this whole block of externs should be from the appropriate headers */
 #ifdef MITSHM
@@ -512,6 +515,9 @@ static ExtensionModule staticExtensions[] = {
 #ifdef DAMAGE
 { DamageExtensionInit, DAMAGE, noDamageExtension, NULL },
 #endif
+#ifdef SCREENSAVER
+{ ScreenSaverExtensionInit, ScreenSaverName, noScreenSaverExtension, NULL 
},
+#endif
 #ifdef DBE
 { DbeExtensionInit, DOUBLE-BUFFER, noDbeExtension, NULL },
 #endif
-- 
1.7.5.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


[PATCH 33/37] Add localOnly argument to AddExtension

2011-06-28 Thread Daniel Stone
Does what it says on the box (or will, next commit): specifies if the
extension should be enabled for local clients only.  Marked SHM, DRI and
DRI2 as the only extensions requiring local clients.

Signed-off-by: Daniel Stone dan...@fooishbar.org
---
 Xext/bigreq.c |2 +-
 Xext/dpms.c   |2 +-
 Xext/geext.c  |2 +-
 Xext/panoramiX.c  |2 +-
 Xext/saver.c  |2 +-
 Xext/security.c   |2 +-
 Xext/shape.c  |2 +-
 Xext/shm.c|2 +-
 Xext/sync.c   |2 +-
 Xext/xcmisc.c |2 +-
 Xext/xf86bigfont.c|2 +-
 Xext/xres.c   |2 +-
 Xext/xselinux_ext.c   |2 +-
 Xext/xtest.c  |2 +-
 Xext/xvmain.c |2 +-
 Xext/xvmc.c   |2 +-
 Xi/extinit.c  |3 ++-
 composite/compext.c   |2 +-
 damageext/damageext.c |3 ++-
 dbe/dbe.c |2 +-
 dix/extension.c   |3 ++-
 doc/Xserver-spec.xml  |4 +++-
 glx/glxext.c  |2 +-
 hw/dmx/dmx.c  |2 +-
 hw/dmx/glxProxy/glxext.c  |2 +-
 hw/kdrive/ephyr/ephyrdriext.c |3 ++-
 hw/xfree86/common/xf86DGA.c   |3 ++-
 hw/xfree86/common/xf86vmode.c |3 ++-
 hw/xfree86/dri/xf86dri.c  |3 ++-
 hw/xfree86/dri2/dri2ext.c |3 ++-
 hw/xquartz/applewm.c  |3 ++-
 hw/xquartz/pseudoramiX.c  |3 ++-
 hw/xquartz/xpr/appledri.c |3 ++-
 hw/xwin/winwindowswm.c|3 ++-
 include/extnsionst.h  |4 +++-
 randr/randr.c |2 +-
 randr/rrxinerama.c|3 ++-
 record/record.c   |3 ++-
 render/render.c   |2 +-
 xfixes/xfixes.c   |3 ++-
 xkb/xkb.c |3 ++-
 41 files changed, 61 insertions(+), 41 deletions(-)

diff --git a/Xext/bigreq.c b/Xext/bigreq.c
index 2a3becd..9c1e73a 100644
--- a/Xext/bigreq.c
+++ b/Xext/bigreq.c
@@ -73,5 +73,5 @@ BigReqExtensionInit(void)
 {
 AddExtension(XBigReqExtensionName, 0, 0,
 ProcBigReqDispatch, ProcBigReqDispatch,
-NULL, StandardMinorOpcode);
+NULL, StandardMinorOpcode, FALSE);
 }
diff --git a/Xext/dpms.c b/Xext/dpms.c
index 2eb28ef..af97a76 100644
--- a/Xext/dpms.c
+++ b/Xext/dpms.c
@@ -376,5 +376,5 @@ DPMSExtensionInit(void)
 {
 AddExtension(DPMSExtensionName, 0, 0,
 ProcDPMSDispatch, SProcDPMSDispatch,
-NULL, StandardMinorOpcode);
+NULL, StandardMinorOpcode, FALSE);
 }
diff --git a/Xext/geext.c b/Xext/geext.c
index 18f8ffe..9a2d3ef 100644
--- a/Xext/geext.c
+++ b/Xext/geext.c
@@ -216,7 +216,7 @@ GEExtensionInit(void)
 if((extEntry = AddExtension(GE_NAME,
 0, GENumberErrors,
 ProcGEDispatch, SProcGEDispatch,
-GEResetProc, StandardMinorOpcode)) != 0)
+GEResetProc, StandardMinorOpcode, FALSE)) != 0)
 {
 memset(GEExtensions, 0, sizeof(GEExtensions));
 
diff --git a/Xext/panoramiX.c b/Xext/panoramiX.c
index 277b637..2921450 100644
--- a/Xext/panoramiX.c
+++ b/Xext/panoramiX.c
@@ -470,7 +470,7 @@ void PanoramiXExtensionInit(void)
extEntry = AddExtension(PANORAMIX_PROTOCOL_NAME, 0,0, 
ProcPanoramiXDispatch,
SProcPanoramiXDispatch, PanoramiXResetProc, 
-   StandardMinorOpcode);
+   StandardMinorOpcode, FALSE);
if (!extEntry)
break;
 
diff --git a/Xext/saver.c b/Xext/saver.c
index 0544506..54881bc 100644
--- a/Xext/saver.c
+++ b/Xext/saver.c
@@ -1505,7 +1505,7 @@ ScreenSaverExtensionInit(void)
 if (AttrType  SaverEventType  SuspendType 
(extEntry = AddExtension(ScreenSaverName, ScreenSaverNumberEvents, 0,
 ProcScreenSaverDispatch, 
SProcScreenSaverDispatch,
-NULL, StandardMinorOpcode)))
+NULL, StandardMinorOpcode, FALSE)))
 {
ScreenSaverEventBase = extEntry-eventBase;
EventSwapVector[ScreenSaverEventBase] = (EventSwapPtr) 
SScreenSaverNotifyEvent;
diff --git a/Xext/security.c b/Xext/security.c
index 5e0a734..55407f0 100644
--- a/Xext/security.c
+++ b/Xext/security.c
@@ -1130,7 +1130,7 @@ SecurityExtensionInit(void)
 extEntry = AddExtension(SECURITY_EXTENSION_NAME,
XSecurityNumberEvents, XSecurityNumberErrors,
ProcSecurityDispatch, SProcSecurityDispatch,
-SecurityResetProc, StandardMinorOpcode);
+SecurityResetProc, StandardMinorOpcode, FALSE);
 
 SecurityErrorBase = extEntry-errorBase;
 SecurityEventBase = 

[PATCH 09/37] Move RECORD from external module to built-in

2011-06-28 Thread Daniel Stone
From: Tomas Carnecky t...@dbservice.com

Rather than languishing in its own special module, move RECORD into the
core server.

Signed-off-by: Tomas Carnecky t...@dbservice.com
Reviewed-by: Daniel Stone dan...@fooishbar.org
---
 configure.ac   |2 +-
 hw/xfree86/common/xf86Config.c |3 --
 hw/xfree86/dixmods/Makefile.am |   11 +-
 hw/xfree86/dixmods/recordmod.c |   44 
 hw/xfree86/loader/loadmod.c|1 +
 mi/miinitext.c |3 ++
 6 files changed, 6 insertions(+), 58 deletions(-)
 delete mode 100644 hw/xfree86/dixmods/recordmod.c

diff --git a/configure.ac b/configure.ac
index d525e21..820332a 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1517,7 +1517,7 @@ if test x$XORG = xyes; then
XORG_OSINCS='-I$(top_srcdir)/hw/xfree86/os-support 
-I$(top_srcdir)/hw/xfree86/os-support/bus -I$(top_srcdir)/os'
XORG_INCS=$XORG_DDXINCS $XORG_OSINCS
XORG_CFLAGS=$XORGSERVER_CFLAGS -DHAVE_XORG_CONFIG_H
-   XORG_LIBS=$COMPOSITE_LIB $FIXES_LIB $XEXTXORG_LIB $DBE_LIB $GLX_LIBS 
$RANDR_LIB $RENDER_LIB $DAMAGE_LIB $MIEXT_SYNC_LIB $MIEXT_DAMAGE_LIB 
$MIEXT_SHADOW_LIB $XI_LIB $XKB_LIB
+   XORG_LIBS=$COMPOSITE_LIB $FIXES_LIB $XEXTXORG_LIB $DBE_LIB $RECORD_LIB 
$GLX_LIBS $RANDR_LIB $RENDER_LIB $DAMAGE_LIB $MIEXT_SYNC_LIB $MIEXT_DAMAGE_LIB 
$MIEXT_SHADOW_LIB $XI_LIB $XKB_LIB
 
dnl ==
dnl symbol visibility
diff --git a/hw/xfree86/common/xf86Config.c b/hw/xfree86/common/xf86Config.c
index 6e93be8..9677c75 100644
--- a/hw/xfree86/common/xf86Config.c
+++ b/hw/xfree86/common/xf86Config.c
@@ -113,9 +113,6 @@ static ModuleDefault ModuleDefaults[] = {
 #ifdef GLXEXT
 {.name = glx,  .toLoad = TRUE,.load_opt=NULL},
 #endif
-#ifdef XRECORD
-{.name = record,   .toLoad = TRUE,.load_opt=NULL},
-#endif
 #ifdef XF86DRI
 {.name = dri,  .toLoad = TRUE,.load_opt=NULL},
 #endif
diff --git a/hw/xfree86/dixmods/Makefile.am b/hw/xfree86/dixmods/Makefile.am
index 3e7354c..21536d5 100644
--- a/hw/xfree86/dixmods/Makefile.am
+++ b/hw/xfree86/dixmods/Makefile.am
@@ -6,17 +6,12 @@ if GLX
 GLXMODS = libglx.la
 endif
 
-if RECORD
-RECORDMOD = librecord.la
-endif
-
 module_LTLIBRARIES = libfb.la \
  libwfb.la \
  libshadow.la
 
 extsmoduledir = $(moduledir)/extensions
-extsmodule_LTLIBRARIES = $(RECORDMOD) \
- $(GLXMODS)
+extsmodule_LTLIBRARIES = $(GLXMODS)
 
 AM_CFLAGS = @XORG_CFLAGS@ @DIX_CFLAGS@
 INCLUDES = @XORG_INCS@ \
@@ -43,10 +38,6 @@ libglx_la_LIBADD = \
$(GLXDRI_LIBRARY)
 libglx_la_SOURCES = glxmodule.c
 
-librecord_la_LDFLAGS = -avoid-version
-librecord_la_LIBADD = $(top_builddir)/record/librecord.la
-librecord_la_SOURCES = recordmod.c
-
 libshadow_la_LDFLAGS = -avoid-version
 libshadow_la_LIBADD = $(top_builddir)/miext/shadow/libshadow.la
 libshadow_la_SOURCES = shmodule.c
diff --git a/hw/xfree86/dixmods/recordmod.c b/hw/xfree86/dixmods/recordmod.c
deleted file mode 100644
index cb265de..000
--- a/hw/xfree86/dixmods/recordmod.c
+++ /dev/null
@@ -1,44 +0,0 @@
-#ifdef HAVE_XORG_CONFIG_H
-#include xorg-config.h
-#endif
-
-#include xf86Module.h
-
-extern Bool noTestExtensions;
-
-static MODULESETUPPROTO(recordSetup);
-
-extern void RecordExtensionInit(void);
-
-static ExtensionModule recordExt = {
-RecordExtensionInit,
-RECORD,
-noTestExtensions,
-NULL,
-NULL
-};
-
-static XF86ModuleVersionInfo VersRec = {
-   record,
-   MODULEVENDORSTRING,
-   MODINFOSTRING1,
-   MODINFOSTRING2,
-   XORG_VERSION_CURRENT,
-   1, 13, 0,
-   ABI_CLASS_EXTENSION,
-   ABI_EXTENSION_VERSION,
-   MOD_CLASS_EXTENSION,
-   {0,0,0,0}
-};
-
-_X_EXPORT XF86ModuleData recordModuleData = { VersRec, recordSetup, NULL };
-
-static pointer
-recordSetup(pointer module, pointer opts, int *errmaj, int *errmin)
-{
-LoadExtension(recordExt, FALSE);
-
-/* Need a non-NULL return value to indicate success */
-return (pointer)1;
-}
-
diff --git a/hw/xfree86/loader/loadmod.c b/hw/xfree86/loader/loadmod.c
index 6da9070..958d420 100644
--- a/hw/xfree86/loader/loadmod.c
+++ b/hw/xfree86/loader/loadmod.c
@@ -816,6 +816,7 @@ static const char *compiled_in_modules[] = {
 i2c,
 ramdac,
 dbe,
+record,
 NULL
 };
 
diff --git a/mi/miinitext.c b/mi/miinitext.c
index a51bd9b..d46b59d 100644
--- a/mi/miinitext.c
+++ b/mi/miinitext.c
@@ -515,6 +515,9 @@ static ExtensionModule staticExtensions[] = {
 #ifdef DBE
 { DbeExtensionInit, DOUBLE-BUFFER, noDbeExtension, NULL },
 #endif
+#ifdef XRECORD
+{ RecordExtensionInit, RECORD, noTestExtensions, NULL },
+#endif
 { NULL, NULL, NULL, NULL, NULL }
 };
 
-- 
1.7.5.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


[PATCH 05/37] Reorder extension initialisation for non-Xorg

2011-06-28 Thread Daniel Stone
Reorder static extension initialisation in miinitext for non-Xorg
servers to match Xorg's order.

Tested with Xephyr; checked that the extension list was identical before
and after.

Signed-off-by: Daniel Stone dan...@fooishbar.org
---
 mi/miinitext.c |   84 ---
 1 files changed, 43 insertions(+), 41 deletions(-)

diff --git a/mi/miinitext.c b/mi/miinitext.c
index 3155bda..ff70a1d 100644
--- a/mi/miinitext.c
+++ b/mi/miinitext.c
@@ -386,13 +386,6 @@ void
 InitExtensions(int argc, char *argv[])
 {
 if (!noGEExtension) GEExtensionInit();
-
-#ifdef PANORAMIX
-  if (!noPanoramiXExtension) PanoramiXExtensionInit();
-#endif
-#ifdef INXQUARTZ
-if(!noPseudoramiXExtension) PseudoramiXExtensionInit();
-#endif
 ShapeExtensionInit();
 #ifdef MITSHM
 if (!noMITShmExtension) ShmExtensionInit();
@@ -402,36 +395,43 @@ InitExtensions(int argc, char *argv[])
 if (!noTestExtensions) XTestExtensionInit();
 #endif
 BigReqExtensionInit();
-#if defined(SCREENSAVER)
-if (!noScreenSaverExtension) ScreenSaverExtensionInit ();
-#endif
-#ifdef XV
-if (!noXvExtension) {
-  XvExtensionInit();
-  XvMCExtensionInit();
-}
-#endif
 SyncExtensionInit();
 XkbExtensionInit();
 XCMiscExtensionInit();
-#ifdef XRECORD
-if (!noTestExtensions) RecordExtensionInit(); 
-#endif
-#ifdef DBE
-if (!noDbeExtension) DbeExtensionInit();
-#endif
 #ifdef XCSECURITY
 if (!noSecurityExtension) SecurityExtensionInit();
 #endif
-#ifdef XSELINUX
-if (!noSELinuxExtension) SELinuxExtensionInit();
+#ifdef PANORAMIX
+if (!noPanoramiXExtension) PanoramiXExtensionInit();
 #endif
-#if defined(DPMSExtension)  !defined(NO_HW_ONLY_EXTS)
-if (!noDPMSExtension) DPMSExtensionInit();
+#ifdef INXQUARTZ
+if(!noPseudoramiXExtension) PseudoramiXExtensionInit();
+#endif
+#ifdef XFIXES
+/* must be before Render to layer DisplayCursor correctly */
+if (!noXFixesExtension) XFixesExtensionInit();
 #endif
 #ifdef XF86BIGFONT
 if (!noXFree86BigfontExtension) XFree86BigfontExtensionInit();
 #endif
+if (!noRenderExtension) RenderExtensionInit();
+#ifdef RANDR
+if (!noRRExtension) RRExtensionInit();
+#endif
+#ifdef COMPOSITE
+if (!noCompositeExtension) CompositeExtensionInit();
+#endif
+#ifdef DAMAGE
+if (!noDamageExtension) DamageExtensionInit();
+#endif
+
+#ifdef XSELINUX
+if (!noSELinuxExtension) SELinuxExtensionInit();
+#endif
+#if defined(SCREENSAVER)
+if (!noScreenSaverExtension) ScreenSaverExtensionInit ();
+#endif
+
 #if !defined(NO_HW_ONLY_EXTS)
 #if defined(XF86VIDMODE)
 if (!noXFree86VidModeExtension) XFree86VidModeExtensionInit();
@@ -439,29 +439,31 @@ InitExtensions(int argc, char *argv[])
 #if defined(XFreeXDGA)
 if (!noXFree86DGAExtension) XFree86DGAExtensionInit();
 #endif
-#ifdef XF86DRI
-if (!noXFree86DRIExtension) XFree86DRIExtensionInit();
-#endif
+#if defined(DPMSExtension)
+if (!noDPMSExtension) DPMSExtensionInit();
 #endif
-#ifdef XFIXES
-/* must be before Render to layer DisplayCursor correctly */
-if (!noXFixesExtension) XFixesExtensionInit();
 #endif
-if (!noRenderExtension) RenderExtensionInit();
-#ifdef RANDR
-if (!noRRExtension) RRExtensionInit();
+
+#ifdef XV
+if (!noXvExtension) {
+  XvExtensionInit();
+  XvMCExtensionInit();
+}
 #endif
 #ifdef RES
 if (!noResExtension) ResExtensionInit();
 #endif
-#ifdef DMXEXT
-DMXExtensionInit(); /* server-specific extension, cannot be disabled */
+#ifdef XRECORD
+if (!noTestExtensions) RecordExtensionInit(); 
 #endif
-#ifdef COMPOSITE
-if (!noCompositeExtension) CompositeExtensionInit();
+#ifdef DBE
+if (!noDbeExtension) DbeExtensionInit();
 #endif
-#ifdef DAMAGE
-if (!noDamageExtension) DamageExtensionInit();
+#if !defined(NO_HW_ONLY_EXTS)  defined(XF86DRI)
+if (!noXFree86DRIExtension) XFree86DRIExtensionInit();
+#endif
+#ifdef DMXEXT
+DMXExtensionInit(); /* server-specific extension, cannot be disabled */
 #endif
 
 #ifdef GLXEXT
-- 
1.7.5.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


[PATCH 17/37] DGA: Remove excessive module-induced indirection

2011-06-28 Thread Daniel Stone
From: Tomas Carnecky t...@dbservice.com

The DGA event base used to have to be passed through a function pointer,
as the code was cleaved in two with half in a module, and half in the
core server.  Now that's not the case, just access DGAEventBase
directly.

Signed-off-by: Tomas Carnecky t...@dbservice.com
Reviewed-by: Daniel Stone dan...@fooishbar.org
---
 hw/xfree86/common/dgaproc.h|1 -
 hw/xfree86/common/xf86DGA.c|   20 ++--
 hw/xfree86/common/xf86Extensions.c |2 +-
 3 files changed, 7 insertions(+), 16 deletions(-)

diff --git a/hw/xfree86/common/dgaproc.h b/hw/xfree86/common/dgaproc.h
index a13a517..111d46b 100644
--- a/hw/xfree86/common/dgaproc.h
+++ b/hw/xfree86/common/dgaproc.h
@@ -135,7 +135,6 @@ extern _X_EXPORT int DGACreateColormap(int Index, ClientPtr 
client, int id, int
 extern _X_EXPORT unsigned char DGAReqCode;
 extern _X_EXPORT int DGAErrorBase;
 extern _X_EXPORT int DGAEventBase;
-extern _X_EXPORT int *XDGAEventBase;
 
 
 
diff --git a/hw/xfree86/common/xf86DGA.c b/hw/xfree86/common/xf86DGA.c
index 0e3f53d..c42854b 100644
--- a/hw/xfree86/common/xf86DGA.c
+++ b/hw/xfree86/common/xf86DGA.c
@@ -96,7 +96,9 @@ DGACopyModeInfo(
XDGAModePtr xmode
 );
 
-int *XDGAEventBase = NULL;
+unsigned char DGAReqCode = 0;
+int DGAErrorBase;
+int DGAEventBase;
 
 #define DGA_GET_SCREEN_PRIV(pScreen) ((DGAScreenPtr) \
 dixLookupPrivate((pScreen)-devPrivates, DGAScreenKeyRec))
@@ -1065,7 +1067,7 @@ DGAProcessKeyboardEvent (ScreenPtr pScreen, DGAEvent 
*event, DeviceIntPtr keybd)
 if (pScreenPriv-client)
 {
 dgaEvent de;
-de.u.u.type = *XDGAEventBase + GetCoreType((InternalEvent*)ev);
+de.u.u.type = DGAEventBase + GetCoreType((InternalEvent*)ev);
 de.u.u.detail = event-detail;
 de.u.event.time = event-time;
 de.u.event.dx = event-dx;
@@ -1121,7 +1123,7 @@ DGAProcessPointerEvent (ScreenPtr pScreen, DGAEvent 
*event, DeviceIntPtr mouse)
 
 coreEquiv = GetCoreType((InternalEvent*)ev);
 
-de.u.u.type = *XDGAEventBase + coreEquiv;
+de.u.u.type = DGAEventBase + coreEquiv;
 de.u.u.detail = event-detail;
 de.u.event.time = event-time;
 de.u.event.dx = event-dx;
@@ -1218,7 +1220,7 @@ DGAHandleEvent(int screen_num, InternalEvent *ev, 
DeviceIntPtr device)
 DGAScreenPtrpScreenPriv;
 
 /* no DGA */
-if (!DGAScreenKeyRegistered || XDGAEventBase == 0)
+if (!DGAScreenKeyRegistered || noDGAExtension)
return;
 pScreenPriv = DGA_GET_SCREEN_PRIV(pScreen);
 
@@ -1250,10 +1252,6 @@ static void XDGAResetProc(ExtensionEntry *extEntry);
 
 static void DGAClientStateChange (CallbackListPtr*, pointer, pointer);
 
-unsigned char DGAReqCode = 0;
-int DGAErrorBase;
-int DGAEventBase;
-
 static DevPrivateKeyRec DGAScreenPrivateKeyRec;
 #define DGAScreenPrivateKey (DGAScreenPrivateKeyRec)
 #define DGAScreenPrivateKeyRegistered (DGAScreenPrivateKeyRec.initialized)
@@ -2213,12 +2211,6 @@ ProcXDGADispatch (ClientPtr client)
 }
 
 void
-XFree86DGARegister(void)
-{
-  XDGAEventBase = DGAEventBase;
-}
-
-void
 XFree86DGAExtensionInit(void)
 {
 ExtensionEntry* extEntry;
diff --git a/hw/xfree86/common/xf86Extensions.c 
b/hw/xfree86/common/xf86Extensions.c
index 12a8542..35dd841 100644
--- a/hw/xfree86/common/xf86Extensions.c
+++ b/hw/xfree86/common/xf86Extensions.c
@@ -44,7 +44,7 @@ static ExtensionModule extensionModules[] = {
XFree86DGAExtensionInit,
XF86DGANAME,
noXFree86DGAExtension,
-   XFree86DGARegister,
+   NULL,
NULL
 },
 #endif
-- 
1.7.5.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: [PATCH 01/37] Add a common ARRAY_SIZE macro to dix.h

2011-06-28 Thread Cyril Brulebois
Daniel Stone dan...@fooishbar.org (28/06/2011):
 Does what it says on the box, replacing those from Xi/ and glx/.
 
 Signed-off-by: Daniel Stone dan...@fooishbar.org

Reviewed-by: Cyril Brulebois k...@debian.org

Mraw,
KiBi.


signature.asc
Description: Digital 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: [PATCH 02/37] Make extension.h self-contained, remove C++ externs

2011-06-28 Thread Cyril Brulebois
Daniel Stone dan...@fooishbar.org (28/06/2011):
 externsion.h required bits from Xfuncproto.h and dixstruct.h, but
 included neither; fix that.
 
 It also had _XFUNCPROTOBEGIN and _XFUNCPROTOEND wrappers, which is a bit
 pointless for a server-only library, as it's only needed for C++.

Reviewed-by: Cyril Brulebois k...@debian.org

Mraw,
KiBi.


signature.asc
Description: Digital 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: [PATCH 03/37] Xinerama: Fix ExtensionInit prototype

2011-06-28 Thread Cyril Brulebois
Daniel Stone dan...@fooishbar.org (28/06/2011):
 Huh, so I guess INITARGS used to be int argc, char *argv then.  Either
 way, it's now void, so fix that ...
 
 Signed-off-by: Daniel Stone dan...@fooishbar.org

(Oops, first reply went to Daniel only.)

Reviewed-by: Cyril Brulebois k...@debian.org

Mraw,
KiBi.


signature.asc
Description: Digital 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: [PATCH 04/37] Replace INITARGS with void

2011-06-28 Thread Cyril Brulebois
Daniel Stone dan...@fooishbar.org (28/06/2011):
 From: Tomas Carnecky t...@dbservice.com
 
 It was defined to void anyway. Everyone but panoramix used INITARGS, but
 PanoramiXExtensionInit() had hardcoded argc/argv. Replace that with void
 as well.
 
 Signed-off-by: Tomas Carnecky t...@dbservice.com
 Reviewed-by: Daniel Stone dan...@fooishbar.org

Reviewed-by: Cyril Brulebois k...@debian.org

Mraw,
KiBi.


signature.asc
Description: Digital 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: [PATCH 22/37] XFree86: DRI: Don't use per-target CFLAGS

2011-06-28 Thread Cyril Brulebois
Daniel Stone dan...@fooishbar.org (28/06/2011):
 AM_CFLAGS will suffice, given we only have one target in this directory.
 
 Signed-off-by: Daniel Stone dan...@fooishbar.org

Reviewed-by: Cyril Brulebois k...@debian.org

Mraw,
KiBi.


signature.asc
Description: Digital 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: [PATCH 23/37] DRI2: Remove prototype for DRI2DestroyDrawable

2011-06-28 Thread Cyril Brulebois
Daniel Stone dan...@fooishbar.org (28/06/2011):
 DRI2DestroyDrawable() was still being _X_EXPORTed, but hasn't existed
 since 1da1f33f last year.
 
 Signed-off-by: Daniel Stone dan...@fooishbar.org

Reviewed-by: Cyril Brulebois k...@debian.org

Mraw,
KiBi.


signature.asc
Description: Digital 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: [PATCH 16/37] Move DGA from extmod to built-in

2011-06-28 Thread Daniel Stone
On Tue, Jun 28, 2011 at 08:55:40PM +0100, Alan Hourihane wrote:
 Just remembered, if --disable-dga when configuring still works, then I'm
 fine :-)

Indeed it does; I had to double back and install dgaproto to actually
test this.  I'm all in favour of ditching DGA if we can, but I think SDL
still depends on it for relative motion.  Wine at least uses Xi 2
though.

Cheers,
Daniel
___
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 0/37] Extension handling cleanup, death to extmod

2011-06-28 Thread Daniel Stone
Hi,

On Tue, Jun 28, 2011 at 08:27:16PM +0100, Daniel Stone wrote:
 The following patch series cleans up extension handling pretty
 substantially: it kills extmod, removes about half of miinitext.c to
 give us one unified set of extension definitions, and removes all other
 Xorg extension modules except for GLX, which is huge.

This is also available at:
git://people.freedesktop.org/~daniels/xserver extension-cleanup

(Why do I always forget to mention this?)

Cheers,
Daniel
___
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 input-synaptics 0/5] Revert collapse all Makefile.am files into a single

2011-06-28 Thread Gaetan Nadon
As I reverted this patch and found new issues, I ended up reverting 5 patches.
Solving conflicts is always risky, and some reversal were not bisectable.

I realized I could just revert the patches in the opposite direction
and have no conflicts at all.

The order of the reversal does not reflect the order in which problems have 
been found.
I would not recommend trying to modify some of the patches if a fix seems 
apparent.
I'd rather reviewers accept/reject this series as a unit of work.
Any desirable feature to be retained would be safer done/reviewed separatly.

Distcheck passes with each patch. None of them in between pacthes were related
to autotool or makefile. This seems the safest approach as 1.5 waiting around 
the corner.

Gaetan Nadon (5):
  Revert build: apply the distcheck tricks used in xf86-input-evdev
  Revert build: create object files following the sources' structure.
  Revert build: install documentation as part of make install.
  Revert build: collapse all Makefile.am files into a single
non-recursive one.
  Revert build: sort building of tools, ensure that cross-pkg-config
works.

 .gitignore  |4 --
 Makefile.am |  104 +--
 conf/Makefile.am|   27 +
 configure.ac|   13 +++---
 include/Makefile.am |   21 ++
 man/Makefile.am |   47 +++
 src/Makefile.am |   52 +
 test/.gitignore |6 +++
 test/Makefile.am|   15 +++
 tools/.gitignore|3 +
 tools/Makefile.am   |   32 
 11 files changed, 212 insertions(+), 112 deletions(-)
 create mode 100644 conf/Makefile.am
 create mode 100644 include/Makefile.am
 create mode 100644 man/Makefile.am
 create mode 100644 src/Makefile.am
 create mode 100644 test/.gitignore
 create mode 100644 test/Makefile.am
 create mode 100644 tools/.gitignore
 create mode 100644 tools/Makefile.am

-- 
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 input-synaptics 1/5] Revert build: apply the distcheck tricks used in xf86-input-evdev

2011-06-28 Thread Gaetan Nadon
This reverts commit 6eb829e07e455a8a04dabae7f257dd42a9b8bcdf.

Althought this feature is desirable, it introduces a dormant bug.

The value of sdkdir during distcheck points to an empty xserver sdkdir
where xserver-properties.h is expected by the tools.

Specifying XORG_CFLAGS for the tools worked around the issue by supplying
the real path to the xserver sdk. tools must not depend on xserver.
In any case it would be a brittle workaround.

This feature can be reintroduced later with the proper solution.

Signed-off-by: Gaetan Nadon mems...@videotron.ca
---
 Makefile.am  |6 --
 configure.ac |5 -
 2 files changed, 0 insertions(+), 11 deletions(-)

diff --git a/Makefile.am b/Makefile.am
index e94fe19..07cb902 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -18,12 +18,6 @@
 #  IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
 #  CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 
-# During distcheck, system locations (as provided by pkg-config) are
-# not writable; provide instead relative locations.
-DISTCHECK_CONFIGURE_FLAGS = \
-   --with-sdkdir='$${includedir}/xorg' \
-   --with-xorg-conf-dir='$${sysconfdir}/xorg'
-
 MAINTAINERCLEANFILES = ChangeLog INSTALL
 
 pkgconfigdir = $(libdir)/pkgconfig
diff --git a/configure.ac b/configure.ac
index bf99958..dfef591 100644
--- a/configure.ac
+++ b/configure.ac
@@ -146,11 +146,6 @@ if test x$have_libxtst = xyes ; then
 fi
 # -
 
-# Workaround overriding sdkdir to be able to create a tarball when user has no
-# write permission in sdkdir. See DISTCHECK_CONFIGURE_FLAGS in Makefile.am
-AC_ARG_WITH([sdkdir], [], [sdkdir=$withval])
-AC_SUBST([sdkdir])
-
 AC_CONFIG_FILES([Makefile
 xorg-synaptics.pc])
 AC_OUTPUT
-- 
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 input-synaptics 2/5] Revert build: create object files following the sources' structure.

2011-06-28 Thread Gaetan Nadon
This reverts commit dac624ad2b3a67ab93c11d8ee0a91b217fc1afe6.

Acked-by: Daniel Stone dan...@fooishbar.org
Signed-off-by: Gaetan Nadon mems...@videotron.ca
---
 .gitignore   |1 -
 configure.ac |2 +-
 2 files changed, 1 insertions(+), 2 deletions(-)

diff --git a/.gitignore b/.gitignore
index 39e3f35..2f191c3 100644
--- a/.gitignore
+++ b/.gitignore
@@ -79,4 +79,3 @@ core
 eventcomm-test
 synclient
 syndaemon
-.dirstamp
\ No newline at end of file
diff --git a/configure.ac b/configure.ac
index dfef591..e5427cd 100644
--- a/configure.ac
+++ b/configure.ac
@@ -31,7 +31,7 @@ AC_CONFIG_HEADERS([config.h])
 AC_CONFIG_AUX_DIR(.)
 
 # Initialize Automake
-AM_INIT_AUTOMAKE([foreign dist-bzip2 subdir-objects])
+AM_INIT_AUTOMAKE([foreign dist-bzip2])
 AM_MAINTAINER_MODE
 
 # Initialize libtool
-- 
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 input-synaptics 3/5] Revert build: install documentation as part of make install.

2011-06-28 Thread Gaetan Nadon
This reverts commit d27b4e560ccf61b94f067156c6d5c1e3d3e5e1eb.

ChangeLog is generated from git and should be created at dist time only.
The original patch creates it at make time multiple times and fails
when user permissions change such as when using sudo.

Some have expressed a desire to install files such as ChangeLog and README.
This reversal does not dismiss the idea, but simply reverts a non-essential
change that happens to have an implementation bug just before making a module
release.

Anyone is welcome to promote the idea in the context of the X.Org project
where all modules would exhibit the same behaviour. The current behaviour of
ChangeLog, although not perfect, has been thoroughly reviewed and widely
accepted for several years.

As for the files in docs, they should be re-submitted for reviews to determine
if they constitute users docs that should be installed as opposed to
developers docs which are not.

Reported-by: Daniel Stone dan...@fooishbar.org
Signed-off-by: Gaetan Nadon mems...@videotron.ca
---
 Makefile.am |3 ---
 1 files changed, 0 insertions(+), 3 deletions(-)

diff --git a/Makefile.am b/Makefile.am
index 07cb902..7cedc61 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -124,6 +124,3 @@ ChangeLog:
$(CHANGELOG_CMD)
 
 dist-hook: ChangeLog INSTALL
-
-dist_doc_DATA = ChangeLog README docs/README.alps  \
-   docs/trouble-shooting.txt docs/tapndrag.dia
-- 
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 input-synaptics 4/5] Revert build: collapse all Makefile.am files into a single non-recursive one.

2011-06-28 Thread Gaetan Nadon
This reverts commit 39afe69ad7d2258d4043044d1283bd6e311e48da.

Acked-by: Daniel Stone dan...@fooishbar.org
Signed-off-by: Gaetan Nadon mems...@videotron.ca
---
 .gitignore  |3 --
 Makefile.am |   95 +-
 conf/Makefile.am|   27 ++
 configure.ac|6 +++
 include/Makefile.am |   21 +++
 man/Makefile.am |   47 +
 src/Makefile.am |   52 
 test/.gitignore |6 +++
 test/Makefile.am|   15 
 tools/.gitignore|3 ++
 tools/Makefile.am   |   31 
 11 files changed, 210 insertions(+), 96 deletions(-)
 create mode 100644 conf/Makefile.am
 create mode 100644 include/Makefile.am
 create mode 100644 man/Makefile.am
 create mode 100644 src/Makefile.am
 create mode 100644 test/.gitignore
 create mode 100644 test/Makefile.am
 create mode 100644 tools/.gitignore
 create mode 100644 tools/Makefile.am

diff --git a/.gitignore b/.gitignore
index 2f191c3..c496323 100644
--- a/.gitignore
+++ b/.gitignore
@@ -76,6 +76,3 @@ core
 #  Edit the following section as needed
 # For example, !report.pc overrides *.pc. See 'man gitignore'
 # 
-eventcomm-test
-synclient
-syndaemon
diff --git a/Makefile.am b/Makefile.am
index 7cedc61..edd28a6 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -18,104 +18,13 @@
 #  IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
 #  CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 
+SUBDIRS = include src man tools conf test
 MAINTAINERCLEANFILES = ChangeLog INSTALL
 
 pkgconfigdir = $(libdir)/pkgconfig
 pkgconfig_DATA = xorg-synaptics.pc
 
-sdk_HEADERS = include/synaptics.h include/synaptics-properties.h
-
-input_LTLIBRARIES = @DRIVER_NAME@_drv.la
-
-# -module lets us name the module exactly how we want
-# -avoid-version prevents gratuitous .0.0.0 version numbers on the end
-# -shared avoid building the static archive
-@DRIVER_NAME@_drv_la_LDFLAGS = -module -avoid-version -shared
-@DRIVER_NAME@_drv_la_CPPFLAGS = -I$(top_srcdir)/include
-@DRIVER_NAME@_drv_la_CFLAGS = $(XORG_CFLAGS)
-
-@DRIVER_NAME@_drv_la_SOURCES = src/@DRIVER_NAME@.c src/synapticsstr.h \
-   src/synproto.h \
-   src/properties.c
-
-if BUILD_PS2COMM
-@DRIVER_NAME@_drv_la_SOURCES += \
-   src/alpscomm.c \
-   src/ps2comm.c src/ps2comm.h
-endif
-
-if BUILD_EVENTCOMM
-@DRIVER_NAME@_drv_la_SOURCES += \
-   src/eventcomm.c src/eventcomm.h
-endif
-
-if BUILD_PSMCOMM
-@DRIVER_NAME@_drv_la_SOURCES += \
-   src/psmcomm.c
-endif
-
-bin_PROGRAMS = synclient syndaemon
-
-synclient_SOURCES = tools/synclient.c
-synclient_CFLAGS = -I$(top_srcdir)/include $(XORG_CFLAGS) $(XI_CFLAGS)
-synclient_LDADD = $(XI_LIBS)
-
-syndaemon_SOURCES = tools/syndaemon.c
-syndaemon_CFLAGS = -I$(top_srcdir)/include $(XORG_CFLAGS) $(XI_CFLAGS) 
$(XTST_CFLAGS)
-syndaemon_LDADD = $(XI_LIBS) $(XTST_LIBS)
-
-if HAS_XORG_CONF_DIR
-dist_config_DATA = conf/50-synaptics.conf
-else
-fdidir = $(datadir)/hal/fdi/policy/20thirdparty
-dist_fdi_DATA = conf/11-x11-synaptics.fdi
-endif
-
-if ENABLE_UNIT_TESTS
-if BUILD_EVENTCOMM
-check_PROGRAMS = eventcomm-test
-
-eventcomm_test_CPPFLAGS = -I$(top_srcdir)/src -I$(top_srcdir)/include
-eventcomm_test_CFLAGS = $(XORG_CFLAGS) $(CWARNFLAGS)
-eventcomm_test_SOURCES = test/eventcomm-test.c\
-src/eventcomm.c \
-test/fake-symbols.c test/fake-symbols.h
-
-TESTS = $(check_PROGRAMS)
-endif
-endif
-
-synclientmandir = $(APP_MAN_DIR)
-synclientman_PRE = man/synclient.man
-synclientman_DATA = $(synclientman_PRE:man=@APP_MAN_SUFFIX@)
-
-syndaemonmandir = $(APP_MAN_DIR)
-syndaemonman_PRE = man/syndaemon.man
-syndaemonman_DATA = $(syndaemonman_PRE:man=@APP_MAN_SUFFIX@)
-
-drivermandir = $(DRIVER_MAN_DIR)
-driverman_PRE = man/@DRIVER_NAME@.man
-driverman_DATA = $(driverman_PRE:man=@DRIVER_MAN_SUFFIX@)
-
-EXTRA_DIST = man/@DRIVER_NAME@.man man/synclient.man man/syndaemon.man
-
-CLEANFILES = $(driverman_DATA) $(synclientman_DATA) $(syndaemonman_DATA)
-
-SUFFIXES = .$(DRIVER_MAN_SUFFIX) .man
-
-.PHONY: ChangeLog INSTALL mandir
-
-mandir:
-   $(MKDIR_P) man
-
-# String replacements in MAN_SUBSTS now come from xorg-macros.m4 via configure
-.man.$(DRIVER_MAN_SUFFIX):
-   @$(MKDIR_P) man
-   $(AM_V_GEN)$(SED) $(MAN_SUBSTS)  $  $@
-
-.man.$(APP_MAN_SUFFIX):
-   @$(MKDIR_P) man
-   $(AM_V_GEN)$(SED) $(MAN_SUBSTS)  $  $@
+.PHONY: ChangeLog INSTALL
 
 INSTALL:
$(INSTALL_CMD)
diff --git a/conf/Makefile.am b/conf/Makefile.am
new file mode 100644
index 000..38d2a01
--- /dev/null
+++ b/conf/Makefile.am
@@ -0,0 +1,27 @@
+#  Copyright 2005 Adam Jackson.
+#
+#  Permission is hereby granted, free of charge, to any person obtaining a
+#  copy of this software and associated documentation files (the Software),
+#  to deal in the Software without restriction, including without limitation
+#  on the rights to use, copy, modify, 

[PATCH input-synaptics 5/5] Revert build: sort building of tools, ensure that cross-pkg-config works.

2011-06-28 Thread Gaetan Nadon
This reverts commit 4005df66072ceac175ea71427deb16176262f197.

The patch introduces a couple of issues.
1) These tools are apps and conceptually do not depend on Xserver,
so XORG_CFLAGS should not be used. It included pixman header files.
Only drivers depend xserver

2) XORG_CFLAGS may contain, depending on the platform, a compiler
visibilty flag. Compiler flags cannot be assigned to AM_CPPFLAGS
preprocessor flags variable.

There were two changes introduced by the patch.
1) Possible wrong order of include directives
The commit text does not mention which paths may be in the wrong order.

2) Incorrect usage of AM_LDFLAGS
The patch does not really change anything. If the intention was for the tools
to link directly to the libraries, it would look like:

  LDADD =  $(top_builddir)/src/libpciaccess.la # scanpci example

This is only possible for libraries built in the same package.
There is nothing wrong in putting -l -L flags in LDADD, but should there
be other flags, LDFLAGS would be required, ending with two variables.

It looks easier to revert the patch to the previosuly known good version
which has been in service for a year.

Unfortunatly, the reversal breaks distcheck as it removes an unsuspected 
workaround.
The value of sdkdir during distcheck points to an empty xserver sdkdir
where xserver-properties.h is expected by the tools.

Specifying XORG_CFLAGS worked around the issue by supplying the real path
to the xserver sdk.

Signed-off-by: Gaetan Nadon mems...@videotron.ca
---
 tools/Makefile.am |   11 ++-
 1 files changed, 6 insertions(+), 5 deletions(-)

diff --git a/tools/Makefile.am b/tools/Makefile.am
index c74a5e3..2ad48f6 100644
--- a/tools/Makefile.am
+++ b/tools/Makefile.am
@@ -20,12 +20,13 @@
 
 bin_PROGRAMS = synclient syndaemon
 
-AM_CPPFLAGS = -I$(top_srcdir)/include $(XORG_CFLAGS)
+AM_CPPFLAGS = -I$(top_srcdir)/include -I$(sdkdir)
+AM_CFLAGS = $(XI_CFLAGS)
+AM_LDFLAGS = $(XI_LIBS)
 
 synclient_SOURCES = synclient.c
-synclient_CFLAGS = $(XI_CFLAGS)
-synclient_LDADD = $(XI_LIBS)
 
 syndaemon_SOURCES = syndaemon.c
-syndaemon_CFLAGS = $(XI_CFLAGS) $(XTST_CFLAGS)
-syndaemon_LDADD = $(XI_LIBS) $(XTST_LIBS)
+syndaemon_CFLAGS = $(AM_CFLAGS) $(XTST_CFLAGS)
+syndaemon_LDFLAGS = $(AM_LDFLAGS) $(XTST_LIBS)
+
-- 
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 30/37] Unify miinitext.c

2011-06-28 Thread Jeremy Huddleston
This patch removes this XQuartz extension which needs to be initialized in the 
new common path.

#ifdef INXQUARTZ
if(!noPseudoramiXExtension) PseudoramiXExtensionInit();
#endif

Is this on a branch of your personal git repo for testing?

On Jun 28, 2011, at 12:27, Daniel Stone wrote:

 Rather than having a non-Xorg and an Xorg-specific path which basically
 just duplicated each other for no reason, we could ... just have one.
 
 Signed-off-by: Daniel Stone dan...@fooishbar.org
 ---
 hw/xfree86/dixmods/Makefile.am |2 +-
 mi/miinitext.c |   91 
 2 files changed, 1 insertions(+), 92 deletions(-)
 
 diff --git a/hw/xfree86/dixmods/Makefile.am b/hw/xfree86/dixmods/Makefile.am
 index 4173983..546a2f7 100644
 --- a/hw/xfree86/dixmods/Makefile.am
 +++ b/hw/xfree86/dixmods/Makefile.am
 @@ -41,7 +41,7 @@ libshadow_la_LIBADD = 
 $(top_builddir)/miext/shadow/libshadow.la
 libshadow_la_SOURCES = shmodule.c
 
 libdixmods_la_SOURCES = $(top_srcdir)/mi/miinitext.c
 -libdixmods_la_CFLAGS = -DXFree86LOADER $(AM_CFLAGS)
 +libdixmods_la_CFLAGS = $(AM_CFLAGS)
 
 libxorgxkb_la_SOURCES = xkbVT.c xkbPrivate.c xkbKillSrv.c
 libxorgxkb_la_LIBADD = $(top_builddir)/dix/libdix.la
 diff --git a/mi/miinitext.c b/mi/miinitext.c
 index 9d359e7..c1141fb 100644
 --- a/mi/miinitext.c
 +++ b/mi/miinitext.c
 @@ -162,11 +162,6 @@ extern Bool noXvExtension;
 #endif
 extern Bool noGEExtension;
 
 -#ifndef XFree86LOADER
 -#else /* XFree86Loader */
 -#include loaderProcs.h
 -#endif
 -
 #ifdef MITSHM
 #include X11/extensions/shm.h
 #endif
 @@ -397,90 +392,6 @@ void EnableDisableExtensionError(char *name, Bool enable)
 }
 }
 
 -#ifndef XFree86LOADER
 -
 -/*ARGSUSED*/
 -void
 -InitExtensions(int argc, char *argv[])
 -{
 -if (!noGEExtension) GEExtensionInit();
 -ShapeExtensionInit();
 -#ifdef MITSHM
 -if (!noMITShmExtension) ShmExtensionInit();
 -#endif
 -XInputExtensionInit();
 -#ifdef XTEST
 -if (!noTestExtensions) XTestExtensionInit();
 -#endif
 -BigReqExtensionInit();
 -SyncExtensionInit();
 -XkbExtensionInit();
 -XCMiscExtensionInit();
 -#ifdef XCSECURITY
 -if (!noSecurityExtension) SecurityExtensionInit();
 -#endif
 -#ifdef PANORAMIX
 -if (!noPanoramiXExtension) PanoramiXExtensionInit();
 -#endif
 -#ifdef INXQUARTZ
 -if(!noPseudoramiXExtension) PseudoramiXExtensionInit();
 -#endif
 -#ifdef XFIXES
 -/* must be before Render to layer DisplayCursor correctly */
 -if (!noXFixesExtension) XFixesExtensionInit();
 -#endif
 -#ifdef XF86BIGFONT
 -if (!noXFree86BigfontExtension) XFree86BigfontExtensionInit();
 -#endif
 -if (!noRenderExtension) RenderExtensionInit();
 -#ifdef RANDR
 -if (!noRRExtension) RRExtensionInit();
 -#endif
 -#ifdef COMPOSITE
 -if (!noCompositeExtension) CompositeExtensionInit();
 -#endif
 -#ifdef DAMAGE
 -if (!noDamageExtension) DamageExtensionInit();
 -#endif
 -
 -#ifdef XSELINUX
 -if (!noSELinuxExtension) SELinuxExtensionInit();
 -#endif
 -#if defined(SCREENSAVER)
 -if (!noScreenSaverExtension) ScreenSaverExtensionInit ();
 -#endif
 -
 -#if !defined(NO_HW_ONLY_EXTS)  defined(DPMSExtension)
 -if (!noDPMSExtension) DPMSExtensionInit();
 -#endif
 -
 -#ifdef XV
 -if (!noXvExtension) {
 -  XvExtensionInit();
 -  XvMCExtensionInit();
 -}
 -#endif
 -#ifdef RES
 -if (!noResExtension) ResExtensionInit();
 -#endif
 -#ifdef XRECORD
 -if (!noTestExtensions) RecordExtensionInit(); 
 -#endif
 -#ifdef DBE
 -if (!noDbeExtension) DbeExtensionInit();
 -#endif
 -#ifdef DMXEXT
 -DMXExtensionInit(); /* server-specific extension, cannot be disabled */
 -#endif
 -
 -#ifdef GLXEXT
 -if (serverGeneration == 1)
 - GlxPushProvider(__glXDRISWRastProvider);
 -if (!noGlxExtension) GlxExtensionInit();
 -#endif
 -}
 -
 -#else /* XFree86LOADER */
 /* List of built-in (statically linked) extensions */
 static ExtensionModule staticExtensions[] = {
 { GEExtensionInit, Generic Event Extension, noGEExtension, NULL, NULL},
 @@ -619,5 +530,3 @@ LoadExtension(ExtensionModule * e, Bool builtin)
 if (e-setupFunc != NULL)
   e-setupFunc();
 }
 -
 -#endif /* XFree86LOADER */
 -- 
 1.7.5.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


Re: [PATCH 30/37] Unify miinitext.c

2011-06-28 Thread Daniel Stone
Hi,

On Tue, Jun 28, 2011 at 03:57:35PM -0700, Jeremy Huddleston wrote:
 This patch removes this XQuartz extension which needs to be initialized in 
 the new common path.
 
 #ifdef INXQUARTZ
 if(!noPseudoramiXExtension) PseudoramiXExtensionInit();
 #endif

Damnit, sorry about that.  The real solution here, as with the DMX
extension which I now realise I've also binned, is to move DDX-specific
extension code to, well, the DDX.  hw/xfree86/common/xf86Extensions.c
offers a decent model of how to do this.

I'll try to cook up a patch for this in the next day or two.  Good
looking out, thanks.

 Is this on a branch of your personal git repo for testing?

Yep!

git://people.freedesktop.org/~daniels/xserver extension-cleanup

Which is a bit more up-to-date than the patchset sent to the list,
having been rebased on top of Dan's libxorg removal.

Cheers,
Daniel
___
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] randr: Take panning into account when computing CRTC bounds

2011-06-28 Thread Rui Matos
Fixes regression introduced in 56c90e29f04727c903bd0f084d23bf44eb1a0a11.

Signed-off-by: Rui Matos tiagoma...@gmail.com
---
 randr/rrcrtc.c |   54 +++---
 1 files changed, 47 insertions(+), 7 deletions(-)

diff --git a/randr/rrcrtc.c b/randr/rrcrtc.c
index 0437795..a940847 100644
--- a/randr/rrcrtc.c
+++ b/randr/rrcrtc.c
@@ -297,20 +297,60 @@ RRCrtcPendingProperties (RRCrtcPtr crtc)
 static void
 crtc_bounds(RRCrtcPtr crtc, int *left, int *right, int *top, int *bottom)
 {
-*left = crtc-x;
-*top = crtc-y;
+ScreenPtr pScreen = crtc-pScreen;
+rrScrPriv (pScreen);
+BoxRec panned_area;
+Bool x_pan = FALSE;
+Bool y_pan = FALSE;
+
+if (pScrPriv-rrGetPanning 
+pScrPriv-rrGetPanning(pScreen, crtc, panned_area, NULL, NULL))
+{
+x_pan = panned_area.x2  panned_area.x1;
+y_pan = panned_area.y2  panned_area.y1;
+}
 
 switch (crtc-rotation) {
 case RR_Rotate_0:
 case RR_Rotate_180:
 default:
-   *right = crtc-x + crtc-mode-mode.width;
-   *bottom = crtc-y + crtc-mode-mode.height;
-   return;
+
+if (x_pan) {
+*left = panned_area.x1;
+*right = panned_area.x2;
+} else {
+*left = crtc-x;
+*right = crtc-x + crtc-mode-mode.width;
+}
+
+if (y_pan) {
+*top = panned_area.y1;
+*bottom = panned_area.y2;
+} else {
+*top = crtc-y;
+*bottom = crtc-y + crtc-mode-mode.height;
+}
+
+return;
 case RR_Rotate_90:
 case RR_Rotate_270:
-   *right = crtc-x + crtc-mode-mode.height;
-   *bottom = crtc-y + crtc-mode-mode.width;
+
+if (x_pan) {
+*left = panned_area.x1;
+*right = panned_area.x2;
+} else {
+*left = crtc-x;
+*right = crtc-x + crtc-mode-mode.height;
+}
+
+if (y_pan) {
+*top = panned_area.y1;
+*bottom = panned_area.y2;
+} else {
+*top = crtc-y;
+*bottom = crtc-y + crtc-mode-mode.width;
+}
+
return;
 }
 }
-- 
1.7.5.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


[PULL] valuator double work

2011-06-28 Thread Peter Hutterer
This is admittedly a larger-than-usual pull request but I'd like this to be
in 1.11. The main chunk of this work is the switch to use double valuators
which will eventually enable smooth scrolling. Note that no new feature is
introduced with this part, it's simply the underlying changes. Smooth
scrolling will be in 1.12.

The other parts of this request are grab/window tree debugging plus a few
misc fixes.

The following changes since commit 9d568450b1319e9057319ebb37e76003bcba447d:

  Create sdksyms.dep in the right place at configure time (2011-06-28 09:33:25 
-0700)

are available in the git repository at:
  git://people.freedesktop.org/~whot/xserver.git for-keith

Daniel Stone (30):
  DIX: Make PrintWindowTree actually useful
  XKB: Add debug key actions for grabs  window tree
  XWin: Remove executable bit from headers
  DMX: Remove useless miPointerUpdateSprite call
  KDrive: Remove useless miPointerUpdateSprite call
  Test: Ensure libxservertest gets relinked when necessary
  Test: Input: Only ever set up to MAX_VALUATORS valuators
  Input: Add flags to DeviceEvent
  Input: Add flags to RawDeviceEvent
  Input: Reset SD remainder when copying co-ords from MD
  Input: Convert ValuatorMask to double-precision internally
  Input: Add double-precision valuator_mask API
  Input: Store clipped absolute axes in the mask
  Input: Prepare moveAbsolute for conversion to double
  Input: Prepare moveRelative for conversion to double
  Input: Convert clipAxis, moveAbsolute and moveRelative to double
  Input: Convert transformAbsolute to work on doubles
  Input: Set fractional member in set_raw_valuators
  Input: Use trunc instead of lrintf in acceleration code
  Input: Widen pointer acceleration types to double
  Input: Convert acceleration code to using ValuatorMask
  Input: Remove x and y from moveAbsolute/moveRelative
  Input: Convert rescaleValuatorAxis to double
  Input: Don't call positionSprite for non-pointer devices
  Input: Convert positionSprite and GetPointerEvents to double
  Input: Modify mask in-place in positionSprite
  Input: Make RawDeviceEvent use doubles internally
  Input: Make DeviceEvent use doubles internally
  Input: Convert DeviceIntRec::last to use doubles
  Input: Set last valuators in GetPointerEvents only

Marcin Slusarz (1):
  dri2: restore Screen-ConfigNotify on close

Matěj Cepl (1):
  Fix UTF-8 encoding

Peter Hutterer (5):
  input: add POINTER_NORAW to avoid generation of raw events (#30068)
  input: free the EQ allocated memory on shutdown (#38634)
  xfree86: Remove devices that failed to enable on startup
  input: add POINTER_NORAW to avoid generation of raw events (#30068)
  Merge branch 'for-peter' of git://people.freedesktop.org/~daniels/xserver

Scott James Remnant (1):
  dix: avoid calling deleted block and wakeup handlers

 Xext/xtest.c|9 +-
 Xi/exevents.c   |5 +-
 Xi/xiwarppointer.c  |2 -
 dix/dixutils.c  |   10 +-
 dix/eventconvert.c  |   20 +-
 dix/getevents.c |  387 +-
 dix/grabs.c |  112 +
 dix/inpututils.c|   32 ++-
 dix/ptrveloc.c  |  259 +
 dix/window.c|  139 +--
 exa/exa.c   |4 +-
 exa/exa_accel.c |6 +-
 exa/exa_classic.c   |2 +-
 exa/exa_driver.c|2 +-
 exa/exa_migration_classic.c |4 +-
 exa/exa_migration_mixed.c   |2 +-
 exa/exa_mixed.c |2 +-
 exa/exa_unaccel.c   |2 +-
 hw/dmx/dmxinput.c   |1 +
 hw/dmx/input/dmxinputinit.c |3 -
 hw/kdrive/ephyr/ephyr.c |2 +-
 hw/kdrive/ephyr/ephyr.h |2 +-
 hw/kdrive/ephyr/ephyr_draw.c|2 +-
 hw/kdrive/ephyr/ephyrinit.c |3 +-
 hw/kdrive/ephyr/hostx.c |2 +-
 hw/kdrive/ephyr/hostx.h |2 +-
 hw/kdrive/ephyr/os.c|2 +-
 hw/kdrive/fake/fakeinit.c   |1 +
 hw/kdrive/fake/kbd.c|2 +-
 hw/kdrive/fbdev/fbdev.c |2 +-
 hw/kdrive/fbdev/fbdev.h |2 +-
 hw/kdrive/fbdev/fbinit.c|3 +-
 hw/kdrive/linux/keyboard.c  |8 +-
 hw/kdrive/linux/linux.c |2 +-
 hw/kdrive/linux/mouse.c |2 +-
 hw/kdrive/linux/ps2.c   |2 +-
 hw/kdrive/linux/tslib.c |   10 +-
 hw/kdrive/src/kcmap.c   |2 +-
 hw/kdrive/src/kdrive.h