4 #define DEVNAME "usbmoschipeth.device"
6 #define DEVBASETYPEPTR struct NepEthDevBase *
10 AROS_UFP3(DEVBASETYPEPTR
, devInit
,
11 AROS_UFPA(DEVBASETYPEPTR
, base
, D0
),
12 AROS_UFPA(BPTR
, seglist
, A0
),
13 AROS_UFPA(struct ExecBase
*, SysBase
, A6
));
15 AROS_LD3(DEVBASETYPEPTR
, devOpen
,
16 AROS_LDA(struct IOSana2Req
*, ioreq
, A1
),
17 AROS_LDA(ULONG
, unitnum
, D0
),
18 AROS_LDA(ULONG
, flags
, D1
),
19 DEVBASETYPEPTR
, base
, 1, dev
);
21 AROS_LD1(BPTR
, devClose
,
22 AROS_LDA(struct IOSana2Req
*, ioreq
, A1
),
23 DEVBASETYPEPTR
, base
, 2, dev
);
25 AROS_LD1(BPTR
, devExpunge
,
26 AROS_LDA(DEVBASETYPEPTR
, extralh
, D0
),
27 DEVBASETYPEPTR
, base
, 3, dev
);
29 AROS_LD0(DEVBASETYPEPTR
, devReserved
,
30 DEVBASETYPEPTR
, base
, 4, dev
);
32 AROS_LD1(void, devBeginIO
,
33 AROS_LDA(struct IOSana2Req
*, ioreq
, A1
),
34 DEVBASETYPEPTR
, base
, 5, dev
);
36 AROS_LD1(LONG
, devAbortIO
,
37 AROS_LDA(struct IOSana2Req
*, ioreq
, A1
),
38 DEVBASETYPEPTR
, base
, 6, dev
);
42 #define deverror(ioerr,wireerr) (((wireerr) << 8) | ((ioerr) & 0xff))
44 /* Reply the iorequest with success
48 /* Magic cookie, don't set error fields & don't reply the ioreq
50 #define RC_DONTREPLY -1
52 struct Unit
*Open_Unit(struct IOSana2Req
*ioreq
,
54 struct NepEthDevBase
*base
);
55 void Close_Unit(struct NepEthDevBase
*base
, struct NepClassEth
*ncp
,
56 struct IOSana2Req
*ioreq
);
58 WORD
cmdNSDeviceQuery(struct NepClassEth
*ncp
, struct IOStdReq
*ioreq
);
60 LONG
AbortReq(struct NepClassEth
*ncp
, struct List
*list
, struct IOSana2Req
*ioreq
);
61 void TermIO(struct NepClassEth
*ncp
, struct IOSana2Req
*ioreq
);
62 void AbortList(struct NepClassEth
*ncp
, struct List
*list
, struct BufMan
*bufman
, WORD error
);
63 void AbortRW(struct NepClassEth
*ncp
, struct BufMan
*bufman
, WORD error
);
64 struct Sana2PacketTypeStats
* FindPacketTypeStats(struct NepClassEth
*ncp
, ULONG packettype
);
65 WORD
AddMCastRange(struct NepClassEth
*ncp
, struct IOSana2Req
*ioreq
, UBYTE
*lower
, UBYTE
*upper
);
66 WORD
DelMCastRange(struct NepClassEth
*ncp
, struct IOSana2Req
*ioreq
, UBYTE
*lower
, UBYTE
*upper
);
67 void UpdateMulticastHash(struct NepClassEth
*ncp
);
69 struct my_NSDeviceQueryResult
71 ULONG DevQueryFormat
; /* this is type 0 */
72 ULONG SizeAvailable
; /* bytes available */
73 UWORD DeviceType
; /* what the device does */
74 UWORD DeviceSubType
; /* depends on the main type */
75 const UWORD
*SupportedCommands
; /* 0 terminated list of cmd's */