amigaio.h revision 1.1 1 1.1 is /*
2 1.1 is * $NetBSD: amigaio.h,v 1.1 1996/11/29 23:36:29 is Exp $
3 1.1 is *
4 1.1 is *
5 1.1 is * Copyright (c) 1996 Ignatios Souvatzis
6 1.1 is * All rights reserved.
7 1.1 is *
8 1.1 is * Redistribution and use in source and binary forms, with or without
9 1.1 is * modification, are permitted provided that the following conditions
10 1.1 is * are met:
11 1.1 is * 1. Redistributions of source code must retain the above copyright
12 1.1 is * notice, this list of conditions and the following disclaimer.
13 1.1 is * 2. Redistributions in binary form must reproduce the above copyright
14 1.1 is * notice, this list of conditions and the following disclaimer in the
15 1.1 is * documentation and/or other materials provided with the distribution.
16 1.1 is * 3. All advertising materials mentioning features or use of this software
17 1.1 is * must display the following acknowledgement:
18 1.1 is * This product includes software developed by Ignatios Souvatzis
19 1.1 is * for the NetBSD project.
20 1.1 is * 4. The name of the author may not be used to endorse or promote products
21 1.1 is * derived from this software without specific prior written permission
22 1.1 is *
23 1.1 is * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
24 1.1 is * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
25 1.1 is * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
26 1.1 is * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
27 1.1 is * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
28 1.1 is * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
29 1.1 is * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
30 1.1 is * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
31 1.1 is * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
32 1.1 is * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
33 1.1 is *
34 1.1 is */
35 1.1 is
36 1.1 is /*
37 1.1 is * This describes the IO parameter block used by many standard
38 1.1 is * Amiga OS device drivers.
39 1.1 is */
40 1.1 is #ifndef AMIGA_IO_H
41 1.1 is #define AMIGA_IO_H
42 1.1 is
43 1.1 is struct AmigaIO {
44 1.1 is u_int8_t dum0[28];
45 1.1 is u_int16_t cmd;
46 1.1 is u_int8_t flags;
47 1.1 is int8_t err;
48 1.1 is u_int32_t actual, /* transferred */
49 1.1 is length; /* please transfer this much */
50 1.1 is void *buf; /* data buffer */
51 1.1 is u_int32_t offset; /* offset for block devices */
52 1.1 is };
53 1.1 is
54 1.1 is struct TimerIO {
55 1.1 is u_int8_t dum0[28];
56 1.1 is u_int16_t cmd;
57 1.1 is u_int8_t flags;
58 1.1 is int8_t err;
59 1.1 is u_int32_t secs,
60 1.1 is usec;
61 1.1 is };
62 1.1 is
63 1.1 is /* flags */
64 1.1 is #define QuickIO 0x1
65 1.1 is
66 1.1 is /* commands */
67 1.1 is #define Cmd_Rst 0x1
68 1.1 is #define Cmd_Rd 0x2
69 1.1 is #define Cmd_Wr 0x3
70 1.1 is #define Cmd_Upd 0x4
71 1.1 is #define Cmd_Clr 0x5
72 1.1 is #define Cmd_Stp 0x6
73 1.1 is #define Cmd_Strt 0x7
74 1.1 is #define Cmd_Flsh 0x8
75 1.1 is
76 1.1 is #define Cmd_Addtimereq 0x9
77 1.1 is
78 1.1 is #endif /* AMIGA_IO_H */
79