Back to index

cell-binutils  2.17cvs20070401
Classes | Defines | Typedefs | Enumerations | Functions | Variables
callback.h File Reference
#include <ansidecl.h>
#include <stdarg.h>
#include "bfd.h"

Go to the source code of this file.

Classes

struct  CB_TARGET_DEFS_MAP
struct  host_callback_struct
struct  host_callback_struct::pipe_write_buffer
struct  cb_syscall

Defines

#define MAX_CALLBACK_FDS   10
#define HOST_CALLBACK_MAGIC   4705 /* teds constant */
#define CB_SYS_exit   1
#define CB_SYS_open   2
#define CB_SYS_close   3
#define CB_SYS_read   4
#define CB_SYS_write   5
#define CB_SYS_lseek   6
#define CB_SYS_unlink   7
#define CB_SYS_getpid   8
#define CB_SYS_kill   9
#define CB_SYS_fstat   10
#define CB_SYS_argvlen   12
#define CB_SYS_argv   13
#define CB_SYS_chdir   14
#define CB_SYS_stat   15
#define CB_SYS_chmod   16
#define CB_SYS_utime   17
#define CB_SYS_time   18
#define CB_SYS_lstat   19
#define CB_SYS_rename   20
#define CB_SYS_truncate   21
#define CB_SYS_ftruncate   22
#define CB_SYS_pipe   23
#define CB_SYSCALL_MAGIC   0x12344321
#define CB_SYSCALL_INIT(sc)

Typedefs

typedef struct host_callback_struct
typedef struct cb_syscall CB_SYSCALL

Enumerations

enum  CB_RC { CB_RC_OK = 0, CB_RC_ERR, CB_RC_ACCESS, CB_RC_NO_MEM }

Functions

CB_RC cb_read_target_syscall_maps PARAMS ((host_callback *, const char *))
int cb_target_to_host_syscall PARAMS ((host_callback *, int))
int cb_host_to_target_stat PARAMS ((host_callback *, const struct stat *, PTR))
void cb_store_target_endian PARAMS ((host_callback *, char *, int, long))
CB_RC cb_syscall PARAMS ((host_callback *, CB_SYSCALL *))

Variables

host_callback default_callback

Class Documentation

struct CB_TARGET_DEFS_MAP

Definition at line 62 of file callback.h.

Class Members
int host_val
int target_val
struct host_callback_struct::pipe_write_buffer

Definition at line 153 of file callback.h.

Class Members
char * buffer
int size

Define Documentation

#define CB_SYS_argv   13

Definition at line 216 of file callback.h.

#define CB_SYS_argvlen   12

Definition at line 215 of file callback.h.

#define CB_SYS_chdir   14

Definition at line 219 of file callback.h.

#define CB_SYS_chmod   16

Definition at line 221 of file callback.h.

#define CB_SYS_close   3

Definition at line 204 of file callback.h.

#define CB_SYS_exit   1

Definition at line 202 of file callback.h.

#define CB_SYS_fstat   10

Definition at line 211 of file callback.h.

#define CB_SYS_ftruncate   22

Definition at line 229 of file callback.h.

#define CB_SYS_getpid   8

Definition at line 209 of file callback.h.

#define CB_SYS_kill   9

Definition at line 210 of file callback.h.

#define CB_SYS_lseek   6

Definition at line 207 of file callback.h.

#define CB_SYS_lstat   19

Definition at line 226 of file callback.h.

#define CB_SYS_open   2

Definition at line 203 of file callback.h.

#define CB_SYS_pipe   23

Definition at line 230 of file callback.h.

#define CB_SYS_read   4

Definition at line 205 of file callback.h.

#define CB_SYS_rename   20

Definition at line 227 of file callback.h.

#define CB_SYS_stat   15

Definition at line 220 of file callback.h.

#define CB_SYS_time   18

Definition at line 223 of file callback.h.

#define CB_SYS_truncate   21

Definition at line 228 of file callback.h.

#define CB_SYS_unlink   7

Definition at line 208 of file callback.h.

#define CB_SYS_utime   17

Definition at line 222 of file callback.h.

#define CB_SYS_write   5

Definition at line 206 of file callback.h.

#define CB_SYSCALL_INIT (   sc)
Value:
do { \
  memset ((sc), 0, sizeof (*(sc))); \
  (sc)->magic = CB_SYSCALL_MAGIC; \
} while (0)

Definition at line 276 of file callback.h.

#define CB_SYSCALL_MAGIC   0x12344321

Definition at line 272 of file callback.h.

#define HOST_CALLBACK_MAGIC   4705 /* teds constant */

Definition at line 189 of file callback.h.

#define MAX_CALLBACK_FDS   10

Definition at line 67 of file callback.h.


Typedef Documentation

Definition at line 72 of file callback.h.


Enumeration Type Documentation

enum CB_RC
Enumerator:
CB_RC_OK 
CB_RC_ERR 
CB_RC_ACCESS 
CB_RC_NO_MEM 

Definition at line 284 of file callback.h.

             {
  CB_RC_OK = 0,
  /* generic error */
  CB_RC_ERR,
  /* either file not found or no read access */
  CB_RC_ACCESS,
  CB_RC_NO_MEM
} CB_RC;

Function Documentation

CB_RC cb_read_target_syscall_maps PARAMS ( (host_callback *, const char *)  )
int cb_target_to_host_syscall PARAMS ( (host_callback *, int )
int cb_host_to_target_stat PARAMS ( (host_callback *, const struct stat *, PTR )
void cb_store_target_endian PARAMS ( (host_callback *, char *, int, long )
CB_RC cb_syscall PARAMS ( (host_callback *, CB_SYSCALL *)  )

Variable Documentation

host_callback default_callback