From: Vijay Subramanian <redacted>
Date: Tue, 20 Dec 2011 12:02:52 -0800
I assume you are talking about collision with userspace. These
definitions are already protected by #ifdef __KERNEL__.
That should be enough to protect against collisions with userspace I think.
Within the kernel he means, please put a TCP_* prefix onto these
values.
quoted
quoted
- tcp_opt->sack_ok = (options >> 4) & 0x1;
+ tcp_opt->sack_ok = (options >> 4) & SACK_SEEN;
Looks to me like that 0x1 isn't SAC_SEEK! So this is now misleading.
Can you please elaborate? Are you saying this is wrong or that it
could be done better?
I think he's saying it could be done better. Probably something
like:
tcp_opt->sack_ok = (options & (1 << 4)) ? SACK_SEEN : 0;