Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1320904

Re: [PATCH 15/31] media: dvb-frontend invoke enable/disable_source handlers

From Mauro Carvalho Chehab <mchehab@osg.samsung.com>
Newsgroups linux.kernel
Subject Re: [PATCH 15/31] media: dvb-frontend invoke enable/disable_source handlers
Date 2016-01-28 18:40 +0100
Message-ID <qVYI2-6KM-11@gated-at.bofh.it> (permalink)
References <qO329-63K-3@gated-at.bofh.it> <qO32a-63K-9@gated-at.bofh.it> <qVX9g-5Ao-19@gated-at.bofh.it> <qVXiW-5U4-19@gated-at.bofh.it> <qVY5l-6dI-33@gated-at.bofh.it>
Organization Samsung

Show all headers | View raw


Em Thu, 28 Jan 2016 09:59:38 -0700
Shuah Khan <shuahkh@osg.samsung.com> escreveu:

> On 01/28/2016 09:07 AM, One Thousand Gnomes wrote:
> > On Thu, 28 Jan 2016 13:53:04 -0200
> > Mauro Carvalho Chehab <mchehab@osg.samsung.com> wrote:
> >   
> >> Em Wed,  6 Jan 2016 13:27:04 -0700
> >> Shuah Khan <shuahkh@osg.samsung.com> escreveu:
> >>  
> >>> Checking for tuner availability from frontend thread start
> >>> disrupts video stream. Change to check for tuner and start
> >>> pipeline from frontend open instead and stop pipeline from
> >>> frontend release.    
> >>
> >> That's wrong, as DVB can be opened on read-only mode, where
> >> it won't be changing anything.  
> 
> Correct. Please check the code. Tuner availability check is
> done when the device is opened in Write mode in the following
> conditional.
> 
>        if ((file->f_flags & O_ACCMODE) != O_RDONLY) {

OK.

Thanks!
Mauro
, I don't think POSIX allows to return an error like EBUSY
> >> on open:
> >> 	http://pubs.opengroup.org/onlinepubs/9699919799/functions/open.html  
> > 
> > It doesn't document all the errors you may return. Quite a lot of
> > kernel drivers return EBUSY when they are "single open" things.
> > 
> > POSIX documents certain cases that *must* error and what the error code
> > is. It documents certain possible failures and what their error code is.
> > Beyond that it's up to you.
> >   
> 
> Returning EBUSY clearly indicates the reason why the device
> can't be opened in this case.
> 
> thanks,
> -- Shuah
> 
> 
Thanks!
Mauro

Back to linux.kernel | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

Re: [PATCH 15/31] media: dvb-frontend invoke enable/disable_source  handlers Mauro Carvalho Chehab <mchehab@osg.samsung.com> - 2016-01-28 17:00 +0100
  Re: [PATCH 15/31] media: dvb-frontend invoke enable/disable_source  handlers One Thousand Gnomes <gnomes@lxorguk.ukuu.org.uk> - 2016-01-28 17:10 +0100
    Re: [PATCH 15/31] media: dvb-frontend invoke enable/disable_source  handlers Shuah Khan <shuahkh@osg.samsung.com> - 2016-01-28 18:00 +0100
      Re: [PATCH 15/31] media: dvb-frontend invoke enable/disable_source  handlers Mauro Carvalho Chehab <mchehab@osg.samsung.com> - 2016-01-28 18:40 +0100

csiph-web