authorgravatar for karl.bohlmark@gmail.comKarl Böhlmark <karl.bohlmark@gmail.com> 2024-01-03 11:34:10+01:00
committergravatar for noreply@github.comGitHub <noreply@github.com> 2024-01-03 12:34:10+02:00
log9a56228c2b90d94d01bb76784c77fdec5710cf0a
tree87610ddc08424b41303fed8cb80b1b6a271ed24f
parentd03649ec2f42c6b967f7113e78aa137de5384c1a
signaturebadge-question-mark Signed by PGP key 4AEE18F83AFDEB23

doc: Fix typos in bpf docs


1 files changed, 8 insertions(+), 8 deletions(-)

lib/std/os/linux/bpf.zig+8-8
...@@ -140,9 +140,9 @@ pub const F_REPLACE = 0x4;...@@ -140,9 +140,9 @@ pub const F_REPLACE = 0x4;
140pub const F_STRICT_ALIGNMENT = 0x1;140pub const F_STRICT_ALIGNMENT = 0x1;
141141
142/// If BPF_F_ANY_ALIGNMENT is used in BPF_PROF_LOAD command, the verifier will142/// If BPF_F_ANY_ALIGNMENT is used in BPF_PROF_LOAD command, the verifier will
143/// allow any alignment whatsoever. On platforms with strict alignment143/// allow any alignment whatsoever. On platforms with strict alignment
144/// requirements for loads ands stores (such as sparc and mips) the verifier144/// requirements for loads ands stores (such as sparc and mips) the verifier
145/// validates that all loads and stores provably follow this requirement. This145/// validates that all loads and stores provably follow this requirement. This
146/// flag turns that checking and enforcement off.146/// flag turns that checking and enforcement off.
147///147///
148/// It is mostly used for testing when we want to validate the context and148/// It is mostly used for testing when we want to validate the context and
...@@ -163,7 +163,7 @@ pub const F_ANY_ALIGNMENT = 0x2;...@@ -163,7 +163,7 @@ pub const F_ANY_ALIGNMENT = 0x2;
163///163///
164/// So, this flag is introduced. Once it is set, verifier will randomize high164/// So, this flag is introduced. Once it is set, verifier will randomize high
165/// 32-bit for those instructions who has been identified as safe to ignore165/// 32-bit for those instructions who has been identified as safe to ignore
166/// them. Then, if verifier is not doing correct analysis, such randomization166/// them. Then, if verifier is not doing correct analysis, such randomization
167/// will regress tests to expose bugs.167/// will regress tests to expose bugs.
168pub const F_TEST_RND_HI32 = 0x4;168pub const F_TEST_RND_HI32 = 0x4;
169169
...@@ -206,7 +206,7 @@ pub const BPF_F_NO_PREALLOC = 0x1;...@@ -206,7 +206,7 @@ pub const BPF_F_NO_PREALLOC = 0x1;
206206
207/// flag for BPF_MAP_CREATE command. Instead of having one common LRU list in207/// flag for BPF_MAP_CREATE command. Instead of having one common LRU list in
208/// the BPF_MAP_TYPE_LRU_[PERCPU_]HASH map, use a percpu LRU list which can208/// the BPF_MAP_TYPE_LRU_[PERCPU_]HASH map, use a percpu LRU list which can
209/// scale and perform better. Note, the LRU nodes (including free nodes) cannot209/// scale and perform better. Note, the LRU nodes (including free nodes) cannot
210/// be moved across different LRU lists.210/// be moved across different LRU lists.
211pub const BPF_F_NO_COMMON_LRU = 0x2;211pub const BPF_F_NO_COMMON_LRU = 0x2;
212212
...@@ -860,7 +860,7 @@ test "opcodes" {...@@ -860,7 +860,7 @@ test "opcodes" {
860}860}
861861
862pub const Cmd = enum(usize) {862pub const Cmd = enum(usize) {
863 /// Create a map and return a file descriptor that refers to the map. The863 /// Create a map and return a file descriptor that refers to the map. The
864 /// close-on-exec file descriptor flag is automatically enabled for the new864 /// close-on-exec file descriptor flag is automatically enabled for the new
865 /// file descriptor.865 /// file descriptor.
866 ///866 ///
...@@ -887,7 +887,7 @@ pub const Cmd = enum(usize) {...@@ -887,7 +887,7 @@ pub const Cmd = enum(usize) {
887 map_get_next_key,887 map_get_next_key,
888888
889 /// Verify and load an eBPF program, returning a new file descriptor889 /// Verify and load an eBPF program, returning a new file descriptor
890 /// associated with the program. The close-on-exec file descriptor flag890 /// associated with the program. The close-on-exec file descriptor flag
891 /// is automatically enabled for the new file descriptor.891 /// is automatically enabled for the new file descriptor.
892 ///892 ///
893 /// uses ProgLoadAttr893 /// uses ProgLoadAttr
...@@ -1027,9 +1027,9 @@ pub const MapType = enum(u32) {...@@ -1027,9 +1027,9 @@ pub const MapType = enum(u32) {
1027 /// memory and can be submitted with commit() or discarded with1027 /// memory and can be submitted with commit() or discarded with
1028 /// discard()1028 /// discard()
1029 ///1029 ///
1030 /// ringbuf_output() will incurr an extra memory copy, but allows to submit1030 /// ringbuf_output() will incur an extra memory copy, but allows to submit
1031 /// records of the length that's not known beforehand, and is an easy1031 /// records of the length that's not known beforehand, and is an easy
1032 /// replacement for perf_event_outptu().1032 /// replacement for perf_event_output().
1033 ///1033 ///
1034 /// ringbuf_reserve() avoids the extra memory copy but requires a known size1034 /// ringbuf_reserve() avoids the extra memory copy but requires a known size
1035 /// of memory beforehand.1035 /// of memory beforehand.