diff options
author | Torsten Schenk <torsten.schenk@zoho.com> | 2013-05-23 15:38:29 +0400 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2013-05-23 16:30:26 +0400 |
commit | d47333ddb234dbc661ab2a4fe019758bd33ba33b (patch) | |
tree | 334478ce8963b469ba41955e7bdd939777ee2455 /sound/usb | |
parent | e6135fe960bba1d1a3a6b6818839e6d8d3f21293 (diff) | |
download | linux-d47333ddb234dbc661ab2a4fe019758bd33ba33b.tar.xz |
ALSA: usb-6fire: Modify firmware version check
Check only the uppermost 16 bits instead of the whole 32 bits of
the version information. Do this because all firmware version tested
with this version information worked correctly and the strict check
causes problems for several users.
Signed-off-by: Torsten Schenk <torsten.schenk@zoho.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/usb')
-rw-r--r-- | sound/usb/6fire/firmware.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sound/usb/6fire/firmware.c b/sound/usb/6fire/firmware.c index a1d9b0792a1e..b9defcdeb7ef 100644 --- a/sound/usb/6fire/firmware.c +++ b/sound/usb/6fire/firmware.c @@ -42,8 +42,8 @@ static const u8 ep_w_max_packet_size[] = { 0x94, 0x01, 0x5c, 0x02 /* alt 3: 404 EP2 and 604 EP6 (25 fpp) */ }; -static const u8 known_fw_versions[][4] = { - { 0x03, 0x01, 0x0b, 0x00 } +static const u8 known_fw_versions[][2] = { + { 0x03, 0x01 } }; struct ihex_record { @@ -343,7 +343,7 @@ static int usb6fire_fw_check(u8 *version) int i; for (i = 0; i < ARRAY_SIZE(known_fw_versions); i++) - if (!memcmp(version, known_fw_versions + i, 4)) + if (!memcmp(version, known_fw_versions + i, 2)) return 0; snd_printk(KERN_ERR PREFIX "invalid fimware version in device: %*ph. " |