OpenCores
URL https://opencores.org/ocsvn/hf-risc/hf-risc/trunk

Subversion Repositories hf-risc

[/] [hf-risc/] [trunk/] [tools/] [riscv-gnu-toolchain-master/] [glibc/] [sysdeps/] [unix/] [sysv/] [linux/] [riscv/] [sys/] [procfs.h] - Blame information for rev 13

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 13 serginhofr
/* Copyright (C) 1996, 1997, 1999, 2000, 2002, 2003, 2004
2
        Free Software Foundation, Inc.
3
   This file is part of the GNU C Library.
4
 
5
   The GNU C Library is free software; you can redistribute it and/or
6
   modify it under the terms of the GNU Lesser General Public
7
   License as published by the Free Software Foundation; either
8
   version 2.1 of the License, or (at your option) any later version.
9
 
10
   The GNU C Library is distributed in the hope that it will be useful,
11
   but WITHOUT ANY WARRANTY; without even the implied warranty of
12
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
13
   Lesser General Public License for more details.
14
 
15
   You should have received a copy of the GNU Lesser General Public
16
   License along with the GNU C Library; if not, write to the Free
17
   Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
18
   02111-1307 USA.  */
19
 
20
#ifndef _SYS_PROCFS_H
21
#define _SYS_PROCFS_H   1
22
 
23
/* This is somehow modelled after the file of the same name on SysVr4
24
   systems.  It provides a definition of the core file format for ELF
25
   used on Linux.  */
26
 
27
#include <features.h>
28
#include <sys/time.h>
29
#include <sys/types.h>
30
#include <sys/user.h>
31
#include <sys/ucontext.h>
32
 
33
/* ELF register definitions */
34
#define ELF_NGREG       NGREG
35
#define ELF_NFPREG      NFPREG
36
 
37
typedef greg_t elf_greg_t;
38
typedef gregset_t elf_gregset_t;
39
typedef fpreg_t elf_fpreg_t;
40
typedef fpregset_t elf_fpregset_t;
41
 
42
__BEGIN_DECLS
43
 
44
struct elf_siginfo
45
  {
46
    int si_signo;                       /* Signal number.  */
47
    int si_code;                        /* Extra code.  */
48
    int si_errno;                       /* Errno.  */
49
  };
50
 
51
 
52
/* Definitions to generate Intel SVR4-like core files.  These mostly
53
   have the same names as the SVR4 types with "elf_" tacked on the
54
   front to prevent clashes with linux definitions, and the typedef
55
   forms have been avoided.  This is mostly like the SVR4 structure,
56
   but more Linuxy, with things that Linux does not support and which
57
   gdb doesn't really use excluded.  Fields present but not used are
58
   marked with "XXX".  */
59
struct elf_prstatus
60
  {
61
    struct elf_siginfo pr_info;         /* Info associated with signal.  */
62
    short int pr_cursig;                /* Current signal.  */
63
    unsigned long int pr_sigpend;       /* Set of pending signals.  */
64
    unsigned long int pr_sighold;       /* Set of held signals.  */
65
    __pid_t pr_pid;
66
    __pid_t pr_ppid;
67
    __pid_t pr_pgrp;
68
    __pid_t pr_sid;
69
    struct timeval pr_utime;            /* User time.  */
70
    struct timeval pr_stime;            /* System time.  */
71
    struct timeval pr_cutime;           /* Cumulative user time.  */
72
    struct timeval pr_cstime;           /* Cumulative system time.  */
73
    elf_gregset_t pr_reg;               /* GP registers.  */
74
    int pr_fpvalid;                     /* True if math copro being used.  */
75
  };
76
 
77
 
78
#define ELF_PRARGSZ     (80)    /* Number of chars for args */
79
 
80
struct elf_prpsinfo
81
  {
82
    char pr_state;                      /* Numeric process state.  */
83
    char pr_sname;                      /* Char for pr_state.  */
84
    char pr_zomb;                       /* Zombie.  */
85
    char pr_nice;                       /* Nice val.  */
86
    unsigned long int pr_flag;          /* Flags.  */
87
    long pr_uid;
88
    long pr_gid;
89
    int pr_pid, pr_ppid, pr_pgrp, pr_sid;
90
    /* Lots missing */
91
    char pr_fname[16];                  /* Filename of executable.  */
92
    char pr_psargs[ELF_PRARGSZ];        /* Initial part of arg list.  */
93
  };
94
 
95
 
96
/* Addresses.  */
97
typedef void *psaddr_t;
98
 
99
/* Register sets.  Linux has different names.  */
100
typedef elf_gregset_t prgregset_t;
101
typedef elf_fpregset_t prfpregset_t;
102
 
103
/* We don't have any differences between processes and threads,
104
   therefore habe only ine PID type.  */
105
typedef __pid_t lwpid_t;
106
 
107
 
108
typedef struct elf_prstatus prstatus_t;
109
typedef struct elf_prpsinfo prpsinfo_t;
110
 
111
__END_DECLS
112
 
113
#endif  /* sys/procfs.h */

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.