From: Jean Delvare <khali@linux-fr.org>
To: LMML <linux-media@vger.kernel.org>
Subject: [PATCH 1/2] V4L/DVB: cx88: Move I2C IR initialization
Date: Mon, 28 Jun 2010 17:55:43 +0200 [thread overview]
Message-ID: <20100628175543.3996cc2d@hyperion.delvare> (raw)
Move I2C IR initialization from just after I2C bus setup to right
before non-I2C IR initialization. This is the same as was done for
the bttv driver several months ago. Might solve bugs which have not yet
been reported for some cards. It makes both drivers consistent, and
makes it easier to disable IR support (coming soon.)
Signed-off-by: Jean Delvare <khali@linux-fr.org>
---
drivers/media/video/cx88/cx88-cards.c | 1 +
drivers/media/video/cx88/cx88-i2c.c | 6 +++++-
drivers/media/video/cx88/cx88.h | 1 +
3 files changed, 7 insertions(+), 1 deletion(-)
--- linux-2.6.34-rc3.orig/drivers/media/video/cx88/cx88-cards.c 2010-04-09 10:55:01.000000000 +0200
+++ linux-2.6.34-rc3/drivers/media/video/cx88/cx88-cards.c 2010-04-09 17:53:58.000000000 +0200
@@ -3498,6 +3498,7 @@ struct cx88_core *cx88_core_create(struc
}
cx88_card_setup(core);
+ cx88_i2c_init_ir(core);
cx88_ir_init(core, pci);
return core;
--- linux-2.6.34-rc3.orig/drivers/media/video/cx88/cx88-i2c.c 2010-04-09 14:04:04.000000000 +0200
+++ linux-2.6.34-rc3/drivers/media/video/cx88/cx88-i2c.c 2010-04-09 17:53:58.000000000 +0200
@@ -181,6 +181,11 @@ int cx88_i2c_init(struct cx88_core *core
} else
printk("%s: i2c register FAILED\n", core->name);
+ return core->i2c_rc;
+}
+
+void cx88_i2c_init_ir(struct cx88_core *core)
+{
/* Instantiate the IR receiver device, if present */
if (0 == core->i2c_rc) {
struct i2c_board_info info;
@@ -196,7 +201,6 @@ int cx88_i2c_init(struct cx88_core *core
i2c_new_probed_device(&core->i2c_adap, &info, addr_list,
i2c_probe_func_quick_read);
}
- return core->i2c_rc;
}
/* ----------------------------------------------------------------------- */
--- linux-2.6.34-rc3.orig/drivers/media/video/cx88/cx88.h 2010-04-03 18:40:32.000000000 +0200
+++ linux-2.6.34-rc3/drivers/media/video/cx88/cx88.h 2010-04-09 17:53:58.000000000 +0200
@@ -636,6 +636,7 @@ extern struct videobuf_queue_ops cx8800_
/* cx88-i2c.c */
extern int cx88_i2c_init(struct cx88_core *core, struct pci_dev *pci);
+extern void cx88_i2c_init_ir(struct cx88_core *core);
/* ----------------------------------------------------------- */
--
Jean Delvare
reply other threads:[~2010-06-28 15:55 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=20100628175543.3996cc2d@hyperion.delvare \
--to=khali@linux-fr.org \
--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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox