diff options
Diffstat (limited to 'sound/firewire/tascam')
-rw-r--r-- | sound/firewire/tascam/tascam-transaction.c | 4 | ||||
-rw-r--r-- | sound/firewire/tascam/tascam.c | 5 |
2 files changed, 4 insertions, 5 deletions
diff --git a/sound/firewire/tascam/tascam-transaction.c b/sound/firewire/tascam/tascam-transaction.c index 1c9a88be55c8..d4f64ae182e7 100644 --- a/sound/firewire/tascam/tascam-transaction.c +++ b/sound/firewire/tascam/tascam-transaction.c @@ -158,7 +158,7 @@ static void handle_midi_tx(struct fw_card *card, struct fw_request *request, port = b[0] >> 4; /* TODO: support virtual MIDI ports. */ - if (port > tscm->spec->midi_capture_ports) + if (port >= tscm->spec->midi_capture_ports) goto end; /* Assume the message length. */ @@ -249,7 +249,7 @@ int snd_tscm_transaction_reregister(struct snd_tscm *tscm) /* Turn on messaging. */ reg = cpu_to_be32(0x00000001); - return snd_fw_transaction(tscm->unit, TCODE_WRITE_QUADLET_REQUEST, + err = snd_fw_transaction(tscm->unit, TCODE_WRITE_QUADLET_REQUEST, TSCM_ADDR_BASE + TSCM_OFFSET_MIDI_TX_ON, ®, sizeof(reg), 0); if (err < 0) diff --git a/sound/firewire/tascam/tascam.c b/sound/firewire/tascam/tascam.c index c6747a45795b..ee0bc1839508 100644 --- a/sound/firewire/tascam/tascam.c +++ b/sound/firewire/tascam/tascam.c @@ -40,7 +40,7 @@ static int identify_model(struct snd_tscm *tscm) { struct fw_device *fw_dev = fw_parent_device(tscm->unit); const u32 *config_rom = fw_dev->config_rom; - char model[8]; + char model[9]; unsigned int i; u8 c; @@ -73,8 +73,7 @@ static int identify_model(struct snd_tscm *tscm) strcpy(tscm->card->mixername, model); snprintf(tscm->card->longname, sizeof(tscm->card->longname), "TASCAM %s, GUID %08x%08x at %s, S%d", model, - cpu_to_be32(fw_dev->config_rom[3]), - cpu_to_be32(fw_dev->config_rom[4]), + fw_dev->config_rom[3], fw_dev->config_rom[4], dev_name(&tscm->unit->device), 100 << fw_dev->max_speed); return 0; |