Skip to content

Commit

Permalink
powerpc/ptrace: Remove duplicate check from pt_regs_check()
Browse files Browse the repository at this point in the history
"offsetof(struct pt_regs, msr) == offsetof(struct user_pt_regs, msr)"
checked in pt_regs_check() twice in a row. Remove the second check.

Signed-off-by: Denis Efremov <[email protected]>
Signed-off-by: Michael Ellerman <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
  • Loading branch information
evdenis authored and mpe committed Mar 24, 2021
1 parent 13b8219 commit 0b71b37
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions arch/powerpc/kernel/ptrace/ptrace.c
Original file line number Diff line number Diff line change
Expand Up @@ -354,8 +354,6 @@ void __init pt_regs_check(void)
offsetof(struct user_pt_regs, nip));
BUILD_BUG_ON(offsetof(struct pt_regs, msr) !=
offsetof(struct user_pt_regs, msr));
BUILD_BUG_ON(offsetof(struct pt_regs, msr) !=
offsetof(struct user_pt_regs, msr));
BUILD_BUG_ON(offsetof(struct pt_regs, orig_gpr3) !=
offsetof(struct user_pt_regs, orig_gpr3));
BUILD_BUG_ON(offsetof(struct pt_regs, ctr) !=
Expand Down

0 comments on commit 0b71b37

Please sign in to comment.