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

Go to the source code of this file.

Macros

#define dev9_IMPORTS_start   DECLARE_IMPORT_TABLE(dev9, 1, 9)
 
#define dev9_IMPORTS_end   END_IMPORT_TABLE
 
#define I_SpdRegisterIntrHandler   DECLARE_IMPORT(4, SpdRegisterIntrHandler)
 
#define I_SpdDmaTransfer   DECLARE_IMPORT(5, SpdDmaTransfer)
 
#define I_Dev9CardStop   DECLARE_IMPORT(6, Dev9CardStop)
 
#define I_SpdIntrEnable   DECLARE_IMPORT(7, SpdIntrEnable)
 
#define I_SpdIntrDisable   DECLARE_IMPORT(8, SpdIntrDisable)
 
#define I_SpdGetEthernetID   DECLARE_IMPORT(9, SpdGetEthernetID)
 
#define I_SpdSetLED   DECLARE_IMPORT(10, SpdSetLED)
 
#define I_Dev9RegisterPowerOffHandler   DECLARE_IMPORT(11, Dev9RegisterPowerOffHandler)
 
#define I_dev9RegisterPreDmaCb   DECLARE_IMPORT(12, dev9RegisterPreDmaCb)
 
#define I_dev9RegisterPostDmaCb   DECLARE_IMPORT(13, dev9RegisterPostDmaCb)
 
#define I_dev9ControlPIO3   DECLARE_IMPORT(14, dev9ControlPIO3)
 
#define I_dev9LED2Ctl   DECLARE_IMPORT(15, dev9LED2Ctl)
 
#define dev9RegisterIntrCb   SpdRegisterIntrHandler
 
#define dev9DmaTransfer   SpdDmaTransfer
 
#define dev9Shutdown   Dev9CardStop
 
#define dev9IntrEnable   SpdIntrEnable
 
#define dev9IntrDisable   SpdIntrDisable
 
#define dev9GetEEPROM   SpdGetEthernetID
 
#define dev9LEDCtl   SpdSetLED
 
#define dev9RegisterShutdownCb   Dev9RegisterPowerOffHandler
 
#define I_dev9RegisterIntrCb   I_SpdRegisterIntrHandler
 
#define I_dev9DmaTransfer   I_SpdDmaTransfer
 
#define I_dev9Shutdown   I_Dev9CardStop
 
#define I_dev9IntrEnable   I_SpdIntrEnable
 
#define I_dev9IntrDisable   I_SpdIntrDisable
 
#define I_dev9GetEEPROM   I_SpdGetEthernetID
 
#define I_dev9LEDCtl   I_SpdSetLED
 
#define I_dev9RegisterShutdownCb   I_Dev9RegisterPowerOffHandler
 

Typedefs

typedef int(* dev9_intr_cb_t) (int flag)
 
typedef void(* dev9_shutdown_cb_t) (void)
 
typedef void(* dev9_dma_cb_t) (int bcr, int dir)
 

Functions

void SpdRegisterIntrHandler (int intr, dev9_intr_cb_t cb)
 
int SpdDmaTransfer (int ctrl, void *buf, int bcr, int dir)
 
void Dev9CardStop (void)
 
void SpdIntrEnable (int mask)
 
void SpdIntrDisable (int mask)
 
int SpdGetEthernetID (u16 *buf)
 
void SpdSetLED (int ctl)
 
void dev9LED2Ctl (int ctl)
 
void dev9ControlPIO3 (int ctl)
 
int Dev9RegisterPowerOffHandler (int idx, dev9_shutdown_cb_t cb)
 
void dev9RegisterPreDmaCb (int ctrl, dev9_dma_cb_t cb)
 
void dev9RegisterPostDmaCb (int ctrl, dev9_dma_cb_t cb)
 

Detailed Description

DEV9 Device Driver definitions and imports.

Definition in file dev9.h.

Macro Definition Documentation

◆ dev9_IMPORTS_start

#define dev9_IMPORTS_start   DECLARE_IMPORT_TABLE(dev9, 1, 9)

Definition at line 48 of file dev9.h.

◆ dev9_IMPORTS_end

#define dev9_IMPORTS_end   END_IMPORT_TABLE

Definition at line 49 of file dev9.h.

◆ I_SpdRegisterIntrHandler

#define I_SpdRegisterIntrHandler   DECLARE_IMPORT(4, SpdRegisterIntrHandler)

Definition at line 51 of file dev9.h.

◆ I_SpdDmaTransfer

#define I_SpdDmaTransfer   DECLARE_IMPORT(5, SpdDmaTransfer)

Definition at line 52 of file dev9.h.

◆ I_Dev9CardStop

#define I_Dev9CardStop   DECLARE_IMPORT(6, Dev9CardStop)

Definition at line 53 of file dev9.h.

◆ I_SpdIntrEnable

#define I_SpdIntrEnable   DECLARE_IMPORT(7, SpdIntrEnable)

Definition at line 54 of file dev9.h.

◆ I_SpdIntrDisable

#define I_SpdIntrDisable   DECLARE_IMPORT(8, SpdIntrDisable)

Definition at line 55 of file dev9.h.

◆ I_SpdGetEthernetID

#define I_SpdGetEthernetID   DECLARE_IMPORT(9, SpdGetEthernetID)

Definition at line 56 of file dev9.h.

◆ I_SpdSetLED

#define I_SpdSetLED   DECLARE_IMPORT(10, SpdSetLED)

Definition at line 57 of file dev9.h.

◆ I_Dev9RegisterPowerOffHandler

#define I_Dev9RegisterPowerOffHandler   DECLARE_IMPORT(11, Dev9RegisterPowerOffHandler)

Definition at line 58 of file dev9.h.

◆ I_dev9RegisterPreDmaCb

#define I_dev9RegisterPreDmaCb   DECLARE_IMPORT(12, dev9RegisterPreDmaCb)

Definition at line 59 of file dev9.h.

◆ I_dev9RegisterPostDmaCb

#define I_dev9RegisterPostDmaCb   DECLARE_IMPORT(13, dev9RegisterPostDmaCb)

Definition at line 60 of file dev9.h.

◆ I_dev9ControlPIO3

#define I_dev9ControlPIO3   DECLARE_IMPORT(14, dev9ControlPIO3)

Definition at line 61 of file dev9.h.

◆ I_dev9LED2Ctl

#define I_dev9LED2Ctl   DECLARE_IMPORT(15, dev9LED2Ctl)

Definition at line 62 of file dev9.h.

◆ dev9RegisterIntrCb

#define dev9RegisterIntrCb   SpdRegisterIntrHandler

Definition at line 66 of file dev9.h.

◆ dev9DmaTransfer

#define dev9DmaTransfer   SpdDmaTransfer

Definition at line 67 of file dev9.h.

◆ dev9Shutdown

#define dev9Shutdown   Dev9CardStop

Definition at line 68 of file dev9.h.

◆ dev9IntrEnable

#define dev9IntrEnable   SpdIntrEnable

Definition at line 69 of file dev9.h.

◆ dev9IntrDisable

#define dev9IntrDisable   SpdIntrDisable

Definition at line 70 of file dev9.h.

◆ dev9GetEEPROM

#define dev9GetEEPROM   SpdGetEthernetID

Definition at line 71 of file dev9.h.

◆ dev9LEDCtl

#define dev9LEDCtl   SpdSetLED

Definition at line 72 of file dev9.h.

◆ dev9RegisterShutdownCb

#define dev9RegisterShutdownCb   Dev9RegisterPowerOffHandler

Definition at line 73 of file dev9.h.

◆ I_dev9RegisterIntrCb

#define I_dev9RegisterIntrCb   I_SpdRegisterIntrHandler

Definition at line 75 of file dev9.h.

◆ I_dev9DmaTransfer

#define I_dev9DmaTransfer   I_SpdDmaTransfer

Definition at line 76 of file dev9.h.

◆ I_dev9Shutdown

#define I_dev9Shutdown   I_Dev9CardStop

Definition at line 77 of file dev9.h.

◆ I_dev9IntrEnable

#define I_dev9IntrEnable   I_SpdIntrEnable

Definition at line 78 of file dev9.h.

◆ I_dev9IntrDisable

#define I_dev9IntrDisable   I_SpdIntrDisable

Definition at line 79 of file dev9.h.

◆ I_dev9GetEEPROM

#define I_dev9GetEEPROM   I_SpdGetEthernetID

Definition at line 80 of file dev9.h.

◆ I_dev9LEDCtl

#define I_dev9LEDCtl   I_SpdSetLED

Definition at line 81 of file dev9.h.

◆ I_dev9RegisterShutdownCb

#define I_dev9RegisterShutdownCb   I_Dev9RegisterPowerOffHandler

Definition at line 82 of file dev9.h.

Typedef Documentation

◆ dev9_intr_cb_t

typedef int(* dev9_intr_cb_t) (int flag)

Definition at line 24 of file dev9.h.

◆ dev9_shutdown_cb_t

typedef void(* dev9_shutdown_cb_t) (void)

Definition at line 25 of file dev9.h.

◆ dev9_dma_cb_t

typedef void(* dev9_dma_cb_t) (int bcr, int dir)

Definition at line 26 of file dev9.h.

Function Documentation

◆ SpdRegisterIntrHandler()

void SpdRegisterIntrHandler ( int  intr,
dev9_intr_cb_t  cb 
)

Definition at line 23 of file acdev9.c.

◆ SpdDmaTransfer()

int SpdDmaTransfer ( int  ctrl,
void *  buf,
int  bcr,
int  dir 
)

Definition at line 32 of file acdev9.c.

◆ Dev9CardStop()

void Dev9CardStop ( void  )

Definition at line 43 of file acdev9.c.

◆ SpdIntrEnable()

void SpdIntrEnable ( int  mask)

Definition at line 50 of file acdev9.c.

◆ SpdIntrDisable()

void SpdIntrDisable ( int  mask)

Definition at line 58 of file acdev9.c.

◆ SpdGetEthernetID()

int SpdGetEthernetID ( u16 *  buf)

Definition at line 66 of file acdev9.c.

◆ SpdSetLED()

void SpdSetLED ( int  ctl)

Definition at line 74 of file acdev9.c.

◆ dev9LED2Ctl()

void dev9LED2Ctl ( int  ctl)

Definition at line 603 of file ps2dev9.c.

◆ dev9ControlPIO3()

void dev9ControlPIO3 ( int  ctl)

Definition at line 619 of file ps2dev9.c.

◆ Dev9RegisterPowerOffHandler()

int Dev9RegisterPowerOffHandler ( int  idx,
dev9_shutdown_cb_t  cb 
)

Definition at line 82 of file acdev9.c.

◆ dev9RegisterPreDmaCb()

void dev9RegisterPreDmaCb ( int  ctrl,
dev9_dma_cb_t  cb 
)

Definition at line 284 of file ps2dev9.c.

◆ dev9RegisterPostDmaCb()

void dev9RegisterPostDmaCb ( int  ctrl,
dev9_dma_cb_t  cb 
)

Definition at line 290 of file ps2dev9.c.