xref: /freebsd/sys/dev/io/iodev.h (revision d8b878873e7aa8df1972cc6a642804b17eb61087)
1*d8b87887SAttilio Rao /*-
2*d8b87887SAttilio Rao  * Copyright (c) 2010 Marcel Moolenaar
3*d8b87887SAttilio Rao  * All rights reserved.
4*d8b87887SAttilio Rao  *
5*d8b87887SAttilio Rao  * Redistribution and use in source and binary forms, with or without
6*d8b87887SAttilio Rao  * modification, are permitted provided that the following conditions
7*d8b87887SAttilio Rao  * are met:
8*d8b87887SAttilio Rao  * 1. Redistributions of source code must retain the above copyright
9*d8b87887SAttilio Rao  *    notice, this list of conditions and the following disclaimer.
10*d8b87887SAttilio Rao  * 2. Redistributions in binary form must reproduce the above copyright
11*d8b87887SAttilio Rao  *    notice, this list of conditions and the following disclaimer in the
12*d8b87887SAttilio Rao  *    documentation and/or other materials provided with the distribution.
13*d8b87887SAttilio Rao  *
14*d8b87887SAttilio Rao  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
15*d8b87887SAttilio Rao  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
16*d8b87887SAttilio Rao  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
17*d8b87887SAttilio Rao  * ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
18*d8b87887SAttilio Rao  * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
19*d8b87887SAttilio Rao  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
20*d8b87887SAttilio Rao  * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21*d8b87887SAttilio Rao  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22*d8b87887SAttilio Rao  * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23*d8b87887SAttilio Rao  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24*d8b87887SAttilio Rao  * SUCH DAMAGE.
25*d8b87887SAttilio Rao  *
26*d8b87887SAttilio Rao  * $FreeBSD$
27*d8b87887SAttilio Rao  */
28*d8b87887SAttilio Rao 
29*d8b87887SAttilio Rao #ifndef _DEV_IODEV_H_
30*d8b87887SAttilio Rao #define	_DEV_IODEV_H_
31*d8b87887SAttilio Rao 
32*d8b87887SAttilio Rao #define	IODEV_PIO_READ		0
33*d8b87887SAttilio Rao #define	IODEV_PIO_WRITE		1
34*d8b87887SAttilio Rao 
35*d8b87887SAttilio Rao struct iodev_pio_req {
36*d8b87887SAttilio Rao 	u_int access;
37*d8b87887SAttilio Rao 	u_int port;
38*d8b87887SAttilio Rao 	u_int width;
39*d8b87887SAttilio Rao 	u_int val;
40*d8b87887SAttilio Rao };
41*d8b87887SAttilio Rao 
42*d8b87887SAttilio Rao #define	IODEV_PIO	_IOWR('I', 0, struct iodev_pio_req)
43*d8b87887SAttilio Rao 
44*d8b87887SAttilio Rao #endif /* _DEV_IODEV_H_ */
45