xref: /linux/drivers/i2c/busses/i2c-pasemi-core.h (revision b4db9f840283caca0d904436f187ef56a9126eaa)
1 /* SPDX-License-Identifier: GPL-2.0 */
2 #include <linux/atomic.h>
3 #include <linux/clk.h>
4 #include <linux/delay.h>
5 #include <linux/device.h>
6 #include <linux/i2c.h>
7 #include <linux/i2c-smbus.h>
8 #include <linux/io.h>
9 #include <linux/kernel.h>
10 #include <linux/completion.h>
11 
12 #define PASEMI_HW_REV_PCI -1
13 
14 struct pasemi_smbus {
15 	struct device		*dev;
16 	struct i2c_adapter	 adapter;
17 	void __iomem		*ioaddr;
18 	unsigned int		 clk_div;
19 	int			 hw_rev;
20 	int			 use_irq;
21 	struct completion	 irq_completion;
22 };
23 
24 int pasemi_i2c_common_probe(struct pasemi_smbus *smbus);
25 
26 irqreturn_t pasemi_irq_handler(int irq, void *dev_id);
27