events in evdev.c

Chuck Robey chuckr at telenix.org
Fri Sep 19 12:59:36 PDT 2008


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Adam Jackson wrote:
> On Thu, 2008-09-18 at 09:24 -0700, Alan Coopersmith wrote:
>> Chuck Robey wrote:
>>> Sorry, I can't parse what you wrote.  You don't know where I heard that Xorg is
>>> Linux-only?  Is that what you said?  My understanding *had been* that Xorg was
>>> trying to be compatible with as many Unixes as possible, and specifically avoid
>>> being Linux only, which is why seeing the depth of Linuxcode that is in your
>>> flagship input driver, evdev, surprised me so.  I uderstood, from Peter's mail,
>>> that I'm wrong there, and the use of Linux-only ocde in that flagship driver was
>>> deliberate.  Simply really surprised me, that's all.
>> Xorg is not Linux-only, but evdev is.   On Solaris & BSD, Xorg uses the
>> xf86-input-keyboard & xf86-input-mouse drivers instead.
> 
> Both Solaris and BSD have very similar event APIs, afaik, and could
> easily have drivers for same.  But they don't.  Patches gratefully etc.
> 
> - ajax

I'm really rather curious where you got the idea that FreeBSD had something that
looked even vaguely like the Linux events.  I know that if you look at the
FreeBSD man page EVENTHANDLER(9) you can see an event interface, but that one is
intra-kernel, not exported to applications like the Linux one is.  Using the
event interface, like evdev does, takes away the portability.

If I could find a FreeBSD applications-event interface ala Linux, I would be
overjoyed, and immediately use it.

The xf86_input_joystick interface is a way better example for how to write a
driver than the evdev is (unless you're using Linux), because it compatibly
brings in 3 different interfaces types, /including/ evdev.  If it were me,
that's the one I'd give newbies, not evdev.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.9 (FreeBSD)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkjUBKgACgkQz62J6PPcoOkIzQCglxtdK6clIGMc8Ui1hXwhm1IR
NocAn01KFXPda+CN23fx6DZXDf3YfbHX
=jfyu
-----END PGP SIGNATURE-----



More information about the xorg mailing list