Commit Graph

506 Commits

Author SHA1 Message Date
Peter Hutterer
6b6b660c36 Xext: remove ev_fill from GEExtensions. 2009-03-20 15:17:54 +10:00
Peter Hutterer
445daa62e7 Xext: purge XGE event masks.
The masks were originally designed to generically handle event masks for
extensions. Since all that is in-server anyway, it's much better writing
custom event masks for those extensions that need it and not providing a
unified mechanism.
XI2 needs more than the current implementation, which is already too complex
for most other extensions. good riddance.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2009-03-20 15:17:53 +10:00
Adam Jackson
3992dd38ca selinux: Add support for avc_acquire_netlink_fd()
Requires libselinux 2.0.79 or newer.  Without this, libselinux will
check for policy updates on the netlink socket on basically every policy
lookup.  Statistically speaking, they never happen, and the check
translates to at least one more syscall on basically every operation.

Instead, take control of the fd from the library, and check it in
WakeupHandler if it polls readable.
2009-03-16 13:24:48 -04:00
Keith Packard
f8dd80d13b Replace dixLookupResource by dixLookupResourceBy{Type,Class}
dixLookupResource attempted to automatically detect whether the caller
wanted a lookup by-type or by-class, unfortunately, it guessed wrong for
RT_NONE. Instead of trying to make the guess better, this patch just reverts
the unification and creates separate functions for each operation.
2009-03-09 13:08:09 -07:00
Eamon Walsh
c7ebb4bef1 Fix 2 const warnings. 2009-03-03 14:02:36 -05:00
Eric Paris
c7cf926d25 This patch changes all places in the X code to use _raw functions. The
X server should never see, translate, or deal with a munged context.
Display managers which show contexts to the user should take care of
translating these to human readable form.
2009-03-03 13:15:39 -05:00
Adam Jackson
b030f858f2 selinux: Don't bother relabeling resources that are being destroyed
Makes window destroy about 40x faster in Xvfb.
2009-02-27 12:45:19 -05:00
Peter Hutterer
36583a4996 mi: split EQ popping and event processing into two functions.
mieqProcessInputEvents() - pop an event off the EQ and pass it to
mieqProcessDeviceEvent() - process the event according to the MD/SD hierarchy.

This way, we can use mieqPDE() from Xtest, xkb, and others to post an event.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2009-02-23 17:52:40 +10:00
Eric Anholt
b349a764e9 xinerama: Put the proto version in the code instead using proto headers.
Proto headers updating resulting in the server advertising new versions is
broken.  This should be applied to every extension.

This fixes the build against slightly-older xineramaproto.
2009-02-17 15:28:29 -08:00
Peter Åstrand
ddb8d8945d xserver: Avoid sending uninitialized padding data over the network
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2009-02-16 13:28:38 +10:00
Benjamin Close
a38ca0063c xext: Use proto header rather than the Xext include file, this prevents userspace being pulled in causing issues
Signed-off-by: Benjamin Close <Benjamin.Close@clearchain.com>
Acked-by: Peter Hutterer <peter.hutterer@who-t.net>
Acked-by: Daniel Stone <daniel@fooishbar.org>
2009-02-13 17:24:37 +10:30
Peter Hutterer
43a1c91a3d Xext: fix typo in GEEventFill macro
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2009-02-03 11:17:02 +10:00
Peter Hutterer
faeb18eb7e Xext: rename shape's EventType to ShapeEventType to avoid name clashing.
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2009-02-03 08:51:11 +10:00
Peter Hutterer
cfd3443fe8 Xext: rename saver's EventType to SaverEventType.
Avoid namespace clashing with the internal events.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2009-02-03 08:51:11 +10:00
Paulo Cesar Pereira de Andrade
4e7bc2d7a9 Work around inclusion of <X11/extensions/panoramiXext.h>
The X Server build only needs the macros PANORAMIX_MAJOR_VERSION
and PANORAMIX_MINOR_VERSION from that header.
  Addition of extra prototypes to <X11/extensions/panoramiXext.h>
caused a X Server build failure.
2009-01-30 03:56:39 -02:00
Adam Jackson
132b464d73 Remove a bunch of useless casts.
We've had void * for twenty years now people let's try to act like we
know how it works.
2009-01-22 02:11:16 -05:00
Daniel Stone
4fa3872dc2 Input: Remove core keysyms from KeyClassRec
Instead of always keeping two copies of the keymap, only generate the
core keymap from the XKB keymap when we really need to, and use the XKB
keymap as the canonical keymap.

Signed-off-by: Daniel Stone <daniel@fooishbar.org>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2009-01-22 15:08:59 +11:00
Adam Jackson
e45a8a498d Remove CreateUnclippedWinSize from window.h
This is utterly wrong, but then, so is sdksyms.sh
2009-01-20 22:07:07 -05:00
Adam Jackson
20d2117eb8 Move CreateUnclippedWinSize to mbuf
It's the only user, so.
2009-01-20 00:18:02 -05:00
Peter Hutterer
e30032d0bb Xext: clean up XGE macros.
Signed-off-by: Peter Hutterer <peter.hutterer@redhat.com>
2009-01-15 16:11:02 +10:00
Julien Cristau
6e20a4ae73 xsync: make SyncAlarmCounterDestroyed static 2009-01-11 08:54:10 +01:00
Julien Cristau
292311b421 Xext: ANSI cleanups 2009-01-11 08:54:10 +01:00
Thomas Jaeger
b2756a71a4 Xext: Send out correct events in ProcXTestFakeInput
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2009-01-09 17:49:26 +10:00
Peter Hutterer
83eb863e3c Xext: don't accept DeviceValuator if the dev doesn't have valuators (in xtest)
Reported by Chris Ball.
2009-01-09 16:08:58 +10:00
Paulo Cesar Pereira de Andrade
200230535f Update sdk headers to export new symbols.
All symbols in installed sdk headers should be explicitly tagged
as exported symbols. Otherwise, to ensure it is not a mistake, one
could write it as something like:
extern /* NOEXPORT */ type name ...;
but the proper procedure really should be to use a non sdk header
(or a "noinst_" one).
  This patch also removes prototypes to some functions that existed
only temporarily.
2009-01-05 16:49:57 -02:00
Adam Jackson
f2d1de6c2a xv: remove useless XVCALL macro 2008-12-19 10:27:37 -05:00
Eamon Walsh
5d065a8890 xselinux: Use xace Xtrans wrappers instead of the now-inaccessible wrapees. 2008-12-18 14:01:10 -05:00
Eamon Walsh
f87e66486c xace: Export wrappers around two Xtrans functions used by modules.
Don't know a better way to do this, since Xtrans isn't a library that
can be linked into modules.
2008-12-18 13:58:35 -05:00
Eamon Walsh
777408914d Add xace headers to the SDK when enabled and export the XaceHooks symbol
to modules.
2008-12-18 12:39:08 -05:00
Peter Hutterer
cb95642dc8 Remove #define NEED_EVENTS and NEED_REPLIES
A grep on xorg/* revealed there's no consumer of this define.

Quote Alan Coopersmith:
"The consumer was in past versions of the headers now located
in proto/x11proto - for instance, in X11R6.0's xc/include/Xproto.h,
all the event definitions were only available if NEED_EVENTS were
defined, and all the reply definitions required NEED_REPLIES.

Looks like Xproto.h dropped them by X11R6.3, which didn't have
the #ifdef's anymore, so these are truly ancient now."

Signed-off-by: Peter Hutterer <peter.hutterer@redhat.com>
Signed-off-by: Adam Jackson <ajax@redhat.com>
2008-12-12 11:43:32 +10:00
Adam Jackson
beb749c87f Fix syncsrv.h guard define 2008-12-11 17:04:37 -05:00
Colin Harrison
9fba808b4f xsync: Prototype fix. 2008-12-11 13:22:53 -05:00
Adam Jackson
dce887ff53 xsync: build fix
argh protocol header disaster
2008-12-11 13:16:41 -05:00
Adam Jackson
1f4fb0225b xsync: Fix wakeup storm in idletime counter.
Wakeup scheduling only considered the threshold values, and not whether
the trigger was edge or level.

See also:
https://bugzilla.redhat.com/show_bug.cgi?id=474586
http://svn.gnome.org/viewvc/gnome-screensaver/trunk/src/test-idle-ext.c?view=markup
2008-12-11 10:31:48 -05:00
Adam Jackson
1a99110f0c xsync: ANSI cleanups 2008-12-11 10:31:45 -05:00
Adam Jackson
e0d8f6a808 xsync: Use a local header for server API definitions 2008-12-11 10:16:46 -05:00
Adam Jackson
1208a1dbca xsync: remove cast abuse. 2008-12-11 10:16:46 -05:00
Paulo Cesar Pereira de Andrade
b1dac41fb3 Use libtool convenience libraries and better "symbol" table.
All .a libraries were converted to .la, and instead of linking the
Xorg binary with a mix of .a and .la, and adding some libraries more
then once in the command line, etc, now it generates a single libxorg.la
from all the required convenience libraries, and links with a dummy
xorg.c (that should usually be the file with the main function...).
This removes the requirement of some things like libosandcommon and
libinit, that existed to circumvent problems when linking multiple
.a and .la in the final Xorg binary.

  The "symbol table" is now generated dynamically, by a shell script,
with an embedded gawk parser that parses cpp output. The new file
sdksyms.sh is generated by hand by analyzing all Makefile.am's and
making it create a sdksyms.c file, that includes all sdk headers that
will add symbols for the Xorg binary. Module headers aren't read, and
a in 2 files it was required to add a "<hash>ifndef XorgLoader" around
declarations shared between the Xorg binary and libextmod. A few
other changes were added to other sdk headers, like preventing
multiple inclusion, or including other headers to satisfy dependencies.

  This should be a lot more portable, and better (hopefully properly)
using libtool to generate convenience libraries.
2008-12-07 02:22:19 -02:00
Paulo Cesar Pereira de Andrade
49f77fff14 Rework symbol visibility for easier maintenance
Save in a few special cases, _X_EXPORT should not be used in C source
files. Instead, it should be used in headers, and the proper C source
include that header. Some special cases are symbols that need to be
shared between modules, but not expected to be used by external drivers,
and symbols that are accessible via LoaderSymbol/dlopen.

  This patch also adds conditionally some new sdk header files, depending
on extensions enabled. These files were added to match pattern for
other extensions/modules, that is, have the headers "deciding" symbol
visibility in the sdk. These headers are:
o Xext/panoramiXsrv.h, Xext/panoramiX.h
o fbpict.h (unconditionally)
o vidmodeproc.h
o mioverlay.h (unconditionally, used only by xaa)
o xfixes.h (unconditionally, symbols required by dri2)

  LoaderSymbol and similar functions now don't have different prototypes,
in loaderProcs.h and xf86Module.h, so that both headers can be included,
without the need of defining IN_LOADER.

  xf86NewInputDevice() device prototype readded to xf86Xinput.h, but
not exported (and with a comment about it).
2008-12-03 05:43:34 -02:00
Bernhard Rosenkraenzer
1dfed222e9 Xext: fix MultiBuffer compilation error with TryClientEvents. (#18835)
X.Org Bug 18835 <http://bugs.freedesktop.org/show_bug.cgi?id=18835>

Signed-off-by: Peter Hutterer <peter.hutterer@redhat.com>
2008-12-02 15:50:38 +10:00
Paulo Cesar Pereira de Andrade
180bad8477 Add visibility flags to XSERVER_CFLAGS.
This is done to actually change DIX_CFLAGS, as not all "modules" use
XORG_CFLAGS.
  Also export the symbols that are required by other modules after
the change.
2008-12-02 02:50:45 -02:00
Paulo Cesar Pereira de Andrade
d6cbd4511e Export symbols defined in the sdk.
This is the biggest "visibility" patch. Instead of doing a "export"
symbol on demand, export everything in the sdk, so that if some module
fails due to an unresolved symbol, it is because it is using a symbol
not in the sdk.

  Most exported symbols shouldn't really be made visible, neither
advertised in the sdk, as they are only used by a single shared object.

  Symbols in the sdk (or referenced in sdk macros), but not defined
anywhere include:
XkbBuildCoreState()
XkbInitialMap
XkbXIUnsupported
XkbCheckActionVMods()
XkbSendCompatNotify()
XkbDDXFakePointerButton()
XkbDDXApplyConfig()
_XkbStrCaseCmp()
_XkbErrMessages[]
_XkbErrCode
_XkbErrLocation
_XkbErrData
XkbAccessXDetailText()
XkbNKNDetailMaskText()
XkbLookupGroupAndLevel()
XkbInitAtoms()
XkbGetOrderedDrawables()
XkbFreeOrderedDrawables()
XkbConvertXkbComponents()
XkbWriteXKBSemantics()
XkbWriteXKBLayout()
XkbWriteXKBKeymap()
XkbWriteXKBFile()
XkbWriteCFile()
XkbWriteXKMFile()
XkbWriteToServer()
XkbMergeFile()
XkmFindTOCEntry()
XkmReadFileSection()
XkmReadFileSectionName()
InitExtInput()
xf86CheckButton()
xf86SwitchCoreDevice()
RamDacSetGamma()
RamDacRestoreDACValues()
xf86Bpp
xf86ConfigPix24
xf86MouseCflags[]
xf86SupportedMouseTypes[]
xf86NumMouseTypes
xf86ChangeBusIndex()
xf86EntityEnter()
xf86EntityLeave()
xf86WrapperInit()
xf86RingBell()
xf86findOptionBoolean()
xf86debugListOptions()
LoadSubModuleLocal()
LoaderSymbolLocal()
getInt10Rec()
xf86CurrentScreen
xf86ReallocatePciResources()
xf86NewSerialNumber()
xf86RandRSetInitialMode()
fbCompositeSolidMask_nx1xn
fbCompositeSolidMask_nx8888x0565C
fbCompositeSolidMask_nx8888x8888C
fbCompositeSolidMask_nx8x0565
fbCompositeSolidMask_nx8x0888
fbCompositeSolidMask_nx8x8888
fbCompositeSrc_0565x0565
fbCompositeSrc_8888x0565
fbCompositeSrc_8888x0888
fbCompositeSrc_8888x8888
fbCompositeSrcAdd_1000x1000
fbCompositeSrcAdd_8000x8000
fbCompositeSrcAdd_8888x8888
fbGeneration
fbIn
fbOver
fbOver24
fbOverlayGeneration
fbRasterizeEdges
fbRestoreAreas
fbSaveAreas
composeFunctions
VBEBuildVbeModeList()
VBECalcVbeModeIndex()
TIramdac3030CalculateMNPForClock()
shadowBufPtr
shadowFindBuf()
miRRGetScreenInfo()
RRSetScreenConfig()
RRModePruneUnused()
PixmanImageFromPicture()
extern int miPointerGetMotionEvents()
miClipPicture()
miRasterizeTriangle()
fbPush1toN()
fbInitializeBackingStore()
ddxBeforeReset()
SetupSprite()
InitSprite()
DGADeliverEvent()

  SPECIAL CASES
o defined as _X_INTERNAL
	xf86NewInputDevice()
o defined as static
	fbGCPrivateKey
	fbOverlayScreenPrivateKey
	fbScreenPrivateKey
	fbWinPrivateKey
o defined in libXfont.so, but declared in xorg/dixfont.h
	GetGlyphs()
	QueryGlyphExtents()
	QueryTextExtents()
	ParseGlyphCachingMode()
	InitGlyphCaching()
	SetGlyphCachingMode()
2008-11-29 23:56:06 -02:00
Eamon Walsh
ed597f19fd xselinux: use "raw context" variants of getpeercon() and getcon(). 2008-11-25 22:49:19 -05:00
Eamon Walsh
2538fc0d89 xselinux: don't pass a NULL key string to selabel_lookup(). 2008-11-25 18:28:12 -05:00
James Cloos
b3c7e62664 Remove some null statements.
Remove several doubled statement-terminal semicolons.

Reported by Fernando Carrijo.
2008-11-08 12:21:20 -05:00
Daniel Stone
f4036f6ace Remove XEvIE
It's unmaintained and has been broken for quite a while; MPX finally
smashed it completely.

Signed-off-by: Peter Hutterer <peter.hutterer@redhat.com>
2008-11-04 16:01:07 +10:30
Peter Hutterer
b6b26560d6 Move EXTENSION_BASE and EXTENSION_EVENT_BASE to misc.h. 2008-10-31 17:09:13 +10:30
Eamon Walsh
0f2fd0577f xselinux: send more specific message types to libaudit. 2008-10-30 18:29:51 -04:00
Julien Cristau
f2bda61c03 Xext: Fix compiler warnings
Make GEClientGone static and include registry.h, to fix the following
warnings:
geext.c:225: warning: no previous prototype for 'GEClientGone'
geext.c: In function 'GEExtensionInit':
geext.c:280: warning: implicit declaration of function 'RegisterResourceName'
geext.c:280: warning: nested extern declaration of 'RegisterResourceName'
2008-10-26 11:43:48 +01:00
Adam Jackson
8a5b89e8e1 xalloc+memset(0) -> xcalloc 2008-10-06 15:36:51 -04:00