aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/i2c.h
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>2019-12-23 06:59:19 -0500
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2019-12-23 06:59:19 -0500
commit749e4121d6ee7fd4495779730fbc6ae800d0317c (patch)
tree9270ebabd9e3b57ef0427495ec9228f52454b608 /include/linux/i2c.h
parenttty: serial: 21285: stop using the unused[] variable from struct uart_port (diff)
parentLinux 5.5-rc3 (diff)
downloadlinux-dev-749e4121d6ee7fd4495779730fbc6ae800d0317c.tar.xz
linux-dev-749e4121d6ee7fd4495779730fbc6ae800d0317c.zip
Merge 5.5-rc3 into tty-next
We need the tty/serial fixes in here as well. Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'include/linux/i2c.h')
-rw-r--r--include/linux/i2c.h12
1 files changed, 6 insertions, 6 deletions
diff --git a/include/linux/i2c.h b/include/linux/i2c.h
index d2f786706657..582ef05ec07e 100644
--- a/include/linux/i2c.h
+++ b/include/linux/i2c.h
@@ -300,6 +300,7 @@ struct i2c_driver {
* generic enough to hide second-sourcing and compatible revisions.
* @adapter: manages the bus segment hosting this I2C device
* @dev: Driver model device node for the slave.
+ * @init_irq: IRQ that was set at initialization
* @irq: indicates the IRQ generated by this device (if any)
* @detected: member of an i2c_driver.clients list or i2c-core's
* userspace_devices list
@@ -466,12 +467,6 @@ i2c_new_probed_device(struct i2c_adapter *adap,
/* Common custom probe functions */
extern int i2c_probe_func_quick_read(struct i2c_adapter *adap, unsigned short addr);
-/* For devices that use several addresses, use i2c_new_dummy() to make
- * client handles for the extra addresses.
- */
-extern struct i2c_client *
-i2c_new_dummy(struct i2c_adapter *adap, u16 address);
-
extern struct i2c_client *
i2c_new_dummy_device(struct i2c_adapter *adapter, u16 address);
@@ -856,6 +851,11 @@ extern void i2c_del_driver(struct i2c_driver *driver);
#define i2c_add_driver(driver) \
i2c_register_driver(THIS_MODULE, driver)
+static inline bool i2c_client_has_driver(struct i2c_client *client)
+{
+ return !IS_ERR_OR_NULL(client) && client->dev.driver;
+}
+
/* call the i2c_client->command() of all attached clients with
* the given arguments */
extern void i2c_clients_command(struct i2c_adapter *adap,