On 12/17/19 7:34 AM, Philippe Mathieu-Daudé wrote: > GCC9 is confused by this comment when building with CFLAG > -Wimplicit-fallthrough=2: > > hw/net/imx_fec.c: In function ‘imx_eth_write’: > hw/net/imx_fec.c:906:12: error: this statement may fall through > [-Werror=implicit-fallthrough=] > 906 | if (unlikely(single_tx_ring)) { > | ^ > hw/net/imx_fec.c:912:5: note: here > 912 | case ENET_TDAR: /* FALLTHROUGH */ > | ^~~~ > cc1: all warnings being treated as errors > > Rewrite the comments in the correct place, using 'fall through' > which is recognized by GCC and static analyzers. > > Signed-off-by: Philippe Mathieu-Daudé <phi...@redhat.com> > --- > Cc: Peter Chubb <peter.ch...@nicta.com.au> > Cc: Peter Maydell <peter.mayd...@linaro.org> > Cc: Jason Wang <jasow...@redhat.com> > Cc: qemu-...@nongnu.org > --- > hw/net/imx_fec.c | 8 +++++--- > 1 file changed, 5 insertions(+), 3 deletions(-)
Reviewed-by: Richard Henderson <richard.hender...@linaro.org> r~