On Sun, Aug 22, 2021 at 01:59:00PM +0200, Lorenzo Fontana wrote:
When writing BPF programs one might refer to the man page
to lookup helpers. When you do so, however you don't have
a way to immediately know if you can use the helper
based on your program licensing requirements.
This patch adds a specific line in the man bpf-helpers
to show that information straight away.
Signed-off-by: Lorenzo Fontana <redacted>
...
quoted hunk ↗ jump to hunk
* long bpf_trace_printk(const char *fmt, u32 fmt_size, ...)
* Description
@@ -1613,6 +1621,8 @@ union bpf_attr {
* Return
* The number of bytes written to the buffer, or a negative error
* in case of failure.
+ * GPL Compatibility
+ * Required
I think manually annotating the docs is too easy to get wrong.
I think scripts/bpf_doc.py should be able to pick it up from the code somehow?
or rely on dynamic discovery by bpftool?