Ask HN: How to handle kernel struct changes (e.g. iov_ITER) in eBPF?
morolis
·
2026-06-20
·
via HN's home page
|
|
| | Ask HN: How to handle kernel struct changes (e.g. iov_ITER) in eBPF? | | 1 point by morolis 1 minute ago | hide | past | favorite | discuss | | I used the kernel vmlinux header file(6.10 version) from pwru to compile, but my actual kernel version was 6.6. the iov field name in iov_iter become an internal anonymous structure __iov file on kernel changing(6.10->6.6), so the led to that if I extracted and compiled according to the field name of version 6.10, I could not run in my current system, and vice versa. I would like to ask what is a more formal or official solution to deal with this change in kernel structure? My current solution is to directly customize two different versions of iov anonymous structures to judge whether two ways to obtain iov are compatible through bpf_core_field_exists. | |
| help |
|

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact |
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。