From: Jiri Slaby <jslaby@suse.cz>
To: crope@iki.fi
Cc: linux-kernel@vger.kernel.org, jirislaby@gmail.com,
Mauro Carvalho Chehab <mchehab@redhat.com>,
linux-media@vger.kernel.org
Subject: [PATCH 4/4] media: dvb/af9015, add hashes support
Date: Fri, 22 Jan 2010 16:10:55 +0100 [thread overview]
Message-ID: <1264173055-14787-4-git-send-email-jslaby@suse.cz> (raw)
In-Reply-To: <4B4F6BE5.2040102@iki.fi>
So as a final patch, add support for hash and one hash entry
for MSI digi vox mini II:
iManufacturer 1 Afatech
iProduct 2 DVB-T 2
iSerial 3 010101010600001
It is now handled with proper IR and key map tables.
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
Cc: Antti Palosaari <crope@iki.fi>
Cc: Mauro Carvalho Chehab <mchehab@redhat.com>
Cc: linux-media@vger.kernel.org
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
---
drivers/media/dvb/dvb-usb/af9015.c | 14 ++++++++++++--
1 files changed, 12 insertions(+), 2 deletions(-)
diff --git a/drivers/media/dvb/dvb-usb/af9015.c b/drivers/media/dvb/dvb-usb/af9015.c
index 796f9d5..650c913 100644
--- a/drivers/media/dvb/dvb-usb/af9015.c
+++ b/drivers/media/dvb/dvb-usb/af9015.c
@@ -788,6 +788,13 @@ static const struct af9015_setup af9015_setup_usbids[] = {
{ }
};
+static const struct af9015_setup af9015_setup_hashes[] = {
+ { 0xb8feb708,
+ af9015_rc_keys_msi, ARRAY_SIZE(af9015_rc_keys_msi),
+ af9015_ir_table_msi, ARRAY_SIZE(af9015_ir_table_msi) },
+ { }
+};
+
static void af9015_set_remote_config(struct usb_device *udev,
struct dvb_usb_device_properties *props)
{
@@ -800,7 +807,10 @@ static void af9015_set_remote_config(struct usb_device *udev,
} else {
u16 vendor = le16_to_cpu(udev->descriptor.idVendor);
- if (vendor == USB_VID_AFATECH) {
+ table = af9015_setup_match(af9015_config.eeprom_sum,
+ af9015_setup_hashes);
+
+ if (!table && vendor == USB_VID_AFATECH) {
/* Check USB manufacturer and product strings and try
to determine correct remote in case of chip vendor
reference IDs are used.
@@ -831,7 +841,7 @@ static void af9015_set_remote_config(struct usb_device *udev,
ARRAY_SIZE(af9015_ir_table_trekstor)
};
}
- } else
+ } else if (!table)
table = af9015_setup_match(vendor, af9015_setup_usbids);
}
--
1.6.5.7
next prev parent reply other threads:[~2010-01-22 15:11 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-01-13 20:00 [PATCH 1/1] media: dvb-usb/af9015, add IR support for digivox mini II Jiri Slaby
2010-01-14 19:09 ` Antti Palosaari
2010-01-22 15:10 ` [PATCH 1/4] media: dvb/af9015, implement eeprom hashing Jiri Slaby
2010-01-24 16:16 ` Antti Palosaari
2010-01-24 16:35 ` Jiri Slaby
2010-01-24 23:52 ` Antti Palosaari
2010-01-22 15:10 ` [PATCH 2/4] media: dvb/af9015, factor out remote setting Jiri Slaby
2010-01-24 23:53 ` Antti Palosaari
2010-01-22 15:10 ` [PATCH 3/4] media: dvb/af9015, refactor " Jiri Slaby
2010-01-24 23:54 ` Antti Palosaari
2010-01-22 15:10 ` Jiri Slaby [this message]
2010-01-24 23:55 ` [PATCH 4/4] media: dvb/af9015, add hashes support Antti Palosaari
2010-01-22 15:11 ` [PATCH 1/1] media: dvb-usb/af9015, add IR support for digivox mini II Jiri Slaby
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=1264173055-14787-4-git-send-email-jslaby@suse.cz \
--to=jslaby@suse.cz \
--cc=crope@iki.fi \
--cc=jirislaby@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®