lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20240322132619.6389-8-wsa+renesas@sang-engineering.com>
Date: Fri, 22 Mar 2024 14:25:00 +0100
From: Wolfram Sang <wsa+renesas@...g-engineering.com>
To: linux-i2c@...r.kernel.org
Cc: Wolfram Sang <wsa+renesas@...g-engineering.com>,
	Andi Shyti <andi.shyti@...nel.org>,
	Ray Jui <rjui@...adcom.com>,
	Scott Branden <sbranden@...adcom.com>,
	Broadcom internal kernel review list <bcm-kernel-feedback-list@...adcom.com>,
	linux-arm-kernel@...ts.infradead.org,
	linux-kernel@...r.kernel.org
Subject: [PATCH 07/64] i2c: bcm-iproc: reword according to newest specification

Match the wording of this driver wrt. the newest I2C v7, SMBus 3.2, I3C
specifications and replace "master/slave" with more appropriate terms.
They are also more specific because we distinguish now between a remote
entity ("client") and a local one ("target").

Signed-off-by: Wolfram Sang <wsa+renesas@...g-engineering.com>
---
 drivers/i2c/busses/i2c-bcm-iproc.c | 20 ++++++++++----------
 1 file changed, 10 insertions(+), 10 deletions(-)

diff --git a/drivers/i2c/busses/i2c-bcm-iproc.c b/drivers/i2c/busses/i2c-bcm-iproc.c
index e905734c26a0..3c68d4df029f 100644
--- a/drivers/i2c/busses/i2c-bcm-iproc.c
+++ b/drivers/i2c/busses/i2c-bcm-iproc.c
@@ -224,8 +224,8 @@ static void slave_rx_tasklet_fn(unsigned long);
 		| BIT(IS_S_TX_UNDERRUN_SHIFT) | BIT(IS_S_RX_FIFO_FULL_SHIFT)\
 		| BIT(IS_S_RX_THLD_SHIFT))
 
-static int bcm_iproc_i2c_reg_slave(struct i2c_client *slave);
-static int bcm_iproc_i2c_unreg_slave(struct i2c_client *slave);
+static int bcm_iproc_i2c_reg_target(struct i2c_client *slave);
+static int bcm_iproc_i2c_unreg_target(struct i2c_client *slave);
 static void bcm_iproc_i2c_enable_disable(struct bcm_iproc_i2c_dev *iproc_i2c,
 					 bool enable);
 
@@ -987,17 +987,17 @@ static uint32_t bcm_iproc_i2c_functionality(struct i2c_adapter *adap)
 
 	val = I2C_FUNC_I2C | I2C_FUNC_SMBUS_EMUL;
 
-	if (adap->algo->reg_slave)
+	if (adap->algo->reg_target)
 		val |= I2C_FUNC_SLAVE;
 
 	return val;
 }
 
 static struct i2c_algorithm bcm_iproc_algo = {
-	.master_xfer = bcm_iproc_i2c_xfer,
+	.xfer = bcm_iproc_i2c_xfer,
 	.functionality = bcm_iproc_i2c_functionality,
-	.reg_slave = bcm_iproc_i2c_reg_slave,
-	.unreg_slave = bcm_iproc_i2c_unreg_slave,
+	.reg_target = bcm_iproc_i2c_reg_target,
+	.unreg_target = bcm_iproc_i2c_unreg_target,
 };
 
 static const struct i2c_adapter_quirks bcm_iproc_i2c_quirks = {
@@ -1079,8 +1079,8 @@ static int bcm_iproc_i2c_probe(struct platform_device *pdev)
 		spin_lock_init(&iproc_i2c->idm_lock);
 
 		/* no slave support */
-		bcm_iproc_algo.reg_slave = NULL;
-		bcm_iproc_algo.unreg_slave = NULL;
+		bcm_iproc_algo.reg_target = NULL;
+		bcm_iproc_algo.unreg_target = NULL;
 	}
 
 	ret = bcm_iproc_i2c_init(iproc_i2c);
@@ -1191,7 +1191,7 @@ static const struct dev_pm_ops bcm_iproc_i2c_pm_ops = {
 	.resume_early = &bcm_iproc_i2c_resume
 };
 
-static int bcm_iproc_i2c_reg_slave(struct i2c_client *slave)
+static int bcm_iproc_i2c_reg_target(struct i2c_client *slave)
 {
 	struct bcm_iproc_i2c_dev *iproc_i2c = i2c_get_adapdata(slave->adapter);
 
@@ -1210,7 +1210,7 @@ static int bcm_iproc_i2c_reg_slave(struct i2c_client *slave)
 	return 0;
 }
 
-static int bcm_iproc_i2c_unreg_slave(struct i2c_client *slave)
+static int bcm_iproc_i2c_unreg_target(struct i2c_client *slave)
 {
 	u32 tmp;
 	struct bcm_iproc_i2c_dev *iproc_i2c = i2c_get_adapdata(slave->adapter);
-- 
2.43.0


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ