aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/drivers/i2c/busses/i2c-designware-core.h
diff options
context:
space:
mode:
authorLucas De Marchi <lucas.demarchi@intel.com>2016-08-23 19:18:55 -0300
committerWolfram Sang <wsa@the-dreams.de>2016-08-26 00:42:15 +0200
commit63d0f0a6952a1a02bc4f116b7da7c7887e46efa3 (patch)
treeb74bd520f0884c407bc4bb078218af63f558aa03 /drivers/i2c/busses/i2c-designware-core.h
parenti2c: designware: add common functions for locking (diff)
downloadwireguard-linux-63d0f0a6952a1a02bc4f116b7da7c7887e46efa3.tar.xz
wireguard-linux-63d0f0a6952a1a02bc4f116b7da7c7887e46efa3.zip
i2c: designware: detect when dynamic tar update is possible
This adapter can be synthesized with dynamic tar update enabled or disabled. When enabled it is not necessary to disable the adapter to change the slave address in some situations, which saves some time per transaction. There is no direct register to know if this feature is enabled but we can do it indirectly by writing to the 10BIT_ADDR field in IC_CON: this field is read only when dynamic tar update is enabled. Signed-off-by: Lucas De Marchi <lucas.demarchi@intel.com> Signed-off-by: José Roberto de Souza <jose.souza@intel.com> Acked-by: Jarkko Nikula <jarkko.nikula@linux.intel.com> Tested-by: Christian Ruppert <christian.ruppert@alitech.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
Diffstat (limited to 'drivers/i2c/busses/i2c-designware-core.h')
-rw-r--r--drivers/i2c/busses/i2c-designware-core.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/i2c/busses/i2c-designware-core.h b/drivers/i2c/busses/i2c-designware-core.h
index 22bfbe147870..0d44d2ae7d4c 100644
--- a/drivers/i2c/busses/i2c-designware-core.h
+++ b/drivers/i2c/busses/i2c-designware-core.h
@@ -117,6 +117,7 @@ struct dw_i2c_dev {
int (*acquire_lock)(struct dw_i2c_dev *dev);
void (*release_lock)(struct dw_i2c_dev *dev);
bool pm_runtime_disabled;
+ bool dynamic_tar_update_enabled;
};
#define ACCESS_SWAP 0x00000001