WARNING: line length of 81 exceeds 80 columns #34: FILE: include/linux/bpf_verifier.h:991: +static inline bool bpf_is_prune_point(struct bpf_verifier_env *env, int insn_idx) WARNING: line length of 86 exceeds 80 columns #44: FILE: include/linux/bpf_verifier.h:1001: +static inline bool bpf_is_force_checkpoint(struct bpf_verifier_env *env, int insn_idx) WARNING: line length of 81 exceeds 80 columns #54: FILE: include/linux/bpf_verifier.h:1011: +static inline bool bpf_calls_callback(struct bpf_verifier_env *env, int insn_idx) CHECK: Please use a blank line after function/struct/union/enum declarations #154: FILE: include/linux/bpf_verifier.h:1299: +} +bool bpf_is_kfunc_pkt_changing(struct bpf_kfunc_call_arg_meta *meta); WARNING: Prefer 'fallthrough;' over fallthrough comment #216: FILE: kernel/bpf/cfg.c:38: + * 0x11 - discovered and fall-through edge labelled WARNING: Prefer 'fallthrough;' over fallthrough comment #217: FILE: kernel/bpf/cfg.c:39: + * 0x12 - discovered and fall-through and branch edges labelled CHECK: Please don't use multiple blank lines #228: FILE: kernel/bpf/cfg.c:50: + + WARNING: line length of 84 exceeds 80 columns #247: FILE: kernel/bpf/cfg.c:69: + * Eventually this function would be called when env->cfg.insn_state[w] == EXPLORED. WARNING: line length of 85 exceeds 80 columns #346: FILE: kernel/bpf/cfg.c:168: + size_t new_size = sizeof(struct bpf_iarray) + n_elem * sizeof(old->items[0]); WARNING: line length of 81 exceeds 80 columns #351: FILE: kernel/bpf/cfg.c:173: + /* this is what callers always want, so simplify the call site */ WARNING: line length of 90 exceeds 80 columns #473: FILE: kernel/bpf/cfg.c:295: + if (jt_cur->items[0] >= subprog_start && jt_cur->items[0] < subprog_end) { WARNING: Missing a blank line after declarations #475: FILE: kernel/bpf/cfg.c:297: + u32 old_cnt = jt ? jt->cnt : 0; + jt = bpf_iarray_realloc(jt, old_cnt + jt_cur->cnt); WARNING: line length of 85 exceeds 80 columns #480: FILE: kernel/bpf/cfg.c:302: + memcpy(jt->items + old_cnt, jt_cur->items, jt_cur->cnt << 2); WARNING: line length of 97 exceeds 80 columns #487: FILE: kernel/bpf/cfg.c:309: + verbose(env, "no jump tables found for subprog starting at %u\n", subprog_start); WARNING: line length of 93 exceeds 80 columns #510: FILE: kernel/bpf/cfg.c:332: + /* Check that the every element of the jump table fits within the given subprogram */ WARNING: line length of 82 exceeds 80 columns #512: FILE: kernel/bpf/cfg.c:334: + if (jt->items[i] < subprog_start || jt->items[i] >= subprog_end) { WARNING: line length of 102 exceeds 80 columns #513: FILE: kernel/bpf/cfg.c:335: + verbose(env, "jump table for insn %d points outside of the subprog [%u,%u]\n", CHECK: Alignment should match open parenthesis #514: FILE: kernel/bpf/cfg.c:336: + verbose(env, "jump table for insn %d points outside of the subprog [%u,%u]\n", + t, subprog_start, subprog_end); WARNING: line length of 94 exceeds 80 columns #545: FILE: kernel/bpf/cfg.c:367: + verbose(env, "indirect jump out of range from insn %d to %d\n", t, w); WARNING: Prefer 'fallthrough;' over fallthrough comment #603: FILE: kernel/bpf/cfg.c:425: + /* All non-branch instructions have a single fall-through edge. */ WARNING: line length of 85 exceeds 80 columns #629: FILE: kernel/bpf/cfg.c:451: + /* For functions that invoke callbacks it is not known how many times WARNING: line length of 87 exceeds 80 columns #630: FILE: kernel/bpf/cfg.c:452: + * callback would be called. Verifier models callback calling functions WARNING: line length of 86 exceeds 80 columns #631: FILE: kernel/bpf/cfg.c:453: + * by repeatedly visiting callback bodies and returning to origin call WARNING: line length of 84 exceeds 80 columns #633: FILE: kernel/bpf/cfg.c:455: + * In order to stop such iteration verifier needs to identify when a WARNING: line length of 83 exceeds 80 columns #634: FILE: kernel/bpf/cfg.c:456: + * state identical some state from a previous iteration is reached. WARNING: line length of 84 exceeds 80 columns #635: FILE: kernel/bpf/cfg.c:457: + * Check below forces creation of checkpoint before callback calling WARNING: line length of 89 exceeds 80 columns #665: FILE: kernel/bpf/cfg.c:487: + ret = bpf_fetch_kfunc_arg_meta(env, insn->imm, insn->off, &meta); WARNING: line length of 92 exceeds 80 columns #668: FILE: kernel/bpf/cfg.c:490: + /* Checking and saving state checkpoints at iter_next() call WARNING: line length of 94 exceeds 80 columns #669: FILE: kernel/bpf/cfg.c:491: + * is crucial for fast convergence of open-coded iterator loop WARNING: line length of 86 exceeds 80 columns #670: FILE: kernel/bpf/cfg.c:492: + * logic, so we need to force it. If we don't do that, WARNING: line length of 93 exceeds 80 columns #671: FILE: kernel/bpf/cfg.c:493: + * is_state_visited() might skip saving a checkpoint, causing WARNING: line length of 82 exceeds 80 columns #672: FILE: kernel/bpf/cfg.c:494: + * unnecessarily long sequence of not checkpointed WARNING: line length of 88 exceeds 80 columns #673: FILE: kernel/bpf/cfg.c:495: + * instructions and jumps, leading to exhaustion of jump WARNING: line length of 92 exceeds 80 columns #674: FILE: kernel/bpf/cfg.c:496: + * history buffer, and potentially other undesired outcomes. WARNING: line length of 88 exceeds 80 columns #675: FILE: kernel/bpf/cfg.c:497: + * It is expected that with correct open-coded iterators WARNING: line length of 93 exceeds 80 columns #676: FILE: kernel/bpf/cfg.c:498: + * convergence will happen quickly, so we don't run a risk of WARNING: line length of 93 exceeds 80 columns #691: FILE: kernel/bpf/cfg.c:513: + return visit_func_call_insn(t, insns, env, insn->src_reg == BPF_PSEUDO_CALL); CHECK: multiple assignments should be avoided #735: FILE: kernel/bpf/cfg.c:557: + insn_state = env->cfg.insn_state = kvzalloc_objs(int, insn_cnt, CHECK: multiple assignments should be avoided #740: FILE: kernel/bpf/cfg.c:562: + insn_stack = env->cfg.insn_stack = kvzalloc_objs(int, insn_cnt, WARNING: line length of 93 exceeds 80 columns #799: FILE: kernel/bpf/cfg.c:621: + verbose(env, "jump into the middle of ldimm64 insn %d\n", i); WARNING: line length of 81 exceeds 80 columns #807: FILE: kernel/bpf/cfg.c:629: + env->prog->aux->changes_pkt_data = env->subprog_info[0].changes_pkt_data; CHECK: multiple assignments should be avoided #813: FILE: kernel/bpf/cfg.c:635: + env->cfg.insn_state = env->cfg.insn_stack = NULL; WARNING: line length of 81 exceeds 80 columns #819: FILE: kernel/bpf/cfg.c:641: + * [env->subprog_info[i].postorder_start, env->subprog_info[i+1].postorder_start) WARNING: line length of 82 exceeds 80 columns #918: FILE: kernel/bpf/cfg.c:740: + low[w] = min(low[w], low[succ->items[j]]); WARNING: line length of 94 exceeds 80 columns #1071: FILE: kernel/bpf/verifier.c:4420: + } else if (bpf_is_sync_callback_calling_insn(insn) && idx != subseq_idx - 1) { WARNING: line length of 81 exceeds 80 columns #1428: FILE: kernel/bpf/verifier.c:18329: + err = bpf_fetch_kfunc_arg_meta(env, call->imm, call->off, &meta); WARNING: line length of 91 exceeds 80 columns #1968: FILE: kernel/bpf/verifier.c:19947: + force_new_state = env->test_state_freq || bpf_is_force_checkpoint(env, insn_idx) || WARNING: line length of 94 exceeds 80 columns #1977: FILE: kernel/bpf/verifier.c:20227: + n = bpf_is_force_checkpoint(env, insn_idx) && sl->state.branches > 0 ? 64 : 3; WARNING: line length of 83 exceeds 80 columns #1988: FILE: kernel/bpf/verifier.c:20531: + max_index - min_index + 1); ERROR: code indent should use tabs where possible #1988: FILE: kernel/bpf/verifier.c:20531: +^I^I^I^I^I^I max_index - min_index + 1);$ CHECK: Alignment should match open parenthesis #1988: FILE: kernel/bpf/verifier.c:20531: + env->gotox_tmp_buf = bpf_iarray_realloc(env->gotox_tmp_buf, + max_index - min_index + 1); WARNING: line length of 91 exceeds 80 columns #1994: FILE: kernel/bpf/verifier.c:20536: + n = bpf_copy_insn_array_uniq(map, min_index, max_index, env->gotox_tmp_buf->items); total: 1 errors, 44 warnings, 7 checks, 2151 lines checked NOTE: For some of the reported defects, checkpatch may be able to mechanically convert to the typical style using --fix or --fix-inplace. NOTE: Whitespace errors detected. You may wish to use scripts/cleanpatch or scripts/cleanfile Commit 0a96511a899a ("bpf: Move check_cfg() into cfg.c") has style problems, please review. NOTE: Ignored message types: ALLOC_SIZEOF_STRUCT BAD_REPORTED_BY_LINK CAMELCASE COMMIT_LOG_LONG_LINE FILE_PATH_CHANGES GIT_COMMIT_ID MACRO_ARG_REUSE NO_AUTHOR_SIGN_OFF NOTE: If any of the errors are false positives, please report them to the maintainer, see CHECKPATCH in MAINTAINERS.