[linux-dvb] [PATCH] propagating more errors

Johannes Stezenbach js at linuxtv.org
Thu Jun 16 21:41:25 CEST 2005

On Wed, Jun 15, 2005 at 04:00:06AM +0200, Wolfgang Rohdewald wrote:
> this patch propagates more errors back to the caller.
> Questions:
> - av7110_set_vidmode: If av7110_fw_cmd(...COMTPYE_PIDFILTER...) fails
>   should the previous av7110_fw_cmd calls be reverted and how?
> - same question for dvb_feed_{start,stop}_pid and av7110_fe_lock_fix

No. Either the ioctl fails with ERESTARTSYS and the whole thing
is retried, or it fails due to some other error and it's up to
userspace to handle that. av7110_fe_lock_fix() is different
because it may be called by the dvb_frontend_thread(), but there's
nothing we can do if it fails.

> - play_video_cb() should not call get_video_format because that can
>   return -ERESTARTSYS, and play_video_cb cannot handle that. How to fix that?

Ignore. Someone interrupted write(), userspace decides if it wants to
retry it (assuming userspace sees the error).

> - dvb_get_stc: is that fix correct? Something has to be done, because now return -EIO
>   could mask a -ERESTARTSYS

is OK

> - init_av7110_av and setup_rc_config also ignore the return code of av7110_fw_cmd.
>   I am not sure how this should be fixed.

just log an error

> @@ -172,6 +173,7 @@ int av7110_av_start_play(struct av7110 *
>  	if (av7110->playing & av)
>  		return -EBUSY;
> +	// what does this do, do we have to ignore the result of av7110_fw_cmd?
>  	av7110_fw_cmd(av7110, COMTYPE_REC_PLAY, __Stop, 0);

good question, I hope you'll work it out with Werner

Could you please send an updated patch?


More information about the linux-dvb mailing list