[dpdk-dev] [PATCH 2/2] net/virtio: fix lgtm static checker complaint
Maxime Coquelin
maxime.coquelin at redhat.com
Thu Mar 28 12:04:37 CET 2019
On 3/27/19 10:08 PM, Stephen Hemminger wrote:
> Since previous test is for mtu < 1519 the next else if
> is always true. This causes the lgtm static tool to complain.
> Not a real issue, just cosmetic.
>
> Signed-off-by: Stephen Hemminger <stephen at networkplumber.org>
> ---
> drivers/net/virtio/virtio_rxtx.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/net/virtio/virtio_rxtx.c b/drivers/net/virtio/virtio_rxtx.c
> index 5f6796bdba37..268fe3b8f156 100644
> --- a/drivers/net/virtio/virtio_rxtx.c
> +++ b/drivers/net/virtio/virtio_rxtx.c
> @@ -1110,7 +1110,7 @@ virtio_update_packet_stats(struct virtnet_stats *stats, struct rte_mbuf *mbuf)
> stats->size_bins[0]++;
> else if (s < 1519)
> stats->size_bins[6]++;
> - else if (s >= 1519)
> + else
> stats->size_bins[7]++;
> }
>
>
Reviewed-by: Maxime Coquelin <maxime.coquelin at redhat.com>
More information about the dev
mailing list