summaryrefslogtreecommitdiff
path: root/kernel/bpf/liveness.c
diff options
context:
space:
mode:
authorJiri Kosina <jkosina@suse.com>2025-12-02 14:46:11 +0100
committerJiri Kosina <jkosina@suse.com>2025-12-02 14:46:11 +0100
commit7362b5b493102c6b71827c2da22117b475528f6d (patch)
tree62888e5fb3459077d2874c61bc8b378d7bf5c7da /kernel/bpf/liveness.c
parenteb41c955b05ea015275b3188b27b3960a95ae149 (diff)
parent06416555c883e3ffabcc62ad39617c23d6b2f012 (diff)
Merge branch 'for-6.19/nintendo' into for-linus
- switch to WQ_PERCPU workaueues (Marco Crivellari) - reduce potential initialization blocking time of hid-nintendo (Willy Huang)
Diffstat (limited to 'kernel/bpf/liveness.c')
-rw-r--r--kernel/bpf/liveness.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/kernel/bpf/liveness.c b/kernel/bpf/liveness.c
index 3c611aba7f52..1e6538f59a78 100644
--- a/kernel/bpf/liveness.c
+++ b/kernel/bpf/liveness.c
@@ -195,8 +195,10 @@ static struct func_instance *__lookup_instance(struct bpf_verifier_env *env,
return ERR_PTR(-ENOMEM);
result->must_write_set = kvcalloc(subprog_sz, sizeof(*result->must_write_set),
GFP_KERNEL_ACCOUNT);
- if (!result->must_write_set)
+ if (!result->must_write_set) {
+ kvfree(result);
return ERR_PTR(-ENOMEM);
+ }
memcpy(&result->callchain, callchain, sizeof(*callchain));
result->insn_cnt = subprog_sz;
hash_add(liveness->func_instances, &result->hl_node, key);