[v2,06/18] bpf: fix spelling in comments

Message ID 20210913161025.10490-7-stephen@networkplumber.org (mailing list archive)
State Superseded, archived
Delegated to: Thomas Monjalon
Headers
Series fix spelling errors |

Checks

Context Check Description
ci/checkpatch success coding style OK

Commit Message

Stephen Hemminger Sept. 13, 2021, 4:10 p.m. UTC
  Found by running codespell on the bpf implementation.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
---
 lib/bpf/bpf_jit_x86.c  | 2 +-
 lib/bpf/bpf_load_elf.c | 2 +-
 lib/bpf/bpf_pkt.c      | 2 +-
 lib/bpf/bpf_validate.c | 8 ++++----
 4 files changed, 7 insertions(+), 7 deletions(-)
  

Comments

Ananyev, Konstantin Oct. 7, 2021, 12:20 p.m. UTC | #1
> 
> Found by running codespell on the bpf implementation.
> 
> Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
> ---

Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>

> --
> 2.30.2
  

Patch

diff --git a/lib/bpf/bpf_jit_x86.c b/lib/bpf/bpf_jit_x86.c
index aa22ea78a01d..518513376a67 100644
--- a/lib/bpf/bpf_jit_x86.c
+++ b/lib/bpf/bpf_jit_x86.c
@@ -1245,7 +1245,7 @@  emit_epilog(struct bpf_jit_state *st)
 	uint32_t i;
 	int32_t spil, ofs;
 
-	/* if we allready have an epilog generate a jump to it */
+	/* if we already have an epilog generate a jump to it */
 	if (st->exit.num++ != 0) {
 		emit_abs_jmp(st, st->exit.off);
 		return;
diff --git a/lib/bpf/bpf_load_elf.c b/lib/bpf/bpf_load_elf.c
index 2b11adeb5eb1..02a5d8ba0d07 100644
--- a/lib/bpf/bpf_load_elf.c
+++ b/lib/bpf/bpf_load_elf.c
@@ -80,7 +80,7 @@  resolve_xsym(const char *sn, size_t ofs, struct ebpf_insn *ins, size_t ins_sz,
 	if (type == RTE_BPF_XTYPE_FUNC) {
 
 		/* we don't support multiple functions per BPF module,
-		 * so treat EBPF_PSEUDO_CALL to extrernal function
+		 * so treat EBPF_PSEUDO_CALL to external function
 		 * as an ordinary EBPF_CALL.
 		 */
 		if (ins[idx].src_reg == EBPF_PSEUDO_CALL) {
diff --git a/lib/bpf/bpf_pkt.c b/lib/bpf/bpf_pkt.c
index 6e8248f0d6e4..701e8e2c62a9 100644
--- a/lib/bpf/bpf_pkt.c
+++ b/lib/bpf/bpf_pkt.c
@@ -169,7 +169,7 @@  bpf_eth_cbh_add(struct bpf_eth_cbh *cbh, uint16_t port, uint16_t queue)
 }
 
 /*
- * BPF packet processing routinies.
+ * BPF packet processing routines.
  */
 
 static inline uint32_t
diff --git a/lib/bpf/bpf_validate.c b/lib/bpf/bpf_validate.c
index 7b1291b382e9..eb8016ef196c 100644
--- a/lib/bpf/bpf_validate.c
+++ b/lib/bpf/bpf_validate.c
@@ -1723,7 +1723,7 @@  static const struct bpf_ins_check ins_chk[UINT8_MAX + 1] = {
 
 /*
  * make sure that instruction syntax is valid,
- * and it fields don't violate partciular instrcution type restrictions.
+ * and its fields don't violate particular instruction type restrictions.
  */
 static const char *
 check_syntax(const struct ebpf_insn *ins)
@@ -1954,7 +1954,7 @@  log_loop(const struct bpf_verifier *bvf)
  * First pass goes though all instructions in the set, checks that each
  * instruction is a valid one (correct syntax, valid field values, etc.)
  * and constructs control flow graph (CFG).
- * Then deapth-first search is performed over the constructed graph.
+ * Then depth-first search is performed over the constructed graph.
  * Programs with unreachable instructions and/or loops will be rejected.
  */
 static int
@@ -1981,7 +1981,7 @@  validate(struct bpf_verifier *bvf)
 
 		/*
 		 * construct CFG, jcc nodes have to outgoing edges,
-		 * 'exit' nodes - none, all others nodes have exaclty one
+		 * 'exit' nodes - none, all other nodes have exactly one
 		 * outgoing edge.
 		 */
 		switch (ins->code) {
@@ -2251,7 +2251,7 @@  evaluate(struct bpf_verifier *bvf)
 			idx = get_node_idx(bvf, node);
 			op = ins[idx].code;
 
-			/* for jcc node make a copy of evaluatoion state */
+			/* for jcc node make a copy of evaluation state */
 			if (node->nb_edge > 1)
 				rc |= save_eval_state(bvf, node);