Hi, On Wed, Oct 07, 2009 at 06:19:10PM -0700, Ping wrote: > On Wed, Oct 7, 2009 at 5:02 PM, Peter Hutterer > <[email protected]>wrote: > > http://cvs.fedoraproject.org/viewvc/rpms/linuxwacom/devel/linuxwacom-0.8.2.2-HAL.patch?revision=1.1&view=markup > > not for the faint of heart. > > > > when cleaning up you have to make sure you're only cleaning up those > > devices > > that you've initialized yourself, otherwise you're going to top the server. > > i'm not sure if I can recommend the above at all, mjg59's HAL trickery was > > a > > lot nicer but then again, udev. > > Then, my question is: can we assume, with xserver 1.8 and later, > xf86WcmInit (the device initialization routine) will only be called by your > libudev input-hotplug mechanism? Or in another phase: do you still allow > users to define input devices through xorg.conf? > > If xf86-input-wacom will only be Init'ed by libudev input-hotplug, I can > "fix" my driver by creating all devices inside the Init. Then the driver > will cleanup itself in UnInit. I think I like this approach if you guys are > willing to take the risk of Wacom blowing up the server :).
I'd like to finally fix up our device API so these kinds of hacks are no longer necessary, but to be honest I'd suspect this may end up creeping into 1.9 rather than 1.8. NewInputDeviceRequest is completely fine to call from your driver: don't be scared by all the failure messages you'd find about it. :) Just construct a reasonable set of options lists (including 'Driver "wacom"'), and you should be fine. I don't think xorg.conf will ever die, but yes, you can safely do this by checking the option named '_source'. If it's server/hal or server/libudev (I think -- you'd have to check Julien's patch to make fully sure), then you're being called from either hal or udev. If not, then it's almost certainly xorg.conf. Cheers, Daniel
pgpOH8dwqznuY.pgp
Description: PGP signature
_______________________________________________ xorg-devel mailing list [email protected] http://lists.x.org/mailman/listinfo/xorg-devel
