summaryrefslogtreecommitdiff
path: root/linux/drivers/media
diff options
context:
space:
mode:
authorHans Verkuil <hverkuil@xs4all.nl>2006-11-12 13:28:46 +0100
committerHans Verkuil <hverkuil@xs4all.nl>2006-11-12 13:28:46 +0100
commitafda8f6dfa6cef5fc7014cdeb6a1749905d5194e (patch)
treec76e469eafaa370f355b5ba617b991b21223dddd /linux/drivers/media
parentb13643285e0e18e972d16cd49ab402b9ee99cd94 (diff)
downloadmediapointer-dvb-s2-afda8f6dfa6cef5fc7014cdeb6a1749905d5194e.tar.gz
mediapointer-dvb-s2-afda8f6dfa6cef5fc7014cdeb6a1749905d5194e.tar.bz2
Detect presence of IR receiver/IR transmitter in tveeprom
From: Hans Verkuil <hverkuil@xs4all.nl> Thanks to input from Steven Toth from Hauppauge the tveeprom module has been extended to detect the presence of an IR transmitter (aka IR-blaster). Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Diffstat (limited to 'linux/drivers/media')
-rw-r--r--linux/drivers/media/video/tveeprom.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/linux/drivers/media/video/tveeprom.c b/linux/drivers/media/video/tveeprom.c
index f963cee12..c53e64a7a 100644
--- a/linux/drivers/media/video/tveeprom.c
+++ b/linux/drivers/media/video/tveeprom.c
@@ -434,7 +434,7 @@ void tveeprom_hauppauge_analog(struct i2c_client *c, struct tveeprom *tvee,
tvee->has_radio = eeprom_data[i+len-1];
/* old style tag, don't know how to detect
IR presence, mark as unknown. */
- tvee->has_ir = 2;
+ tvee->has_ir = -1;
tvee->model =
eeprom_data[i+8] +
(eeprom_data[i+9] << 8);
@@ -657,13 +657,14 @@ void tveeprom_hauppauge_analog(struct i2c_client *c, struct tveeprom *tvee,
STRM(decoderIC, tvee->decoder_processor),
tvee->decoder_processor);
}
- if (tvee->has_ir == 2)
+ if (tvee->has_ir == -1)
tveeprom_info("has %sradio\n",
tvee->has_radio ? "" : "no ");
else
- tveeprom_info("has %sradio, has %sIR remote\n",
+ tveeprom_info("has %sradio, has %sIR receiver, has %sIR transmitter\n",
tvee->has_radio ? "" : "no ",
- tvee->has_ir ? "" : "no ");
+ (tvee->has_ir & 1) ? "" : "no ",
+ (tvee->has_ir & 2) ? "" : "no ");
}
EXPORT_SYMBOL(tveeprom_hauppauge_analog);