From: Jemma Denson <jdenson@gmail.com>
To: Antti Palosaari <crope@iki.fi>, linux-media@vger.kernel.org
Subject: Re: [PATCH 1/8] m88ds3103: do not return error from get_frontend() when not ready
Date: Mon, 18 May 2015 09:36:42 +0100 [thread overview]
Message-ID: <5559A49A.2030105@gmail.com> (raw)
In-Reply-To: <1431925731-7499-1-git-send-email-crope@iki.fi>
Hi Antti,
On 18/05/15 06:08, Antti Palosaari wrote:
> Do not return error from get_frontend() when status is queried, but
> device is not ready. dvbv5-zap has habit to call that IOCTL before
> device is tuned and it also refuses to use DVBv5 statistic after
> that...
In the driver I'm working on I noticed that in dvb5-zap too. I also saw
a timing issue if holding fe_status in the priv struct - fe_status will
remain at FE_HAS_LOCK until read_status() spins around again and this
can cause get_frontend to proceed when it probably shouldn't. The end
result is this early call to get_frontend() overwrites the property
cache before zap has sent it through to set_frontend() and tuning then
fails.
Do we need to be fixing these issues at a driver level?
Jemma.
>
> Signed-off-by: Antti Palosaari <crope@iki.fi>
> ---
> drivers/media/dvb-frontends/m88ds3103.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/media/dvb-frontends/m88ds3103.c b/drivers/media/dvb-frontends/m88ds3103.c
> index d3d928e..03dceb5 100644
> --- a/drivers/media/dvb-frontends/m88ds3103.c
> +++ b/drivers/media/dvb-frontends/m88ds3103.c
> @@ -742,7 +742,7 @@ static int m88ds3103_get_frontend(struct dvb_frontend *fe)
> dev_dbg(&priv->i2c->dev, "%s:\n", __func__);
>
> if (!priv->warm || !(priv->fe_status & FE_HAS_LOCK)) {
> - ret = -EAGAIN;
> + ret = 0;
> goto err;
> }
>
prev parent reply other threads:[~2015-05-18 8:36 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-05-18 5:08 [PATCH 1/8] m88ds3103: do not return error from get_frontend() when not ready Antti Palosaari
2015-05-18 5:08 ` [PATCH 2/8] m88ds3103: implement DVBv5 CNR statistics Antti Palosaari
2015-05-18 5:08 ` [PATCH 3/8] m88ds3103: wrap legacy DVBv3 SNR to DVBv5 CNR Antti Palosaari
2015-05-18 5:08 ` [PATCH 4/8] m88ds3103: implement DVBv5 BER Antti Palosaari
2015-05-18 5:08 ` [PATCH 5/8] m88ds3103: wrap legacy DVBv3 BER to " Antti Palosaari
2015-05-18 5:08 ` [PATCH 6/8] m88ds3103: use jiffies when polling DiSEqC TX ready Antti Palosaari
2015-05-18 5:08 ` [PATCH 7/8] m88ds3103: add I2C client binding Antti Palosaari
2015-05-18 5:08 ` [PATCH 8/8] m88ds3103: wrap media attach to driver I2C probe Antti Palosaari
2015-05-18 8:36 ` Jemma Denson [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5559A49A.2030105@gmail.com \
--to=jdenson@gmail.com \
--cc=crope@iki.fi \
--cc=linux-media@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.