Centos-kernel-stream-9/Documentation/bpf
Artem Savkov 3b8fa9106d bpf, docs: Define signed modulo as using truncated division
JIRA: https://issues.redhat.com/browse/RHEL-23643

commit 0e133a13370389d3894891eafe54fec2c44ad735
Author: Dave Thaler <dthaler@microsoft.com>
Date:   Tue Oct 17 20:30:20 2023 +0000

    bpf, docs: Define signed modulo as using truncated division
    
    There's different mathematical definitions (truncated, floored, rounded,
    etc.) and different languages have chosen different definitions [0][1].
    E.g., languages/libraries that follow Knuth use a different mathematical
    definition than C uses. This patch specifies which definition BPF uses,
    as verified by Eduard [2] and others.
    
      [0] https://en.wikipedia.org/wiki/Modulo#Variants_of_the_definition
      [1] https://torstencurdt.com/tech/posts/modulo-of-negative-numbers/
      [2] https://lore.kernel.org/bpf/57e6fefadaf3b2995bb259fa8e711c7220ce5290.camel@gmail.com/
    
    Signed-off-by: Dave Thaler <dthaler@microsoft.com>
    Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
    Acked-by: David Vernet <void@manifault.com>
    Acked-by: Eduard Zingerman <eddyz87@gmail.com>
    Link: https://lore.kernel.org/bpf/20231017203020.1500-1-dthaler1968@googlemail.com

Signed-off-by: Artem Savkov <asavkov@redhat.com>
2024-03-27 10:27:54 +01:00
..
libbpf bpf, docs: Libbpf overview documentation 2023-09-22 09:12:18 +02:00
standardization bpf, docs: Define signed modulo as using truncated division 2024-03-27 10:27:54 +01:00
bpf_design_QA.rst docs/bpf: Add documentation for new instructions 2023-12-15 09:28:55 +01:00
bpf_devel_QA.rst bpf: Replace deprecated -target with --target= for Clang 2023-12-14 15:22:22 +01:00
bpf_iterators.rst bpf, docs: BPF Iterator Document 2023-09-22 09:12:37 +02:00
bpf_licensing.rst bpf: Document BPF licensing. 2022-06-03 17:23:54 +03:00
bpf_prog_run.rst Documentation/bpf: Add documentation for BPF_PROG_RUN 2022-10-25 14:57:58 +02:00
btf.rst docs/bpf: Fix "file doesn't exist" warnings in {llvm_reloc,btf}.rst 2023-12-15 09:29:03 +01:00
clang-notes.rst bpf, docs: Explain helper functions 2023-09-22 09:12:16 +02:00
classic_vs_extended.rst bpf, docs: Split the comparism to classic BPF from instruction-set.rst 2022-08-24 12:53:51 +02:00
cpumasks.rst bpf/docs: Update documentation for new cpumask kfuncs 2023-10-26 17:06:19 +02:00
drgn.rst
faq.rst bpf, docs: Fix ordering of bpf documentation 2022-08-24 12:53:38 +02:00
graph_ds_impl.rst Documentation: bpf: Add missing line break separator in node_data struct code block 2023-06-13 22:45:32 +02:00
helpers.rst bpf, docs: Fix ordering of bpf documentation 2022-08-24 12:53:38 +02:00
index.rst bpf, docs: Move linux-notes.rst to root bpf docs tree 2023-12-15 09:29:02 +01:00
kfuncs.rst bpf: Allow NULL buffers in bpf_dynptr_slice(_rw) 2023-10-12 11:40:58 +02:00
linux-notes.rst bpf, docs: Move linux-notes.rst to root bpf docs tree 2023-12-15 09:29:02 +01:00
llvm_reloc.rst docs/bpf: Fix "file doesn't exist" warnings in {llvm_reloc,btf}.rst 2023-12-15 09:29:03 +01:00
map_array.rst docs/bpf: Fix sphinx warnings in BPF map docs 2023-04-28 11:43:11 +02:00
map_bloom_filter.rst docs/bpf: Document BPF_MAP_TYPE_BLOOM_FILTER 2023-04-28 11:43:10 +02:00
map_cgroup_storage.rst Remove duplicate words inside documentation 2023-04-28 11:43:21 +02:00
map_cgrp_storage.rst docs/bpf: Add documentation for new cgroup local storage 2023-04-28 11:42:59 +02:00
map_cpumap.rst docs/bpf: Fix sphinx warnings for cpumap 2023-04-28 11:43:10 +02:00
map_devmap.rst docs/bpf: Fix sphinx warnings for devmap 2023-04-28 11:43:10 +02:00
map_hash.rst docs/bpf: Add LRU internals description and graph 2023-10-12 11:40:54 +02:00
map_lpm_trie.rst docs/bpf: Fix sphinx warnings in BPF map docs 2023-04-28 11:43:11 +02:00
map_lru_hash_update.dot docs/bpf: Add LRU internals description and graph 2023-10-12 11:40:54 +02:00
map_of_maps.rst docs/bpf: Fix sphinx warnings in BPF map docs 2023-04-28 11:43:11 +02:00
map_queue_stack.rst docs/bpf: Fix sphinx warnings in BPF map docs 2023-04-28 11:43:11 +02:00
map_sk_storage.rst docs/bpf: Reword docs for BPF_MAP_TYPE_SK_STORAGE 2023-04-28 11:43:18 +02:00
map_sockmap.rst docs: BPF_MAP_TYPE_SOCK[MAP|HASH] 2023-06-13 22:44:24 +02:00
map_xskmap.rst Documentation: bpf: correct spelling 2023-06-13 22:44:55 +02:00
maps.rst bpf, docs: Fix final bpf docs build failure 2023-09-22 09:12:09 +02:00
other.rst bpf, documentation: Add graph documentation for non-owning refs 2023-06-13 22:45:31 +02:00
prog_cgroup_sockopt.rst bpf: Document EFAULT changes for sockopt 2023-10-12 11:41:04 +02:00
prog_cgroup_sysctl.rst
prog_flow_dissector.rst docs/bpf: update out-of-date doc in BPF flow dissector 2023-12-15 09:29:04 +01:00
prog_lsm.rst bpf, docs: Rename bpf_lsm.rst to prog_lsm.rst 2022-08-24 12:53:38 +02:00
prog_sk_lookup.rst bpf: sk_lookup: Add user documentation 2020-08-24 14:46:50 -07:00
programs.rst docs/bpf: Add table of BPF program types to libbpf docs 2023-04-28 11:43:11 +02:00
redirect.rst bpf, docs: DEVMAPs and XDP_REDIRECT 2023-04-28 11:43:08 +02:00
ringbuf.rst Documentation: bpf: correct spelling 2023-06-13 22:44:55 +02:00
s390.rst
syscall_api.rst bpf, docs: Fix ordering of bpf documentation 2022-08-24 12:53:38 +02:00
test_debug.rst bpf, docs: Fix ordering of bpf documentation 2022-08-24 12:53:38 +02:00
verifier.rst docs/bpf: Add description of register liveness tracking algorithm 2023-06-13 22:45:21 +02:00