Skip to content
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

Fix flow direction #341

Merged
merged 4 commits into from
Sep 5, 2024
Merged

Fix flow direction #341

merged 4 commits into from
Sep 5, 2024

Conversation

anjmao
Copy link
Collaborator

@anjmao anjmao commented Sep 4, 2024

This is regression introduced in #338
We should keep track of packet direction.

e2e/e2e.go Outdated Show resolved Hide resolved
@anjmao anjmao merged commit 924cd8a into main Sep 5, 2024
2 checks passed
@anjmao anjmao deleted the fix-flow-direction branch September 5, 2024 06:50
net_event_context_t *neteventctx = bpf_map_lookup_elem(&cgroup_skb_events_scratch_map, &zero);
if (unlikely(neteventctx == NULL))
return 0;
// TODO: We may run into stack limit issue here.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can simply use the mechanism that we introduced with selecting a scratch buffer from the scratch map. As pointed out in the original PR, since event_context_t is the first field in net_event_context_t, it should just work ™️ .

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants