Skip to content

Commit

Permalink
[S390] Expose a constant for the number of words representing the CRs
Browse files Browse the repository at this point in the history
We need to use this value in the checkpoint/restart code and would like to
have a constant instead of a magic '3'.

Cc: linux-s390@vger.kernel.org
Signed-off-by: Dan Smith <danms@us.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
  • Loading branch information
Dan Smith authored and Martin Schwidefsky committed Mar 26, 2009
1 parent 1fbc9f4 commit eaf1b6f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
4 changes: 3 additions & 1 deletion arch/s390/include/asm/ptrace.h
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,8 @@
#define NUM_CRS 16
#define NUM_ACRS 16

#define NUM_CR_WORDS 3

#define FPR_SIZE 8
#define FPC_SIZE 4
#define FPC_PAD_SIZE 4 /* gcc insists on aligning the fpregs */
Expand Down Expand Up @@ -334,7 +336,7 @@ struct pt_regs
*/
typedef struct
{
unsigned long cr[3];
unsigned long cr[NUM_CR_WORDS];
} per_cr_words;

#define PER_EM_MASK 0xE8000000UL
Expand Down
3 changes: 2 additions & 1 deletion arch/s390/kernel/compat_ptrace.h
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
#ifndef _PTRACE32_H
#define _PTRACE32_H

#include <asm/ptrace.h> /* needed for NUM_CR_WORDS */
#include "compat_linux.h" /* needed for psw_compat_t */

typedef struct {
__u32 cr[3];
__u32 cr[NUM_CR_WORDS];
} per_cr_words32;

typedef struct {
Expand Down

0 comments on commit eaf1b6f

Please sign in to comment.