powerpc/modules: Improve restore_r2() error message
"Linux Kernel Mailing List" <[email protected]> Fri, 2 Feb 2018 18:23:35 +0000 (UTC)
| Newsgroups | gmane.linux.kernel.commits.head |
|---|---|
| Message-ID | <[email protected]> |
Web: https://git.kernel.org/torvalds/c/1ea61ea23985c0f15c027e4c0ac02224efdfb243 Commit: 1ea61ea23985c0f15c027e4c0ac02224efdfb243 Parent: b9eab08d012fa093947b230f9a87257c27fb829b Refname: refs/heads/master Author: Josh Poimboeuf <[email protected]> AuthorDate: Tue Nov 14 04:29:10 2017 -0500 Committer: Michael Ellerman <[email protected]> CommitDate: Mon Dec 11 13:03:29 2017 +1100 powerpc/modules: Improve restore_r2() error message Print the function address associated with the restore_r2() error to make it easier to debug the problem. Also clarify the wording a bit. Before: module_64: patch_foo: Expect noop after relocate, got 3c820000 After: module_64: patch_foo: Expected nop after call, got 7c630034 at netdev_has_upper_dev+0x54/0xb0 [patch_foo] Signed-off-by: Josh Poimboeuf <[email protected]> Signed-off-by: Kamalesh Babulal <[email protected]> [mpe: Change noop to nop, as that's the name of the instruction] Signed-off-by: Michael Ellerman <[email protected]> --- arch/powerpc/kernel/module_64.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/powerpc/kernel/module_64.c b/arch/powerpc/kernel/module_64.c index 5b44668c0e45..e6c011d56629 100644 --- a/arch/powerpc/kernel/module_64.c +++ b/arch/powerpc/kernel/module_64.c @@ -501,8 +501,8 @@ static int restore_r2(u32 *instruction, struct module *me) return 1; if (*instruction != PPC_INST_NOP) { - pr_err("%s: Expect noop after relocate, got %08x\n", - me->name, *instruction); + pr_err("%s: Expected nop after call, got %08x at %pS\n", + me->name, *instruction, instruction); return 0; } /* ld r2,R2_STACK_OFFSET(r1) */ -- To unsubscribe from this list: send the line "unsubscribe git-commits-head" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html