Skip to content

Commit

Permalink
powerpc: unrel_branch_check.sh: exit silently for early errors
Browse files Browse the repository at this point in the history
If we can't find the address of __end_interrupts, then we still exit
successfully as that is the current behaviour.

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20200811140435.20957-8-sfr@canb.auug.org.au
  • Loading branch information
Stephen Rothwell authored and Michael Ellerman committed Sep 2, 2020
1 parent 3745ae6 commit af13a22
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion arch/powerpc/tools/unrel_branch_check.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,12 @@ kstart=0xc000000000000000
printf -v kend '0x%x' $(( kstart + 0x10000 ))

end_intr=0x$(
$objdump -R -d --start-address="$kstart" --stop-address="$kend" "$vmlinux" |
$objdump -R -d --start-address="$kstart" --stop-address="$kend" "$vmlinux" 2>/dev/null |
awk '$2 == "<__end_interrupts>:" { print $1 }'
)
if [ "$end_intr" = "0x" ]; then
exit 0
fi

$objdump -R -D --no-show-raw-insn --start-address="$kstart" --stop-address="$end_intr" "$vmlinux" |
sed -E -n '
Expand Down

0 comments on commit af13a22

Please sign in to comment.