diff options
author | Eric W. Biederman <ebiederm@xmission.com> | 2021-10-20 12:43:54 -0500 |
---|---|---|
committer | Eric W. Biederman <ebiederm@xmission.com> | 2021-10-25 15:56:29 -0500 |
commit | 984bd71fb32032ef395a895916853964166b322b (patch) | |
tree | c094ae98dade56d9f32f1021c0040de180c639e2 /tools/perf/util/c++/clang.cpp | |
parent | 83a1f27ad773b1d8f0460d3a676114c7651918cc (diff) |
signal/sparc: In setup_tsb_params convert open coded BUG into BUG
The function setup_tsb_params has exactly one caller tsb_grow. The
function tsb_grow passes in a tsb_bytes value that is between 8192 and
1048576 inclusive, and is guaranteed to be a power of 2. The function
setup_tsb_params verifies this property with a switch statement and
then prints an error and causes the task to exit if this is not true.
In practice that print statement can never be reached because tsb_grow
never passes in a bad tsb_size. So if tsb_size ever gets a bad value
that is a kernel bug.
So replace the do_exit which is effectively an open coded version of
BUG() with an actuall call to BUG(). Making it clearer that this
is a case that can never, and should never happen.
Cc: David Miller <davem@davemloft.net>
Cc: sparclinux@vger.kernel.org
Link: https://lkml.kernel.org/r/20211020174406.17889-8-ebiederm@xmission.com
Signed-off-by: Eric W. Biederman <ebiederm@xmission.com>
Diffstat (limited to 'tools/perf/util/c++/clang.cpp')
0 files changed, 0 insertions, 0 deletions