xserver: Branch 'master' - 5 commits
Keith Packard
keithp at kemper.freedesktop.org
Tue Jul 10 01:05:43 PDT 2012
Makefile.am | 7 +++++++
dix/privates.c | 5 +++++
hw/xfree86/common/xf86Init.c | 6 ++++--
include/os.h | 3 +++
os/osinit.c | 1 +
os/utils.c | 13 +++++++++++++
6 files changed, 33 insertions(+), 2 deletions(-)
New commits:
commit 6e12cb147da58bd12a158807b2cd5afac32ae70f
Merge: 532fbc2... 0231279...
Author: Keith Packard <keithp at keithp.com>
Date: Tue Jul 10 00:52:11 2012 -0700
Merge branch 'local-fixes'
commit 023127915e6922bc53e4c768de760d8a4f25c07c
Author: Keith Packard <keithp at keithp.com>
Date: Mon Jul 9 16:34:39 2012 -0700
Reliably reset signals at server init time
Each DDX currently calls OsReleaseSIGIO in case it was suspended when
the server regen started. This causes a BUG to occur if SIGIO was
*not* blocked at that time. Instead of relying on each DDX, make the
OS layer reliably reset all signal state at server init time, ensuring
that signals are suitably unblocked and that the various signal state
counting variables are set back to zero.
Signed-off-by: Keith Packard <keithp at keithp.com>
diff --git a/hw/xfree86/common/xf86Init.c b/hw/xfree86/common/xf86Init.c
index 9c31d82..0dedd7c 100644
--- a/hw/xfree86/common/xf86Init.c
+++ b/hw/xfree86/common/xf86Init.c
@@ -1012,7 +1012,6 @@ OsVendorInit(void)
}
#endif
#endif
- OsReleaseSIGIO();
beenHere = TRUE;
}
diff --git a/include/os.h b/include/os.h
index 34ca1f5..7701c39 100644
--- a/include/os.h
+++ b/include/os.h
@@ -340,6 +340,9 @@ OsBlockSIGIO(void);
extern _X_EXPORT void
OsReleaseSIGIO(void);
+extern void
+OsResetSignals(void);
+
extern _X_EXPORT void
OsAbort(void)
_X_NORETURN;
diff --git a/os/osinit.c b/os/osinit.c
index 6cc0401..2eb1f7a 100644
--- a/os/osinit.c
+++ b/os/osinit.c
@@ -288,6 +288,7 @@ OsInit(void)
}
TimerInit();
OsVendorInit();
+ OsResetSignals();
/*
* No log file by default. OsVendorInit() should call LogInit() with the
* log file name if logging to a file is desired.
diff --git a/os/utils.c b/os/utils.c
index 2537934..82192e8 100644
--- a/os/utils.c
+++ b/os/utils.c
@@ -1243,6 +1243,19 @@ OsReleaseSignals(void)
#endif
}
+void
+OsResetSignals(void)
+{
+#ifdef SIG_BLOCK
+ while (BlockedSignalCount > 0)
+ OsReleaseSignals();
+#ifdef SIGIO
+ while (sigio_blocked > 0)
+ OsReleaseSIGIO();
+#endif
+#endif
+}
+
/*
* Pending signals may interfere with core dumping. Provide a
* mechanism to block signals when aborting.
commit d6756e0298e660a0aca58d75bcf79471ce07a634
Author: Keith Packard <keithp at keithp.com>
Date: Mon Jul 9 16:33:11 2012 -0700
xfree86: In InitOutput, only call OsReleaseSIGIO if OsBlockSIGIO was called
Otherwise, OsReleaseSIGIO will complain, or perhaps something worse
will happen (if SIGIO actually needs to be blocked here).
Signed-off-by: Keith Packard <keithp at keithp.com>
diff --git a/hw/xfree86/common/xf86Init.c b/hw/xfree86/common/xf86Init.c
index 058d09f..9c31d82 100644
--- a/hw/xfree86/common/xf86Init.c
+++ b/hw/xfree86/common/xf86Init.c
@@ -401,6 +401,7 @@ InitOutput(ScreenInfo * pScreenInfo, int argc, char **argv)
MessageType pix24From = X_DEFAULT;
Bool pix24Fail = FALSE;
Bool autoconfig = FALSE;
+ Bool sigio_blocked = FALSE;
GDevPtr configured_device;
xf86Initialising = TRUE;
@@ -819,6 +820,7 @@ InitOutput(ScreenInfo * pScreenInfo, int argc, char **argv)
#endif
xf86AccessEnter();
OsBlockSIGIO();
+ sigio_blocked = TRUE;
}
}
@@ -924,7 +926,8 @@ InitOutput(ScreenInfo * pScreenInfo, int argc, char **argv)
AttachUnboundGPU(xf86Screens[0]->pScreen, xf86GPUScreens[i]->pScreen);
xf86VGAarbiterWrapFunctions();
- OsReleaseSIGIO();
+ if (sigio_blocked)
+ OsReleaseSIGIO();
xf86InitOrigins();
commit ea8b04507e5464e4817791db516a20cfed2a6724
Author: Keith Packard <keithp at keithp.com>
Date: Mon Jul 9 16:30:24 2012 -0700
privates: Resize GPU screen-specific privates too
When allocating new global privates, make sure the gpu
screens get their private offsets updated.
This only affects GPU screens that enumerate before the non-GPU
screens, which generally requires that the related device be present
when the system boots so that it can get an earlier DRM filename.
Signed-off-by: Keith Packard <keithp at keithp.com>
diff --git a/dix/privates.c b/dix/privates.c
index 740ead7..55b9345 100644
--- a/dix/privates.c
+++ b/dix/privates.c
@@ -317,6 +317,11 @@ grow_screen_specific_set(DevPrivateType type, unsigned bytes)
grow_private_set(&pScreen->screenSpecificPrivates[type], bytes);
}
+ for (s = 0; s < screenInfo.numGPUScreens; s++) {
+ ScreenPtr pScreen = screenInfo.gpuscreens[s];
+
+ grow_private_set(&pScreen->screenSpecificPrivates[type], bytes);
+ }
}
/*
commit d1c639c006526b8cab14dac582508f3f54848967
Author: Keith Packard <keithp at keithp.com>
Date: Mon Jul 9 16:29:04 2012 -0700
Add 'install-headers' target in the top-level Makefile
This target recursively locates directories with sdk headers and
installs them all. Useful when you want to build a complete new X
server and drivers without having to install the X server before the
drivers are actually working.
Signed-off-by: Keith Packard <keithp at keithp.com>
diff --git a/Makefile.am b/Makefile.am
index cea140b..9a62853 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -95,3 +95,10 @@ DIST_SUBDIRS = \
# gross hack
relink: all
$(AM_V_at)$(MAKE) -C hw relink
+
+install-headers: Makefile
+ +find . -name Makefile | while read m; do \
+ if grep -q install-sdkHEADERS $$m; then \
+ (cd `dirname "$$m"` && make install-sdkHEADERS) \
+ fi \
+ done
More information about the xorg-commit
mailing list