Expand description
A linter for BPF C code.
At the source code level, individual lints can be disabled with source code comments of the form
/* bpflint: disable=probe-read */
bpf_probe_read(/* ... */);
In this instance, probe-read
is the name of the lint to disable.
Entire blocks can be annotated as well:
/* bpflint: disable=probe-read */
void handler(void) {
void *dst = /* ... */
bpf_probe_read(dst, /* ... */);
}
In the above examples, none of the instances of bpf_probe_read
will be flagged.
The directive bpflint: disable=all
acts as a catch-all, disabling
reporting of all lints.
Structs§
- Lint
Match - Details about a lint match.
- Lint
Meta - Meta data about a lint.
- Point
- A position in a multi-line text document, in terms of rows and columns.
- Range
- A range of positions in a multi-line text document, both in terms of bytes and of rows and columns.
Functions§
- builtin_
lints - Retrieve the list of lints shipped with the library.
- lint
- Lint code using the default set of lints.
- report_
terminal - Report a lint match in terminal style.