From: Jean Delvare <khali@linux-fr.org>
To: LMML <linux-media@vger.kernel.org>
Subject: [PATCH 2/2] V4L/DVB: cx88: Let the user disable IR support
Date: Mon, 28 Jun 2010 17:59:49 +0200 [thread overview]
Message-ID: <20100628175949.293d1673@hyperion.delvare> (raw)
It might be useful to be able to disable the IR support, either for
debugging purposes, or just for users who know they won't use the IR
remote control anyway. On many cards, IR support requires expensive
polling/sampling which is better avoided if never needed.
Signed-off-by: Jean Delvare <khali@linux-fr.org>
---
drivers/media/video/cx88/cx88-cards.c | 10 ++++++++--
1 file changed, 8 insertions(+), 2 deletions(-)
--- linux-2.6.34-rc3.orig/drivers/media/video/cx88/cx88-cards.c 2010-04-09 17:53:58.000000000 +0200
+++ linux-2.6.34-rc3/drivers/media/video/cx88/cx88-cards.c 2010-04-09 17:54:14.000000000 +0200
@@ -45,6 +45,10 @@ static unsigned int latency = UNSET;
module_param(latency,int,0444);
MODULE_PARM_DESC(latency,"pci latency timer");
+static int disable_ir;
+module_param(disable_ir, int, 0444);
+MODULE_PARM_DESC(latency, "Disable IR support");
+
#define info_printk(core, fmt, arg...) \
printk(KERN_INFO "%s: " fmt, core->name , ## arg)
@@ -3498,8 +3502,10 @@ struct cx88_core *cx88_core_create(struc
}
cx88_card_setup(core);
- cx88_i2c_init_ir(core);
- cx88_ir_init(core, pci);
+ if (!disable_ir) {
+ cx88_i2c_init_ir(core);
+ cx88_ir_init(core, pci);
+ }
return core;
}
--
Jean Delvare
reply other threads:[~2010-06-28 15:59 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=20100628175949.293d1673@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