[alsa-devel] ALSA: firewire-lib: pass the number of data blocks in incoming packets to outgoing packets

Dan Carpenter dan.carpenter at oracle.com
Tue May 26 10:49:24 CEST 2015


Hello Takashi Sakamoto,

The patch 6fc6b9ce41c6: "ALSA: firewire-lib: pass the number of data
blocks in incoming packets to outgoing packets" from May 22, 2015,
leads to the following static checker warning:

	sound/firewire/amdtp.c:857 in_stream_callback()
	warn: unsigned 'data_blocks' is never less than zero.

sound/firewire/amdtp.c
   855  
   856                  data_blocks = handle_in_packet(s, payload_quadlets, buffer);
   857                  if (data_blocks < 0) {
                            ^^^^^^^^^^^^^^^
Never true.  But handle_in_packet() does return negative error codes.

   858                          s->packet_index = -1;
   859                          break;
   860                  }
   861  

regards,
dan carpenter


More information about the Alsa-devel mailing list