-
Notifications
You must be signed in to change notification settings - Fork 2.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
bpf: gate egressgw datapath on separate defines #27189
Conversation
429ff49
to
25b714e
Compare
/test |
Needs a rebase on top of #26952 since that already moves the code to a separate file. |
25b714e
to
f5428dd
Compare
/test |
f5428dd
to
12342bc
Compare
/test |
Add a new define ENABLE_EGRESS_GATEWAY_COMMON which enables the common egress gateway code. The existing ENABLE_EGRESS_GATEWAY flag now controls whether to check for egress gateway policies with static gateway IPs. This makes it easier to extend the codebase to with alternative implementations. Signed-off-by: Lorenz Bauer <lmb@isovalent.com>
12342bc
to
f957feb
Compare
/test |
1 similar comment
/test |
Move the CT reply check into egress_gw_request_needs_redirect so that alternative implementations can have their own CT state handling. Signed-off-by: Lorenz Bauer <lmb@isovalent.com>
b3db2e3
to
b32476d
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! just a non blocking nit
@@ -1065,7 +1065,7 @@ static __always_inline int handle_ipv4_from_lxc(struct __ctx_buff *ctx, __u32 *d | |||
} | |||
} | |||
|
|||
#ifdef ENABLE_EGRESS_GATEWAY | |||
#ifdef ENABLE_EGRESS_GATEWAY_COMMON |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: let's just switch all of them to #if defined()
?
#define ENABLE_EGRESS_GATEWAY_COMMON | ||
#endif | ||
|
||
#ifdef ENABLE_EGRESS_GATEWAY_COMMON |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ditto
/test |
bpf: gate egressgw datapath on separate defines
bpf: move CT checks into egress_gw_request_needs_redirect