ext Laurent Pinchart wrote:
Hi Roger,
On Wednesday 03 March 2010 10:02:16 Roger Quadros wrote:
Hi,
What is the best mechanism to signal an event from gadget driver to user
space?
1) Use POLLPRI when we get the event. User space can then issue an IOCTL to
get the event.
2) Use uevent to send the event to user space
3) Use a separate device file dedicated for the events
Which of the 3 is a good approach. Is there a better way than these
supported by Linux?
I guess the answer depends on the use case. For V4L2, Sakari Ailus recently
posted patches to add an events API based on POLLPRI/ioctls. You can find them
on the linux-media mailing list.
Hi Laurent,
Thanks for the info.
POLLPRI/IOCTL looks to be good for our use case. I was wondering if this is a
good/legal use of POLL or not.
It blends well with poll() and select(). For select it comes as an exception.
regards,
-roger
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html