Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 14c9b31a authored by Gustavo A. R. Silva's avatar Gustavo A. R. Silva Committed by Arnaldo Carvalho de Melo
Browse files

perf header: Fix lock/unlock imbalances when processing BPF/BTF info



Fix lock/unlock imbalances by refactoring the code a bit and adding
calls to up_write() before return.

Signed-off-by: default avatarGustavo A. R. Silva <gustavo@embeddedor.com>
Acked-by: default avatarSong Liu <songliubraving@fb.com>
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Addresses-Coverity-ID: 1444315 ("Missing unlock")
Addresses-Coverity-ID: 1444316 ("Missing unlock")
Fixes: a70a1123 ("perf bpf: Save BTF information as headers to perf.data")
Fixes: 606f972b ("perf bpf: Save bpf_prog_info information as headers to perf.data")
Link: http://lkml.kernel.org/r/20190408173355.GA10501@embeddedor


[ Simplified the exit path to have just one up_write() + return ]
Signed-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
parent 9d5dcc93
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment