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

collector: ct: fix truncation of zone id #487

Merged
merged 1 commit into from
Jan 30, 2025
Merged

Conversation

igsilya
Copy link
Contributor

@igsilya igsilya commented Jan 30, 2025

Zone id is 16-bit, but for some reason is casted to u8 on read. This makes retis report incorrect values.

Fixes: e883af8 ("module: add conntrack module")

Zone id is 16-bit, but for some reason is casted to u8 on read.
This makes retis report incorrect values.

Fixes: e883af8 ("module: add conntrack module")
Signed-off-by: Ilya Maximets <[email protected]>
@vlrpl vlrpl added the run-functional-tests Request functional tests to be run by CI label Jan 30, 2025
@vlrpl
Copy link
Contributor

vlrpl commented Jan 30, 2025

Thanks, @igsilya for spotting this, for the fix, and for the test.
Also, the patch lgtm.
There's a problem with (apparently) a previous PR on C8S (ovs tests are not run there).
I'll quickly double-check and be back on this.

@vlrpl
Copy link
Contributor

vlrpl commented Jan 30, 2025

It seems vlan_all is missing in older kernels (c8s [0]) and BPF_CORE_READ() is not enough.
Didn't dig into it, but this should be protected with bpf_core_field_exists() and emit this relo type BPF_FIELD_EXISTS.
@andreaskaris, if you have spare cycles, are you interested in giving it a stab?

[0] https://cirrus-ci.com/task/5509164367085568

Edit: Nevermind. You already did in #482, thanks!

Copy link
Contributor

@vlrpl vlrpl left a comment

Choose a reason for hiding this comment

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

the patch lgtm, thanks!

@vlrpl vlrpl merged commit 1abdd15 into retis-org:main Jan 30, 2025
14 of 15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
run-functional-tests Request functional tests to be run by CI
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants