From 1b70485f135a39d5f2d8c392a16817456fa3a5cd Mon Sep 17 00:00:00 2001 From: Clemens Ladisch Date: Sun, 4 Sep 2011 22:17:38 +0200 Subject: ALSA: firewire: extend snd_fw_transaction() Add a flag to snd_fw_transaction() to allow it to abort when a bus reset happens. This removes most of the duplicated error handling loops that were required around calls to the low-level fw_run_transaction(). Also add a flag to suppress error messages; errors are expected when we attempt to clean up after the device was unplugged. Signed-off-by: Clemens Ladisch --- sound/firewire/speakers.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'sound/firewire/speakers.c') diff --git a/sound/firewire/speakers.c b/sound/firewire/speakers.c index 6a68caf1d04f..eb3f7dce1d6c 100644 --- a/sound/firewire/speakers.c +++ b/sound/firewire/speakers.c @@ -647,7 +647,7 @@ static u32 fwspk_read_firmware_version(struct fw_unit *unit) int err; err = snd_fw_transaction(unit, TCODE_READ_QUADLET_REQUEST, - OXFORD_FIRMWARE_ID_ADDRESS, &data, 4); + OXFORD_FIRMWARE_ID_ADDRESS, &data, 4, 0); return err >= 0 ? be32_to_cpu(data) : 0; } -- cgit v1.2.3