events in evdev.c

Chuck Robey chuckr at
Wed Sep 17 17:38:09 PDT 2008

I don't know if this is important or not, and I won't harp on this, but I've
heard before that an attempt is made both to keep evdev.c very current, AND to
have it not have anything in it that is Linux-only.  In evdev.c, in a lot of
places, there's a use of a "struct input_event".  Seeing as only Linux has their
events, well, it's Linux-only code.  I've been reading a lot, because I need to
get the keyboard-handling code out of evdev.c (so I can originate keyboard
events, supporting my tablet's function keys) but I can't find any definition
anywhere of what a struct input_event is.

I finally found it defined on a Linux documentation site, where it shows up in
input.h.  Certainly there isn't such an animal in FreeBSD ... FreeBSD's concept
of events are intra-kernel, not exported things like they seem to be for Linux.

I don't want to harangue you folks over this, I have to see if I can extract
that thing from the code, but I thought I would drop this as a possible useful
hint.  I need to see why, when I originate keyboard events, the xserver crashes
on my (it seems to like all the rest of my events just fine).  All the docs I've
seen so far, they all talk about keyboard code from the application viewpoint,
from getting events, not generating them.

OK, all done.

More information about the xorg mailing list