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

Updating to support newer versions of DPDK #728

Open
AndrewAlston opened this issue Apr 29, 2021 · 2 comments
Open

Updating to support newer versions of DPDK #728

AndrewAlston opened this issue Apr 29, 2021 · 2 comments

Comments

@AndrewAlston
Copy link

I've been working with nff-go to make it function correctly with dpdk-20.11.1 (which is critical for support of e810 cards and certain functions in them) - but I've run into an issue and potentially being a little stupid.

in low.go - there is a reference in setMbufLen to mb.anon5[0] -> mb.anon5[7] - and for the life of me I cannot seem to figure out how this maps back to MBuf structure in dpdk itself - since that anon struct member doesn't seem to exist in any version of dpdk that I've checked all the way back to 18 - what I do know is - this kicks out entirely on the later versions of dpdk saying that struct member doesn't exist. Anyone got any idea how this maps back so I can modify accordingly?

@maheperera
Copy link

I'm working on the same task of bumping nff-go to use dpdk v20.11 (and hopefully even newer versions eventually).
From looking at the struct definition for rte_mbuf (https://doc.dpdk.org/api-19.08/rte__mbuf_8h_source.html#l00534), I believe anon5 refers to the (5+1)th anonymous union defined.
I can't find an explicit mention of this convention in the cgo docs but it seems to match with the fact that referencing anon6 breaks compilation (there are only 6 anon unions defined in v19.08), and also by anon3 breaking when upgrading to v20.11 (where there are only 3 unions defined - https://doc.dpdk.org/api-20.11/rte__mbuf__core_8h_source.html#l00474).
Luckily the union in question didn't change other than becoming the 3rd in the struct, so I believe we can just change mb.anon5 to mb.anon2.
I'm still resolving some other compilation issues but will post here if this works out.

@XAhad32
Copy link

XAhad32 commented Sep 19, 2023

any updates?

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

No branches or pull requests

3 participants