xref: /dflybsd-src/sys/dev/drm/include/linux/i2c.h (revision ba55f2f542af67c1331fd80f611891b0a29f57bc)
1bdab7f26SFrançois Tigeot /*
2*ba55f2f5SFrançois Tigeot  * Copyright (c) 2013-2015 François Tigeot
3bdab7f26SFrançois Tigeot  * All rights reserved.
4bdab7f26SFrançois Tigeot  *
5bdab7f26SFrançois Tigeot  * Redistribution and use in source and binary forms, with or without
6bdab7f26SFrançois Tigeot  * modification, are permitted provided that the following conditions
7bdab7f26SFrançois Tigeot  * are met:
8bdab7f26SFrançois Tigeot  * 1. Redistributions of source code must retain the above copyright
9bdab7f26SFrançois Tigeot  *    notice unmodified, this list of conditions, and the following
10bdab7f26SFrançois Tigeot  *    disclaimer.
11bdab7f26SFrançois Tigeot  * 2. Redistributions in binary form must reproduce the above copyright
12bdab7f26SFrançois Tigeot  *    notice, this list of conditions and the following disclaimer in the
13bdab7f26SFrançois Tigeot  *    documentation and/or other materials provided with the distribution.
14bdab7f26SFrançois Tigeot  *
15bdab7f26SFrançois Tigeot  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
16bdab7f26SFrançois Tigeot  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
17bdab7f26SFrançois Tigeot  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
18bdab7f26SFrançois Tigeot  * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
19bdab7f26SFrançois Tigeot  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
20bdab7f26SFrançois Tigeot  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
21bdab7f26SFrançois Tigeot  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
22bdab7f26SFrançois Tigeot  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
23bdab7f26SFrançois Tigeot  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
24bdab7f26SFrançois Tigeot  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25bdab7f26SFrançois Tigeot  */
26bdab7f26SFrançois Tigeot 
27bdab7f26SFrançois Tigeot #ifndef _LINUX_I2C_H_
28bdab7f26SFrançois Tigeot #define _LINUX_I2C_H_
29bdab7f26SFrançois Tigeot 
301f9f5f06SFrançois Tigeot #include <sys/bus.h>
311f9f5f06SFrançois Tigeot #include <sys/bus_private.h>
321f9f5f06SFrançois Tigeot 
338c49d0deSFrançois Tigeot #include <linux/sched.h>
348c49d0deSFrançois Tigeot 
35*ba55f2f5SFrançois Tigeot #include <bus/iicbus/iic.h>
36*ba55f2f5SFrançois Tigeot #include <bus/iicbus/iiconf.h>
37*ba55f2f5SFrançois Tigeot #include "iicbus_if.h"
38*ba55f2f5SFrançois Tigeot 
39bdab7f26SFrançois Tigeot #define i2c_msg iic_msg
40bdab7f26SFrançois Tigeot 
416e29dde8SFrançois Tigeot #define I2C_M_RD	IIC_M_RD
42*ba55f2f5SFrançois Tigeot #define I2C_M_NOSTART	IIC_M_NOSTART
43*ba55f2f5SFrançois Tigeot 
44*ba55f2f5SFrançois Tigeot #define i2c_adapter	device
456e29dde8SFrançois Tigeot 
46bdab7f26SFrançois Tigeot #endif	/* _LINUX_I2C_H_ */
47