summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2010-01-04CloseDevice: call XkbRemoveResourceClient before freeing key class structHEADmasterAlan Coopersmith1-3/+3
XkbRemoveResourceClient() returns immediately if dev->key is NULL. CloseDevice calls XkbRemoveResourceClient until it removes all resources. If we free dev->key and NULL it before XkbRemoveResourceClient, then infinite loop ensues, and the server appears to hang on exit or crash. Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com> Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net> Reviewed-by: Daniel Stone <daniel@fooishbar.org> Signed-off-by: Keith Packard <keithp@keithp.com>
2010-01-04EXA: Restore migration call in exaDoPutImage().Michel Dänzer1-0/+11
Turns out this is still necessary if the driver PrepareAccess hook succeeds. Signed-off-by: Michel Dänzer <daenzer@vmware.com> Tested-by: Maarten Maathuis <madman2003@gmail.com> Tested-by: Andrew Chant <andrew.chant+debian@gmail.com> Signed-off-by: Keith Packard <keithp@keithp.com>
2010-01-01Add Xephyr.man to .gitignoreMikhail Gusarov1-0/+1
Signed-off-by: Mikhail Gusarov <dottedmag@dottedmag.net> Reviewed-by: Gaetan Nadon <memsize@videotron.ca> Signed-off-by: Keith Packard <keithp@keithp.com>
2010-01-01Remove unused pShadow field from drivers' private structuresMikhail Gusarov3-3/+0
Signed-off-by: Mikhail Gusarov <dottedmag@dottedmag.net> Signed-off-by: Keith Packard <keithp@keithp.com>
2010-01-01Do not check xfree argument for NULLMikhail Gusarov11-98/+57
xfree itself checks for NULL, and even this is not necessary as passing NULL to free(3) is safe. Signed-off-by: Mikhail Gusarov <dottedmag@dottedmag.net> Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net> Signed-off-by: Keith Packard <keithp@keithp.com>
2010-01-01Remove trailing whitespaceMikhail Gusarov20-411/+411
Signed-off-by: Mikhail Gusarov <dottedmag@dottedmag.net> Signed-off-by: Keith Packard <keithp@keithp.com>
2010-01-01dix: add smooth limited pointer acceleration profileSimon Thum2-2/+29
This profile is inspired by the accel code removed from the wacom driver. It ascends from zero to acceleration, maxing out at threshold. This means you can control the slope using threshold, which wasn't possible in wacom. For sanity's sake, threshold should grow with acceleration. Works best with adaptive deceleration, since otherwise it only generates acceleration above 1, causing seldom pixel skips. Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net> Signed-off-by: Keith Packard <keithp@keithp.com>
2009-12-30config: add libudev input-hotplug backendJulien Cristau11-81/+415
Add a backend using libudev for input hotplug, and disable the hal and dbus backends if this one is enabled. XKB configuration happens using xkb{rules,model,layout,variant,options} properties (case-insensitive) on the device. We fill in InputAttributes to allow configuration through InputClass in Xorg. Requires udev 148 for the input_id helper and ID_INPUT* properties. Signed-off-by: Julien Cristau <jcristau@debian.org> Acked-by: Dan Nicholson <dbn.lists@gmail.com> Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
2009-12-30xfree86: move sanity checks below option and input classes merges.Peter Hutterer1-10/+11
While the identifier is likely set before the input classes are merged, the driver may not be. Hence don't check for a driver before we've completed configuration for this device. Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net> Reviewed-by: Dan Nicholson <dbn.lists@gmail.com> Signed-off-by: Julien Cristau <jcristau@debian.org>
2009-12-30Merge remote branch 'dbn/inputclass'Keith Packard22-33/+567
2009-12-30Merge remote branch 'dbn/xorg.conf.d'Keith Packard17-179/+583
2009-12-29EXA: Don't use UTS/DFS directly for Put/GetImage when there's a system copy.Michel Dänzer1-34/+8
We want to save the result in the system memory copy, in case we'll need it again for subsequent software fallbacks. Signed-off-by: Michel Dänzer <daenzer@vmware.com> Acked-By: Maarten Maathuis <madman2003@gmail.com> Signed-off-by: Keith Packard <keithp@keithp.com>
2009-12-29EXA: Restrict the regions that need to be migrated for composite fallback ↵Thomas Hellstrom2-41/+200
for src / mask pictures. [ Michel: Minor fixups to address compiler warnings ] Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com> Signed-off-by: Michel Dänzer <daenzer@vmware.com> Acked-by: Maarten Maathuis <madman2003@gmail.com> Signed-off-by: Keith Packard <keithp@keithp.com>
2009-12-29EXA/mixed: Handle results of software fallbacks in DamageReport hook.Michel Dänzer4-39/+29
This is more elegant and probably also slightly more correct than doing it at FinishAccess time. Signed-off-by: Michel Dänzer <daenzer@vmware.com> Acked-by: Maarten Maathuis <madman2003@gmail.com> Signed-off-by: Keith Packard <keithp@keithp.com>
2009-12-29EXA: Fix migration avoidance for 1x1 pixmaps.Michel Dänzer2-1/+21
Signed-off-by: Michel Dänzer <daenzer@vmware.com> Acked-by: Maarten Maathuis <madman2003@gmail.com> Signed-off-by: Keith Packard <keithp@keithp.com>
2009-12-29EXA/classic: Fix crash with migration heuristic "smart".Michel Dänzer1-0/+3
Signed-off-by: Michel Dänzer <daenzer@vmware.com> Acked-by: Maarten Maathuis <madman2003@gmail.com> Signed-off-by: Keith Packard <keithp@keithp.com>
2009-12-29EXA: Limit src prepareAccess regions for a number of unaccelerated operations.Thomas Hellstrom1-27/+75
When we can trivially calculate the affected source regions, do that before calling region bounded prepareAccess. [ Michel: Minor fixups to address compiler warnings ] Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com> Signed-off-by: Michel Dänzer <daenzer@vmware.com> Acked-by: Maarten Maathuis <madman2003@gmail.com> Signed-off-by: Keith Packard <keithp@keithp.com>
2009-12-29EXA: Use relevant source region to minimize migration on CopyWindow fallbacks.Michel Dänzer1-2/+12
Signed-off-by: Michel Dänzer <daenzer@vmware.com> Acked-by: Maarten Maathuis <madman2003@gmail.com> Signed-off-by: Keith Packard <keithp@keithp.com>
2009-12-29EXA: Fix bugs in exaGetImage / ExaCheckGetImage migration.Thomas Hellstrom2-2/+2
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com> Acked-by: Michel Dänzer <michel@daenzer.net> Acked-by: Maarten Maathuis <madman2003@gmail.com> Signed-off-by: Keith Packard <keithp@keithp.com>
2009-12-28EXA: Allow optimized migration to be enabled with mixed pixmaps.Michel Dänzer1-18/+19
This was always the intention, I only recently realized it wasn't the case yet... Signed-off-by: Michel Dänzer <daenzer@vmware.com> Acked-by: Maarten Maathuis <madman2003@gmail.com> Signed-off-by: Keith Packard <keithp@keithp.com>
2009-12-28EXA/mixed: Don't clear deferred status of pixmaps if migration is limited.Michel Dänzer1-1/+2
* With optimized migration, only the pending damage region is synchronized for destination pixmaps. * Migration of source pixmaps can be limited to a bounding region. Signed-off-by: Michel Dänzer <daenzer@vmware.com> Acked-by: Maarten Maathuis <madman2003@gmail.com> Signed-off-by: Keith Packard <keithp@keithp.com>
2009-12-23xfree86: Introduce InputClass configurationDan Nicholson11-2/+472
Currently Xorg uses hal's fdi files to decide what configuration options are applied to automatically added input devices. This is sub-optimal since it requires users to use a new and different configuration store than xorg.conf. The InputClass section attempts to provide a system similar to hal where configuration can be applied to all devices with certain attributes. For now, devices can be matched to: * A substring of the product name via a MatchProduct entry * A substring of the vendir name via a MatchVendor entry * A pathname pattern of the device file via a MatchDevicePath entry * A device type via boolean entries for MatchIsKeyboard, MatchIsPointer, MatchIsJoystick, MatchIsTablet, MatchIsTouchpad and MatchIsTouchscreen See the INPUTCLASS section in xorg.conf(5) for more details. Signed-off-by: Dan Nicholson <dbn.lists@gmail.com> Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
2009-12-22config: Introduce InputAttributes in NewInputDeviceRequestDan Nicholson9-8/+52
In order to give NewInputDeviceRequest more information, a new InputAttributes type is introduced. Currently, this collects the product and vendor name, device path, and sets booleans for attributes such as having keys and/or a pointer. Only the HAL backend fills in the attributes, though. Signed-off-by: Dan Nicholson <dbn.lists@gmail.com> Reviewed-by: Peter Hutterer <peter.hutterer at who-t.net>
2009-12-22xfree86: Support non-Option boolean entries in configurationDan Nicholson4-23/+43
Refactored code into the parser to allow the freeform boolean types used in Option entries to be used in other configuration entries. This isn't as powerful as allowing "No" to precede the option names, but it atleast gives a common handling of "yes", "no", etc. A type xf86TriState has been added to support an optional boolean. This allows the boolean sense of the value to be kept while providing a means to signal that it is unset. Signed-off-by: Dan Nicholson <dbn.lists@gmail.com> Reviewed-by: Peter Hutterer <peter.hutterer at who-t.net>
2009-12-22xfree86: Add Option AutoServerLayout for input devices.Peter Hutterer4-53/+129
Any input device with this option will be automatically added to whichever server layout is selected at startup. This removes the need to reference a device from the ServerLayout section. The two following configuration are identical: CONFIG 1: Section "ServerLayout" InputDevice "foo" EndSection Section "InputDevice" Identifier "foo" ... EndSection CONFIG 2: Section "InputDevice" Identifier "foo" Option "AutoServerLayout" "on" ... EndSection The selection of the server layout affects both explicitly specified layouts and the implicit layout. Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net> Reviewed-by: Keith Packard <keithp at keithp.com>
2009-12-22xfree86: Allow config directory to be specified on command lineDan Nicholson10-28/+142
Add a new command line parameter, -configdir, to specify the config directory to be used. Rules are the same as -config for root vs. user privileges. Signed-off-by: Dan Nicholson <dbn.lists@gmail.com> Reviewed-by: Peter Hutterer <peter.hutterer at who-t.net>
2009-12-22xfree86: Use xorg.conf.d directory for multiple config filesDan Nicholson9-107/+321
Currently there is a single file, xorg.conf, for configuring the server. This works fine most of the time, but it becomes a problem when packages or system services need to adjust the configuration. Instead, allow multiple configuration files to live in a directory. Typically this will be /etc/X11/xorg.conf.d. Files with a suffix of .conf will be read and added to the server configuration after xorg.conf. The server won't fall back to using the auto configuration unless there is no config file and there are no files in the config directory. Right now this uses a simpler search template than the config file search path by not using the command line or environment variable parameters. The matching code was refactored a bit to make this more coherent. Any DDX wanting to read the config files will need to call xf86initConfigFiles before opening/reading them. This is to allow xf86openConfigFile without xf86openConfigDirFiles and vice-versa. Signed-off-by: Dan Nicholson <dbn.lists@gmail.com> Reviewed-by: Peter Hutterer <peter.hutterer at who-t.net>
2009-12-22xfree86: Unexport configuration file symbolsDan Nicholson1-7/+7
These functions should not be used outside of DDXs, so no need to put them in the ABI. Signed-off-by: Dan Nicholson <dbn.lists@gmail.com> Reviewed-by: Peter Hutterer <peter.hutterer at who-t.net>
2009-12-22test/xi2: fail if xi2 class type is garbage. (#25492)Peter Hutterer1-0/+3
If the keycode range exceeds the allowable length, memory gets overwritten. Catch this case by making sure that only allowed class types are present. X.Org Bug 25492 <http://bugs.freedesktop.org/show_bug.cgi?id=25492> Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net> Reviewed-by: Dave Airlie <airlied@redhat.com> Signed-off-by: Keith Packard <keithp@keithp.com>
2009-12-22xfree86: remove LAYOUT_DEBUG section.Peter Hutterer1-39/+0
I don't think this one has been in use since 2003. Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net> Reviewed-by: Dave Airlie <airlied@redhat.com> Signed-off-by: Keith Packard <keithp@keithp.com>
2009-12-22xfree86: remove some 'enable this later' and if 0 ifdefsPeter Hutterer2-28/+0
2003 called, they want their ifdefs back. Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net> Reviewed-by: Dave Airlie <airlied@redhat.com> Signed-off-by: Keith Packard <keithp@keithp.com>
2009-12-22Merge remote branch 'whot/master'Keith Packard3-62/+48
2009-12-23test/xi2: fix maximum max_keycode (bug#25492)Julien Cristau1-1/+1
The number of keycodes needs to be lower than 0xFFFD so that the length field of xXIKeyInfo doesn't overflow. Signed-off-by: Julien Cristau <jcristau@debian.org> Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2009-12-22xfree86: remove HistorySize from the xorg.conf man page.Peter Hutterer1-4/+0
This option isn't parsed by anything anymore. Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net> Reviewed-by: Keith Packard <keithp@keithp.com>
2009-12-22xfree86: reword InputDevice man sections, deprecate CorePointer/CoreKeyboardPeter Hutterer1-42/+39
Reshuffle and reword - InputDevice sections are only necessary if hotplugging is disabled. Put more emphasis on hotplugging and less on HAL since we'll switch backends eventually. CorePointer, CoreKeyboard, and AlwaysCore should be listed as deprecated since they don't do what they used to since 1.4. These days, only SendCoreEvents matters and it's enabled for any driver calling xf86ProcessCommonOptions (== every driver). It only controls the startup behavior too, so document this. Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net> Acked-by: Keith Packard <keithp@keithp.com> Reviewed-by: Alan Coopersmith <alan.coopersmith@sun.com>
2009-12-19Bump to 1.7.99.3 (unreleased)Keith Packard1-2/+2
Signed-off-by: Keith Packard <keithp@keithp.com>
2009-12-18Set release date for 1.7.99.2Keith Packard1-1/+1
Signed-off-by: Keith Packard <keithp@keithp.com>
2009-12-18Add type name argument to CreateNewResourceTypeAlan Coopersmith40-221/+128
Convert all calls of CreateNewResourceType to pass name argument Breaks DIX ABI. ABI versions bumped: Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com> Reviewed-by: Keith Packard <keithp@keithp.com> Signed-off-by: Keith Packard <keithp@keithp.com>
2009-12-18Ensure all resource types created have names registeredAlan Coopersmith30-4/+122
Calls RegisterResourceName to record the type name for use by X-Resource, XACE/SELinux/XTsol, and DTrace. Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com> Reviewed-by: Keith Packard <keithp@keithp.com>
2009-12-18Check for failures from CreateNewResourceTypeAlan Coopersmith15-17/+58
Make sure to check return value before setting bitmask flags. For most calls, just fails to init the extension. Since Xinput already calls FatalError() on initialization failure, so does failure to allocate Xinput's resource type. Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com> Reviewed-by: Keith Packard <keithp@keithp.com>
2009-12-18Change default xkb model from pc104 to pc105Alan Coopersmith1-2/+2
PC105 is a more useful default for non-American keyboard users, not harmful for American PC101/PC104 keyboard users. Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com> Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net> Signed-off-by: Keith Packard <keithp@keithp.com>
2009-12-18Change sysconfdir brackets to avoid some shells trying to run it as a commandAlan Coopersmith1-1/+1
Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com> Reviewed-by: Dan Nicholson <dbn.lists@gmail.com> Signed-off-by: Keith Packard <keithp@keithp.com>
2009-12-18Add platform compatibility defines for Sun Studio compilersAlan Coopersmith1-0/+14
Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com> Signed-off-by: Keith Packard <keithp@keithp.com>
2009-12-18Convert checks for PC98 support from platform #ifdefs to configure flagAlan Coopersmith6-17/+26
Default remains the same - on for most OS'es on i386 (except Solaris), off for everyone else. Can be manually toggled via --enable-pc98 or --disable-pc98. Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com> Signed-off-by: Keith Packard <keithp@keithp.com>
2009-12-18xfree86: update man page for special keys handling.Peter Hutterer1-11/+5
SpecialKeyHandling was removed from the kbd driver with version 1.4.0. Since this is the only version that will build against server 1.7+ it's not reasonable to mention it in the man page. Reword, point to XKB instead and make clear that some key combinations _may_ not be available in any given config. Reported-by: Derek Fawcus Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net> Reviewed-by: Alan Coopersmith <alan.coopersmith@sun.com>
2009-12-18xfree86: DontZap has been disabled for a while now, say so in the man page.Peter Hutterer1-4/+3
1.7 always shipped with DontZap disabled, it's just the default keymaps that may not include the symbol to trigger it. Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net> Reviewed-by: Alan Coopersmith <alan.coopersmith@sun.com>
2009-12-16Merge remote branch 'alanc/master'Keith Packard33-657/+492
2009-12-16Merge remote branch 'jeremyhu/master'Keith Packard2-2/+2
2009-12-16xf86xv: Fix off-by-one in viewport clippingVille Syrjälä1-6/+6
Most of the Xv Put/Get operations have an off by one error in the viewport clipping. Apparently PutImage was fixed at some point but the same code was already copy-pasted all over the place, and so the other operations still suffer from the bug. Signed-off-by: Ville Syrjälä <ville.syrjala@nokia.com> Reviewed-by: Tiago Vignatti <tiago.vignatti@nokia.com> Signed-off-by: Keith Packard <keithp@keithp.com>
2009-12-16xfree86: belately init RandR12 if xinerama fails. (#24627)Peter Hutterer1-1/+6
On Fri, Dec 11, 2009 at 10:19:01AM -0800, Keith Packard wrote: > On Wed, 9 Dec 2009 11:55:14 +1000, Peter Hutterer <peter.hutterer@who-t.net> wrote: > > On Tue, Dec 08, 2009 at 05:24:06PM -0800, Aaron Plattner wrote: > > > On Tue, Dec 08, 2009 at 03:52:27PM -0800, Peter Hutterer wrote: > > > > Xorg +xinerama crashes immediately due to whacky dependency between Xinerama > > > > and RandR12. The latter doesn't initialize if Xinerama is enabled, but if > > > > only one screen is found, Xinerama is disabled again and RandR12 tries to > > > > access data it never initialized. > > I'd sure like to have RandR get enabled when xinerama doesn't; is there > an easy way of making that happen here? Perhaps having the RandR12 code > disable Xinerama when only one screen is found? Or some other kludge? you know the dependency better than I do so any hints are apreciated. afaict, the screenInfo.numScreens (the check used by Xinerama) isn't necessarily initialized at this point so we can't use the same check. The following seems to work though: From 670b3ebdb7312a6433a8f093d0820785db2aea20 Mon Sep 17 00:00:00 2001 From: Peter Hutterer <peter.hutterer@who-t.net> Date: Mon, 14 Dec 2009 11:00:58 +1000 Subject: [PATCH] xfree86: if only one screen was found, disable Xinerama (#24627) Xorg +xinerama crashes immediately due to whacky dependency between Xinerama and RandR12. The latter doesn't initialize if Xinerama is enabled, but if only one screen is found, Xinerama is disabled again and RandR12 tries to access data it never initialized. Dependency chain is: - ProcessCommandLine sets noPanoramiXExtension to FALSE - xf86RandR12Init() is a noop - PanoramiXExtensionInit sets noPanoramiXExtension to TRUE - xf86RandR12CreateScreenResources tries to use the devPrivates key it never initialized. This hack checks if there's only one screen at the time RandR12 is initialized. If so, we expect Xinerama to fail anyhow so we disable it ourselves and proceed as planned. X.Org Bug 24627 <http://bugs.freedesktop.org/show_bug.cgi?id=24627> Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net> Signed-off-by: Keith Packard <keithp@keithp.com>