* Re: ALSA: firewire-lib: pass the number of data blocks in incoming packets to outgoing packets
@ 2015-05-26 8:49 Dan Carpenter
2015-05-26 14:46 ` Takashi Sakamoto
0 siblings, 1 reply; 2+ messages in thread
From: Dan Carpenter @ 2015-05-26 8:49 UTC (permalink / raw)
To: o-takashi; +Cc: alsa-devel
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
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: ALSA: firewire-lib: pass the number of data blocks in incoming packets to outgoing packets
2015-05-26 8:49 ALSA: firewire-lib: pass the number of data blocks in incoming packets to outgoing packets Dan Carpenter
@ 2015-05-26 14:46 ` Takashi Sakamoto
0 siblings, 0 replies; 2+ messages in thread
From: Takashi Sakamoto @ 2015-05-26 14:46 UTC (permalink / raw)
To: Dan Carpenter; +Cc: alsa-devel
Hi Dan,
On May 26 2015 17:49, Dan Carpenter wrote:
> 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
Exactly. And this is a cause of my system hangup. Under compiler
optimization, the condition statement is removed and error handling is
not executed...
Thanks for your indication!
Takashi Sakamoto
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2015-05-26 14:46 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-05-26 8:49 ALSA: firewire-lib: pass the number of data blocks in incoming packets to outgoing packets Dan Carpenter
2015-05-26 14:46 ` Takashi Sakamoto
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.