From 27764726a8fa72a7e8a7cdccbe9e4425747a96fa Mon Sep 17 00:00:00 2001 From: Mike Isely Date: Sat, 7 Mar 2009 01:57:25 -0300 Subject: V4L/DVB (11194): pvrusb2: Implement mechanism to force a full sub-device update When a pvrusb2 driver instance first initializes, we need to be sure to send out a complete state update for everything to all attached modules. The old i2c layer did this by keeping a separate mask of "stale" bits for each attached module - and setting that mask to all stale when that module attaches. But the new sub-device adaptation I've implemented here no longer has per-module stale bits. So instead there's now a global "force dirty" bit that is set upon instance initialization, before the sub-devices are attached. After the first update, this bit is cleared, allowing for normal update-on-dirty behavior. In this manner, we ensure that all sub-devices have been properly synchronized at initialization. Signed-off-by: Mike Isely Signed-off-by: Mauro Carvalho Chehab --- drivers/media/video/pvrusb2/pvrusb2-audio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'drivers/media/video/pvrusb2/pvrusb2-audio.c') diff --git a/drivers/media/video/pvrusb2/pvrusb2-audio.c b/drivers/media/video/pvrusb2/pvrusb2-audio.c index 52966414327..aca6b1d1561 100644 --- a/drivers/media/video/pvrusb2/pvrusb2-audio.c +++ b/drivers/media/video/pvrusb2/pvrusb2-audio.c @@ -184,7 +184,7 @@ int pvr2_i2c_msp3400_setup(struct pvr2_hdw *hdw,struct pvr2_i2c_client *cp) void pvr2_msp3400_subdev_update(struct pvr2_hdw *hdw, struct v4l2_subdev *sd) { - if (hdw->input_dirty) { + if (hdw->input_dirty || hdw->force_dirty) { struct v4l2_routing route; const struct routing_scheme *sp; unsigned int sid = hdw->hdw_desc->signal_routing_scheme; -- cgit v1.2.3-70-g09d2