@@ -124,7 +124,7 @@ struct tcp_ao_info {
124
124
#define tcp_hash_fail (msg , family , skb , fmt , ...) \
125
125
do { \
126
126
const struct tcphdr *th = tcp_hdr(skb); \
127
- char hdr_flags[5] = {} ; \
127
+ char hdr_flags[6] ; \
128
128
char *f = hdr_flags; \
129
129
\
130
130
if (th->fin) \
@@ -133,17 +133,18 @@ do { \
133
133
*f++ = 'S'; \
134
134
if (th->rst) \
135
135
*f++ = 'R'; \
136
+ if (th->psh) \
137
+ *f++ = 'P'; \
136
138
if (th->ack) \
137
- *f++ = 'A'; \
138
- if (f != hdr_flags) \
139
- *f = ' '; \
139
+ *f++ = '.'; \
140
+ *f = 0; \
140
141
if ((family) == AF_INET) { \
141
- net_info_ratelimited("%s for ( %pI4, %d)->( %pI4, %d) %s " fmt "\n", \
142
+ net_info_ratelimited("%s for %pI4.%d-> %pI4.%d [%s] " fmt "\n", \
142
143
msg, &ip_hdr(skb)->saddr, ntohs(th->source), \
143
144
&ip_hdr(skb)->daddr, ntohs(th->dest), \
144
145
hdr_flags, ##__VA_ARGS__); \
145
146
} else { \
146
- net_info_ratelimited("%s for [%pI6c]:%u ->[%pI6c]:%u %s " fmt "\n", \
147
+ net_info_ratelimited("%s for [%pI6c].%d ->[%pI6c].%d [%s] " fmt "\n", \
147
148
msg, &ipv6_hdr(skb)->saddr, ntohs(th->source), \
148
149
&ipv6_hdr(skb)->daddr, ntohs(th->dest), \
149
150
hdr_flags, ##__VA_ARGS__); \
0 commit comments