Skip to content

Commit

Permalink
ALSA: 6fire: Convert byte_rev_table uses to bitrev8
Browse files Browse the repository at this point in the history
Use the inline function instead of directly indexing the array.

This allows some architectures with hardware instructions
for bit reversals to eliminate the array.

Signed-off-by: Joe Perches <[email protected]>
Signed-off-by: Takashi Iwai <[email protected]>
  • Loading branch information
JoePerches authored and tiwai committed Nov 14, 2014
1 parent 76b188c commit 9547c09
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion sound/usb/6fire/firmware.c
Original file line number Diff line number Diff line change
Expand Up @@ -316,7 +316,7 @@ static int usb6fire_fw_fpga_upload(

while (c != end) {
for (i = 0; c != end && i < FPGA_BUFSIZE; i++, c++)
buffer[i] = byte_rev_table[(u8) *c];
buffer[i] = bitrev8((u8)*c);

ret = usb6fire_fw_fpga_write(device, buffer, i);
if (ret < 0) {
Expand Down

0 comments on commit 9547c09

Please sign in to comment.