GDBserver
Defines | Functions | Variables
/home/stan/gdb/src/gdb/gdbserver/linux-s390-low.c File Reference
#include "server.h"
#include "linux-low.h"
#include "elf/common.h"
#include <asm/ptrace.h>
#include <sys/ptrace.h>
#include <sys/uio.h>
#include <elf.h>

Go to the source code of this file.

Defines

#define HWCAP_S390_HIGH_GPRS   512
#define PTRACE_GETREGSET   0x4204
#define PTRACE_SETREGSET   0x4205
#define s390_num_regs   52
#define s390_breakpoint_len   2

Functions

void init_registers_s390_linux32 (void)
void init_registers_s390_linux32v1 (void)
void init_registers_s390_linux32v2 (void)
void init_registers_s390_linux64 (void)
void init_registers_s390_linux64v1 (void)
void init_registers_s390_linux64v2 (void)
void init_registers_s390_te_linux64 (void)
void init_registers_s390x_linux64 (void)
void init_registers_s390x_linux64v1 (void)
void init_registers_s390x_linux64v2 (void)
void init_registers_s390x_te_linux64 (void)
static int s390_cannot_fetch_register (int regno)
static int s390_cannot_store_register (int regno)
static void s390_collect_ptrace_register (struct regcache *regcache, int regno, char *buf)
static void s390_supply_ptrace_register (struct regcache *regcache, int regno, const char *buf)
static void s390_fill_gregset (struct regcache *regcache, void *buf)
static void s390_fill_last_break (struct regcache *regcache, void *buf)
static void s390_store_last_break (struct regcache *regcache, const void *buf)
static void s390_fill_system_call (struct regcache *regcache, void *buf)
static void s390_store_system_call (struct regcache *regcache, const void *buf)
static CORE_ADDR s390_get_pc (struct regcache *regcache)
static void s390_set_pc (struct regcache *regcache, CORE_ADDR newpc)
static int s390_check_regset (int pid, int regset, int regsize)
static void s390_arch_setup (void)
static int s390_breakpoint_at (CORE_ADDR pc)
static struct regs_infos390_regs_info (void)
void initialize_low_arch (void)

Variables

struct target_desctdesc_s390_linux32
struct target_desctdesc_s390_linux32v1
struct target_desctdesc_s390_linux32v2
struct target_desctdesc_s390_linux64
struct target_desctdesc_s390_linux64v1
struct target_desctdesc_s390_linux64v2
struct target_desctdesc_s390_te_linux64
struct target_desctdesc_s390x_linux64
struct target_desctdesc_s390x_linux64v1
struct target_desctdesc_s390x_linux64v2
struct target_desctdesc_s390x_te_linux64
static int s390_regmap []
static struct regset_info s390_regsets []
static const unsigned char s390_breakpoint [] = { 0, 1 }
static struct usrregs_info s390_usrregs_info
static struct regsets_info s390_regsets_info
static struct regs_info regs_info
struct linux_target_ops the_low_target

Define Documentation

#define HWCAP_S390_HIGH_GPRS   512

Definition at line 32 of file linux-s390-low.c.

Referenced by s390_arch_setup().

#define PTRACE_GETREGSET   0x4204
#define PTRACE_SETREGSET   0x4205

Definition at line 40 of file linux-s390-low.c.

Referenced by aarch64_linux_set_debug_regs().

#define s390_breakpoint_len   2

Definition at line 327 of file linux-s390-low.c.

Referenced by s390_breakpoint_at().

#define s390_num_regs   52

Definition at line 87 of file linux-s390-low.c.


Function Documentation

void init_registers_s390_linux32 ( void  )

Referenced by initialize_low_arch().

Referenced by initialize_low_arch().

Referenced by initialize_low_arch().

void init_registers_s390_linux64 ( void  )

Referenced by initialize_low_arch().

Referenced by initialize_low_arch().

Referenced by initialize_low_arch().

Referenced by initialize_low_arch().

Referenced by initialize_low_arch().

Referenced by initialize_low_arch().

Referenced by initialize_low_arch().

Referenced by initialize_low_arch().

void initialize_low_arch ( void  )
static void s390_arch_setup ( void  ) [static]
static int s390_breakpoint_at ( CORE_ADDR  pc) [static]
static int s390_cannot_fetch_register ( int  regno) [static]

Definition at line 152 of file linux-s390-low.c.

static int s390_cannot_store_register ( int  regno) [static]

Definition at line 158 of file linux-s390-low.c.

static int s390_check_regset ( int  pid,
int  regset,
int  regsize 
) [static]

Definition at line 394 of file linux-s390-low.c.

References errno, and PTRACE_GETREGSET.

Referenced by s390_arch_setup().

static void s390_collect_ptrace_register ( struct regcache regcache,
int  regno,
char *  buf 
) [static]
static void s390_fill_gregset ( struct regcache regcache,
void *  buf 
) [static]
static void s390_fill_last_break ( struct regcache regcache,
void *  buf 
) [static]

Definition at line 289 of file linux-s390-low.c.

static void s390_fill_system_call ( struct regcache regcache,
void *  buf 
) [static]

Definition at line 304 of file linux-s390-low.c.

References collect_register_by_name().

static CORE_ADDR s390_get_pc ( struct regcache regcache) [static]

Definition at line 330 of file linux-s390-low.c.

References collect_register_by_name(), register_size(), and regcache::tdesc.

static struct regs_info* s390_regs_info ( void  ) [static, read]

Definition at line 547 of file linux-s390-low.c.

References current_process(), register_size(), regs_info, and process_info::tdesc.

static void s390_set_pc ( struct regcache regcache,
CORE_ADDR  newpc 
) [static]
static void s390_store_last_break ( struct regcache regcache,
const void *  buf 
) [static]

Definition at line 295 of file linux-s390-low.c.

References register_size(), supply_register_by_name(), and regcache::tdesc.

static void s390_store_system_call ( struct regcache regcache,
const void *  buf 
) [static]

Definition at line 310 of file linux-s390-low.c.

References supply_register_by_name().

static void s390_supply_ptrace_register ( struct regcache regcache,
int  regno,
const char *  buf 
) [static]

Variable Documentation

struct regs_info regs_info [static]
Initial value:

Definition at line 517 of file linux-s390-low.c.

Referenced by s390_regs_info().

const unsigned char s390_breakpoint[] = { 0, 1 } [static]

Definition at line 326 of file linux-s390-low.c.

Referenced by s390_breakpoint_at().

int s390_regmap[] [static]
Initial value:
 {
  PT_PSWMASK, PT_PSWADDR,

  PT_GPR0, PT_GPR1, PT_GPR2, PT_GPR3,
  PT_GPR4, PT_GPR5, PT_GPR6, PT_GPR7,
  PT_GPR8, PT_GPR9, PT_GPR10, PT_GPR11,
  PT_GPR12, PT_GPR13, PT_GPR14, PT_GPR15,

  PT_ACR0, PT_ACR1, PT_ACR2, PT_ACR3,
  PT_ACR4, PT_ACR5, PT_ACR6, PT_ACR7,
  PT_ACR8, PT_ACR9, PT_ACR10, PT_ACR11,
  PT_ACR12, PT_ACR13, PT_ACR14, PT_ACR15,

  PT_FPC,


  PT_FPR0_HI, PT_FPR1_HI, PT_FPR2_HI, PT_FPR3_HI,
  PT_FPR4_HI, PT_FPR5_HI, PT_FPR6_HI, PT_FPR7_HI,
  PT_FPR8_HI, PT_FPR9_HI, PT_FPR10_HI, PT_FPR11_HI,
  PT_FPR12_HI, PT_FPR13_HI, PT_FPR14_HI, PT_FPR15_HI,







  PT_ORIGGPR2,
}

Definition at line 89 of file linux-s390-low.c.

struct regset_info s390_regsets[] [static]
Initial value:
 {
  { 0, 0, 0, 0, GENERAL_REGS, s390_fill_gregset, NULL },
  
  { PTRACE_GETREGSET, PTRACE_GETREGSET, NT_S390_LAST_BREAK, 0,
    EXTENDED_REGS, s390_fill_last_break, s390_store_last_break },
  { PTRACE_GETREGSET, PTRACE_SETREGSET, NT_S390_SYSTEM_CALL, 0,
    EXTENDED_REGS, s390_fill_system_call, s390_store_system_call },
  { 0, 0, 0, -1, -1, NULL, NULL }
}

Definition at line 315 of file linux-s390-low.c.

Referenced by s390_arch_setup().

struct regsets_info s390_regsets_info [static]
Initial value:
  {
    s390_regsets, 
    0, 
    NULL, 
  }

Definition at line 510 of file linux-s390-low.c.

Initial value:

Definition at line 504 of file linux-s390-low.c.

 All Classes Files Functions Variables Typedefs Enumerations Enumerator Defines