All of lore.kernel.org
 help / color / mirror / Atom feed
From: Devin Heitmueller <dheitmueller@kernellabs.com>
To: Linux Media Mailing List <linux-media@vger.kernel.org>
Cc: Mauro Carvalho Chehab <mchehab@redhat.com>,
	Gerd Hoffmann <kraxel@redhat.com>
Subject: [PATCH] cx231xx: Fix power ramping issue
Date: Sun, 24 Jul 2011 14:44:43 -0400	[thread overview]
Message-ID: <CAGoCfix0L_POhtmVi8qstEcQ5xNCb+dpP0zoQjCaL9LUmFZ10A@mail.gmail.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 203 bytes --]

Attached is a patch which addresses the issue discussed by Mauro and
Gerd for the "-32" errors seen with the Hauppauge USBLive 2.

Devin

-- 
Devin J. Heitmueller - Kernel Labs
http://www.kernellabs.com

[-- Attachment #2: cx231xx_config_hz.patch --]
[-- Type: text/x-patch, Size: 1453 bytes --]

cx231xx: Fix power ramp time to be consistent regardless of CONFIG_HZ

From: Devin Heitmueller <dheitmueller@kernellabs.com>

On platforms that have CONFIG_HZ set to 100, the power ramp time effectively
ends up being 10ms.  However, on those that have a higher CONFIG_HZ, the time
ends up *actually* being 5ms, which doesn't allow enough time for the hardware
to be fully powered up before attempting to address it via i2c.

Change the constant to 10ms, which is long enough for the hardware to power
up, and won't really be anymore time than it was previously on platforms
with CONFIG_HZ being 100.

Credit goes to Mauro Carvalho Chehab and Gerd Hoffmann who previously
investigated this issue.

Tested with the Hauppauge USBLive 2, with which the problem was readily
reproducible after setting CONFIG_HZ to 1000.

Signed-off-by: Devin Heitmueller <dheitmueller@kernellabs.com>
Cc: Mauro Carvalho Chehab <mchehab@redhat.com>
Cc: Gerd Hoffmann <kraxel@redhat.com>

diff --git a/drivers/media/video/cx231xx/cx231xx.h b/drivers/media/video/cx231xx/cx231xx.h
index b39b85e..472d169 100644
--- a/drivers/media/video/cx231xx/cx231xx.h
+++ b/drivers/media/video/cx231xx/cx231xx.h
@@ -43,7 +43,7 @@
 #include "cx231xx-conf-reg.h"
 
 #define DRIVER_NAME                     "cx231xx"
-#define PWR_SLEEP_INTERVAL              5
+#define PWR_SLEEP_INTERVAL              10
 
 /* I2C addresses for control block in Cx231xx */
 #define     AFE_DEVICE_ADDRESS		0x60

                 reply	other threads:[~2011-07-24 18:44 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=CAGoCfix0L_POhtmVi8qstEcQ5xNCb+dpP0zoQjCaL9LUmFZ10A@mail.gmail.com \
    --to=dheitmueller@kernellabs.com \
    --cc=kraxel@redhat.com \
    --cc=linux-media@vger.kernel.org \
    --cc=mchehab@redhat.com \
    /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.