X-Git-Url: https://git.karo-electronics.de/?a=blobdiff_plain;f=sound%2Ffirewire%2Flib.c;h=14eb414983720fcc629bb55ae962c43be97e8205;hb=8ee78c6fb982b3a7343faf561e7937d4cfa955ff;hp=4750cea2210ee457634779e45e20267127319d53;hpb=24c6d02fe8c34bc958aa4c464efc1cc10d43e29d;p=karo-tx-linux.git diff --git a/sound/firewire/lib.c b/sound/firewire/lib.c index 4750cea2210e..14eb41498372 100644 --- a/sound/firewire/lib.c +++ b/sound/firewire/lib.c @@ -13,32 +13,6 @@ #define ERROR_RETRY_DELAY_MS 5 -/** - * rcode_string - convert a firewire result code to a string - * @rcode: the result - */ -const char *rcode_string(unsigned int rcode) -{ - static const char *const names[] = { - [RCODE_COMPLETE] = "complete", - [RCODE_CONFLICT_ERROR] = "conflict error", - [RCODE_DATA_ERROR] = "data error", - [RCODE_TYPE_ERROR] = "type error", - [RCODE_ADDRESS_ERROR] = "address error", - [RCODE_SEND_ERROR] = "send error", - [RCODE_CANCELLED] = "cancelled", - [RCODE_BUSY] = "busy", - [RCODE_GENERATION] = "generation", - [RCODE_NO_ACK] = "no ack", - }; - - if (rcode < ARRAY_SIZE(names) && names[rcode]) - return names[rcode]; - else - return "unknown"; -} -EXPORT_SYMBOL(rcode_string); - /** * snd_fw_transaction - send a request and wait for its completion * @unit: the driver's unit on the target device @@ -71,7 +45,7 @@ int snd_fw_transaction(struct fw_unit *unit, int tcode, if (rcode_is_permanent_error(rcode) || ++tries >= 3) { dev_err(&unit->device, "transaction failed: %s\n", - rcode_string(rcode)); + fw_rcode_string(rcode)); return -EIO; }