Skip to content

Commit

Permalink
powerpc/64s/exception: move paca save area offsets into exception-64s.S
Browse files Browse the repository at this point in the history
No generated code change.

Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
  • Loading branch information
Nicholas Piggin authored and Michael Ellerman committed Jul 2, 2019
1 parent d064151 commit 1582009
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 14 deletions.
17 changes: 3 additions & 14 deletions arch/powerpc/include/asm/exception-64s.h
Original file line number Diff line number Diff line change
Expand Up @@ -36,22 +36,11 @@
*/
#include <asm/feature-fixups.h>

/* PACA save area offsets (exgen, exmc, etc) */
#define EX_R9 0
#define EX_R10 8
#define EX_R11 16
#define EX_R12 24
#define EX_R13 32
#define EX_DAR 40
#define EX_DSISR 48
#define EX_CCR 52
#define EX_CFAR 56
#define EX_PPR 64
/* PACA save area size in u64 units (exgen, exmc, etc) */
#if defined(CONFIG_RELOCATABLE)
#define EX_CTR 72
#define EX_SIZE 10 /* size in u64 units */
#define EX_SIZE 10
#else
#define EX_SIZE 9 /* size in u64 units */
#define EX_SIZE 9
#endif

/*
Expand Down
22 changes: 22 additions & 0 deletions arch/powerpc/kernel/exceptions-64s.S
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,28 @@
#include <asm/feature-fixups.h>
#include <asm/kup.h>

/* PACA save area offsets (exgen, exmc, etc) */
#define EX_R9 0
#define EX_R10 8
#define EX_R11 16
#define EX_R12 24
#define EX_R13 32
#define EX_DAR 40
#define EX_DSISR 48
#define EX_CCR 52
#define EX_CFAR 56
#define EX_PPR 64
#if defined(CONFIG_RELOCATABLE)
#define EX_CTR 72
.if EX_SIZE != 10
.error "EX_SIZE is wrong"
.endif
#else
.if EX_SIZE != 9
.error "EX_SIZE is wrong"
.endif
#endif

/*
* We're short on space and time in the exception prolog, so we can't
* use the normal LOAD_REG_IMMEDIATE macro to load the address of label.
Expand Down

0 comments on commit 1582009

Please sign in to comment.