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

Bpf export #443

Merged
merged 3 commits into from
Jan 23, 2024
Merged

Bpf export #443

merged 3 commits into from
Jan 23, 2024

Conversation

shankarseal
Copy link
Contributor

This fixes #400 by adding a export tool for XDP program information.

xdp.sln Show resolved Hide resolved
@shankarseal
Copy link
Contributor Author

@mtfriesen - is there a test needed for the export program? I have integrated it into the build process itself in bpf.vcxproj. I have also made it part of the MSI. Maybe that is not needed. Instead this tool should be in the nuget package. Is there anything else you would want me to change?

int exit_code = 0;

if (argc == 2 && !_strcmpi("--clear", argv[1])) {
for (uint32_t i = 0; i < sizeof(EbpfXdpSectionInfo) / sizeof(EbpfXdpSectionInfo[0]); i++) {
Copy link
Contributor

Choose a reason for hiding this comment

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

RTL_NUMBER_OF

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I blame it on the Copilot :P

@mtfriesen
Copy link
Contributor

@mtfriesen - is there a test needed for the export program? I have integrated it into the build process itself in bpf.vcxproj. I have also made it part of the MSI. Maybe that is not needed. Instead this tool should be in the nuget package. Is there anything else you would want me to change?

Integrating into the MSI should be sufficient. Ideally we would test the --clear parameter renders XDP programs unloadable and unverifiable, but it's not essential IMO.

@shankarseal shankarseal marked this pull request as ready for review January 23, 2024 01:59
@shankarseal shankarseal requested a review from a team as a code owner January 23, 2024 01:59
@mtfriesen mtfriesen merged commit f026933 into main Jan 23, 2024
45 checks passed
@mtfriesen mtfriesen deleted the bpf_export branch January 23, 2024 15:30
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.

XDP eBPF extension must export program information.
2 participants