public inbox for linux-media@vger.kernel.org
 help / color / mirror / Atom feed
* [RFCv1 PATCH 0/8] Allocate events per-event-type, v4l2-ctrls cleanup
@ 2011-06-14 15:22 Hans Verkuil
  2011-06-14 15:22 ` [RFCv1 PATCH 1/8] v4l2-events/fh: merge v4l2_events into v4l2_fh Hans Verkuil
  2011-06-15 17:24 ` [RFCv1 PATCH 0/8] Allocate events per-event-type, v4l2-ctrls cleanup Sakari Ailus
  0 siblings, 2 replies; 17+ messages in thread
From: Hans Verkuil @ 2011-06-14 15:22 UTC (permalink / raw)
  To: linux-media; +Cc: laurent.pinchart, sakari.ailus

This patch series consists of two parts: the first four patches change the
way events are allocated and what to do when the event queue is full.

These first four patches are the most important ones to review. The big
change is that event allocation now happens when subscribing an event.
So you not only specify which event you want to subscribe to for a particular
filehandle, but also how many events should be reserved for that event type.
Currently the driver specifies the number of events to allocate, but later
this can be something that the application might want to set manually.

This ensures that for each event type you will never entirely miss all events
of a particular type. Currently this is a real possibility.

The other change is that instead of dropping the new event if there is no more
space available, the oldest event is dropped. This ensures that you get at
least the latest state. And optionally a merge function can be provided that
merges information of two events into one. This allows the control event to
require just one event: if a new event is raised, then the new and old one
can be merged and all state is preserved. Only the intermediate steps are
no longer available. This makes for very good behavior of events and is IMHO
a requirement for using the control event in a real production environment.

The second four patches reorganize the way extended controls are processed
in the control framework. This is the first step towards allowing control
changes from within interrupt handlers. The main purpose is to move as much
code as possible out of the critical sections. This reduces the size of
those sections, making it easier to eventually switch to spinlocks for
certain kinds of controls.

It's lots of internal churn, so it's probably not easy to review. There are
no real functional changes, however.

Regards,

	Hans


^ permalink raw reply	[flat|nested] 17+ messages in thread

end of thread, other threads:[~2011-06-20 14:12 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-06-14 15:22 [RFCv1 PATCH 0/8] Allocate events per-event-type, v4l2-ctrls cleanup Hans Verkuil
2011-06-14 15:22 ` [RFCv1 PATCH 1/8] v4l2-events/fh: merge v4l2_events into v4l2_fh Hans Verkuil
2011-06-14 15:22   ` [RFCv1 PATCH 2/8] v4l2-ctrls/event: remove struct v4l2_ctrl_fh, instead use v4l2_subscribed_event Hans Verkuil
2011-06-20 13:50     ` Laurent Pinchart
2011-06-14 15:22   ` [RFCv1 PATCH 3/8] v4l2-event/ctrls/fh: allocate events per fh and per type instead of just per-fh Hans Verkuil
2011-06-14 15:22   ` [RFCv1 PATCH 4/8] v4l2-event: add optional 'merge' callback to merge two events Hans Verkuil
2011-06-20 14:09     ` Laurent Pinchart
2011-06-20 14:11       ` Hans Verkuil
2011-06-14 15:22   ` [RFCv1 PATCH 5/8] v4l2-ctrls: don't initially set CH_VALUE for write-only controls Hans Verkuil
2011-06-14 15:22   ` [RFCv1 PATCH 6/8] v4l2-ctrls: improve discovery of controls of the same cluster Hans Verkuil
2011-06-14 15:22   ` [RFCv1 PATCH 7/8] v4l2-ctrls: split try_or_set_ext_ctrls() Hans Verkuil
2011-06-14 15:22   ` [RFCv1 PATCH 8/8] v4l2-ctrls: v4l2_ctrl_handler_setup code simplification Hans Verkuil
2011-06-15  9:30   ` [RFCv1 PATCH 1/8] v4l2-events/fh: merge v4l2_events into v4l2_fh Sakari Ailus
2011-06-15 16:39     ` Hans Verkuil
2011-06-15 16:59       ` Sakari Ailus
2011-06-15 17:10         ` Hans Verkuil
2011-06-15 17:24 ` [RFCv1 PATCH 0/8] Allocate events per-event-type, v4l2-ctrls cleanup Sakari Ailus

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox