Gavrilov Ilia d6878d39b6 net: pktgen: Fix interface flags printing
commit 1d30162f35c7a73fc2f8cdcdcdbd690bedb99d1a upstream.

Device flags are displayed incorrectly:
1) The comparison (i == F_FLOW_SEQ) is always false, because F_FLOW_SEQ
is equal to (1 << FLOW_SEQ_SHIFT) == 2048, and the maximum value
of the 'i' variable is (NR_PKT_FLAG - 1) == 17. It should be compared
with FLOW_SEQ_SHIFT.

2) Similarly to the F_IPSEC flag.

3) Also add spaces to the print end of the string literal "spi:%u"
to prevent the output from merging with the flag that follows.

Found by InfoTeCS on behalf of Linux Verification Center
(linuxtesting.org) with SVACE.

Fixes: 99c6d3d20d62 ("pktgen: Remove brute-force printing of flags")
Signed-off-by: Gavrilov Ilia <Ilia.Gavrilov@infotecs.ru>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-10-25 11:53:22 +02:00
..
2023-06-09 10:28:59 +02:00
2022-04-20 09:19:40 +02:00
2023-10-10 21:46:37 +02:00
2023-07-27 08:37:40 +02:00
2023-10-25 11:53:19 +02:00
2023-06-21 15:44:10 +02:00
2023-01-18 11:41:09 +01:00
2023-09-23 10:59:43 +02:00
2023-05-17 11:35:59 +02:00
2023-07-27 08:37:23 +02:00
2023-10-25 11:53:21 +02:00
2021-06-18 09:59:00 +02:00
2023-06-21 15:44:10 +02:00
2023-06-21 15:44:10 +02:00