PS2SDK
PS2 Homebrew Libraries
Loading...
Searching...
No Matches
netman_rpc.h
Go to the documentation of this file.
1
6#ifndef __NETMAN_RPC_H__
7#define __NETMAN_RPC_H__
8
9#include <tamtypes.h>
10#include <netman.h>
11
12#define NETMAN_RPC_NUMBER 0x00004239
13#define NETMAN_SIFCMD_ID 0x8000000D
14
15enum NETMAN_EE_RPC_FUNC_NUMS {
16 NETMAN_EE_RPC_FUNC_INIT = 0x00,
17 NETMAN_EE_RPC_FUNC_DEINIT,
18 NETMAN_EE_RPC_FUNC_HANDLE_PACKETS,
19 NETMAN_EE_RPC_FUNC_HANDLE_LINK_STATUS_CHANGE,
20};
21
22enum NETMAN_IOP_RPC_FUNC_NUMS {
23 NETMAN_IOP_RPC_FUNC_INIT = 0x00,
24 NETMAN_IOP_RPC_FUNC_DEINIT,
25 NETMAN_IOP_RPC_FUNC_REG_NETWORK_STACK,
26 NETMAN_IOP_RPC_FUNC_UNREG_NETWORK_STACK,
27 NETMAN_IOP_RPC_FUNC_IOCTL,
28 NETMAN_IOP_RPC_FUNC_SET_MAIN_NETIF,
29 NETMAN_IOP_RPC_FUNC_QUERY_MAIN_NETIF,
30 NETMAN_IOP_RPC_FUNC_SET_LINK_MODE,
31};
32
34{
35 s32 result;
36 struct NetManBD *FrameBufferStatus;
37};
38
40{
41 struct NetManBD *FrameBufferStatus;
42};
43
45{
46 s32 result;
47 void *FrameBuffer;
48 struct NetManBD *FrameBufferStatus;
49};
50
52{
53 s32 result;
54 char name[NETMAN_NETIF_NAME_MAX_LEN];
55};
56
57#define NETMAN_MAX_FRAME_SIZE 1536 // Maximum 1518 bytes, rounded up to nearest multiple of 16-byte units + 16 (for alignment)
58#define NETMAN_RPC_BLOCK_SIZE 64 // Small sizes will result in poorer performance and perhaps stability issues (due to resource exhaustion).
59
61{
62 u32 command;
63 u8 args[64];
64 u32 args_len;
65 void *output;
66 u32 length;
67};
68
70{
71 s32 result;
72 u8 output[64];
73};
74
76{
77 u8 id;
78 u8 offset; // For alignment correction on the EE (unused for IOP->EE).
79 u16 length;
80};
81
83{
84 u16 length; // When set to 0, buffer is available for use by MAC driver.
85 u16 offset; // For alignment correction on the EE (unused for IOP->EE).
86 void *packet; // Unused for EE->IOP.
87 void *payload; // Pointer to the data section of the packet. Unused for EE->IOP.
88 u32 unused;
89};
90
91#endif /* __NETMAN_RPC_H__ */