PS2SDK
PS2 Homebrew Libraries
Loading...
Searching...
No Matches
defs.h File Reference
#include <types.h>
+ Include dependency graph for defs.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define NULL   ((void *)0)
 
#define ALIGN(x, align)   (((x)+((align)-1))&~((align)-1))
 
#define PHYSADDR(a)   (((u32)(a)) & 0x1fffffff)
 
#define KSEG1   0xa0000000
 
#define KSEG1ADDR(a)   ((__typeof__(a))(((u32)(a) & 0x1fffffff) | KSEG1))
 
#define USE_GP_REGISTER   1
 
#define SetModuleGP()   ChangeGP(&_gp)
 

Functions

static __inline__ void SetGP (void *gp)
 
static __inline__ void * GetGP (void)
 
static __inline__ void * ChangeGP (void *gp)
 
static void * iop_memcpy (void *dest, const void *src, int size)
 

Variables

void * _gp
 

Detailed Description

IOPkit standard definitions.

Definition in file defs.h.

Macro Definition Documentation

◆ NULL

#define NULL   ((void *)0)

Definition at line 26 of file defs.h.

◆ ALIGN

#define ALIGN (   x,
  align 
)    (((x)+((align)-1))&~((align)-1))

Definition at line 29 of file defs.h.

◆ PHYSADDR

#define PHYSADDR (   a)    (((u32)(a)) & 0x1fffffff)

Definition at line 31 of file defs.h.

◆ KSEG1

#define KSEG1   0xa0000000

Definition at line 33 of file defs.h.

◆ KSEG1ADDR

#define KSEG1ADDR (   a)    ((__typeof__(a))(((u32)(a) & 0x1fffffff) | KSEG1))

Definition at line 34 of file defs.h.

◆ USE_GP_REGISTER

#define USE_GP_REGISTER   1

Definition at line 37 of file defs.h.

◆ SetModuleGP

#define SetModuleGP ( )    ChangeGP(&_gp)

Definition at line 68 of file defs.h.

Function Documentation

◆ SetGP()

static __inline__ void SetGP ( void *  gp)
static

Definition at line 40 of file defs.h.

◆ GetGP()

static __inline__ void * GetGP ( void  )
static

Definition at line 50 of file defs.h.

◆ ChangeGP()

static __inline__ void * ChangeGP ( void *  gp)
static

Definition at line 58 of file defs.h.

◆ iop_memcpy()

static void * iop_memcpy ( void *  dest,
const void *  src,
int  size 
)
inlinestatic

Definition at line 70 of file defs.h.