All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mauro Carvalho Chehab <m.chehab@samsung.com>
To: "Frank Schäfer" <fschaefer.oss@googlemail.com>
Cc: linux-media@vger.kernel.org
Subject: Re: [PATCH] xc2028: disable device power-down because power state handling is broken
Date: Mon, 06 Jan 2014 11:00:04 -0200	[thread overview]
Message-ID: <20140106110004.041e4fe6@samsung.com> (raw)
In-Reply-To: <1388410678-12641-1-git-send-email-fschaefer.oss@googlemail.com>

Em Mon, 30 Dec 2013 14:37:58 +0100
Frank Schäfer <fschaefer.oss@googlemail.com> escreveu:

> xc2028 power state handling is broken.
> I2C read/write operations fail when the device is powered down at that moment,
> which causes the get_rf_strength and get_rf_strength callbacks (and probably
> others, too) to fail.
> I don't know how to fix this properly, so disable the device power-down until
> anyone comes up with a better solution.
> 
> Signed-off-by: Frank Schäfer <fschaefer.oss@googlemail.com>
> ---
>  drivers/media/tuners/tuner-xc2028.c |    4 +++-
>  1 Datei geändert, 3 Zeilen hinzugefügt(+), 1 Zeile entfernt(-)
> 
> diff --git a/drivers/media/tuners/tuner-xc2028.c b/drivers/media/tuners/tuner-xc2028.c
> index 4be5cf8..cb3dc5e 100644
> --- a/drivers/media/tuners/tuner-xc2028.c
> +++ b/drivers/media/tuners/tuner-xc2028.c
> @@ -1291,16 +1291,18 @@ static int xc2028_sleep(struct dvb_frontend *fe)
>  		dump_stack();
>  	}
>  
> +	/* FIXME: device power-up/-down handling is broken */
> +/*
>  	mutex_lock(&priv->lock);
>  
>  	if (priv->firm_version < 0x0202)
>  		rc = send_seq(priv, {0x00, XREG_POWER_DOWN, 0x00, 0x00});
>  	else
>  		rc = send_seq(priv, {0x80, XREG_POWER_DOWN, 0x00, 0x00});
> -
>  	priv->state = XC2028_SLEEP;
>  
>  	mutex_unlock(&priv->lock);
> +*/

This patch is completely broken.

First of all, there are both modprobe and config parameters that disables
the poweroff mode.

Second, it doesn't fix the bug, just hides it.

Third, it keeps the xc3028 energized, with spends power and heats the
device, with reduces its lifetime.

I'm working on a proper fix for it.

Cheers,
Mauro

  reply	other threads:[~2014-01-06 13:00 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-12-30 13:37 [PATCH] xc2028: disable device power-down because power state handling is broken Frank Schäfer
2014-01-06 13:00 ` Mauro Carvalho Chehab [this message]
2014-01-07 17:34   ` Frank Schäfer

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=20140106110004.041e4fe6@samsung.com \
    --to=m.chehab@samsung.com \
    --cc=fschaefer.oss@googlemail.com \
    --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.