diff options
author | Michael Ellerman <[email protected]> | 2022-08-01 18:48:34 +1000 |
---|---|---|
committer | Michael Ellerman <[email protected]> | 2022-08-01 22:21:18 +1000 |
commit | ff446cd76854d47f451a84c26bb70934ae2ec5a7 (patch) | |
tree | 1249e564c78366f78a1483a5d38836837d656404 /lib/mpi/mpi-bit.c | |
parent | df5d4b616ee76abc97e5bd348e22659c2b095b1c (diff) |
selftests/powerpc: Avoid GCC 12 uninitialised variable warning
GCC 12 thinks that `actual` might be used uninitialised. It's not, the
use is guarded by `bad_mmcr2` which is only set to true at the same
point where `actual` is initialised.
cycles_with_mmcr2_test.c: In function ‘cycles_with_mmcr2’:
cycles_with_mmcr2_test.c:81:17: error: ‘actual’ may be used uninitialized [-Werror=maybe-uninitialized]
81 | printf("Bad MMCR2 value seen is 0x%lx\n", actual);
Silence the warning by initialising `actual` to zero.
Signed-off-by: Michael Ellerman <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Diffstat (limited to 'lib/mpi/mpi-bit.c')
0 files changed, 0 insertions, 0 deletions