Skip to content

Commit 9881aac

Browse files
Wolfram SangAndi Shyti
authored andcommitted
i2c: octeon: reword according to newest specification
Change the wording of this driver wrt. the newest I2C v7 and SMBus 3.2 specifications and replace "master/slave" with more appropriate terms. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Reviewed-by: Andi Shyti <andi.shyti@kernel.org> Signed-off-by: Andi Shyti <andi.shyti@kernel.org>
1 parent 5a078b4 commit 9881aac

3 files changed

Lines changed: 6 additions & 6 deletions

File tree

drivers/i2c/busses/i2c-octeon-core.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -221,14 +221,14 @@ static int octeon_i2c_check_status(struct octeon_i2c *i2c, int final_read)
221221
case STAT_LOST_ARB_B0:
222222
return -EAGAIN;
223223

224-
/* Being addressed as slave, should back off & listen */
224+
/* Being addressed as local target, should back off & listen */
225225
case STAT_SLAVE_60:
226226
case STAT_SLAVE_70:
227227
case STAT_GENDATA_ACK:
228228
case STAT_GENDATA_NAK:
229229
return -EOPNOTSUPP;
230230

231-
/* Core busy as slave */
231+
/* Core busy as local target */
232232
case STAT_SLAVE_80:
233233
case STAT_SLAVE_88:
234234
case STAT_SLAVE_A0:
@@ -608,7 +608,7 @@ static int octeon_i2c_hlc_comp_write(struct octeon_i2c *i2c, struct i2c_msg *msg
608608
}
609609

610610
/**
611-
* octeon_i2c_xfer - The driver's master_xfer function
611+
* octeon_i2c_xfer - The driver's xfer function
612612
* @adap: Pointer to the i2c_adapter structure
613613
* @msgs: Pointer to the messages to be processed
614614
* @num: Length of the MSGS array

drivers/i2c/busses/i2c-octeon-core.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,8 +39,8 @@
3939
/* Controller command and status bits */
4040
#define TWSI_CTL_CE 0x80 /* High level controller enable */
4141
#define TWSI_CTL_ENAB 0x40 /* Bus enable */
42-
#define TWSI_CTL_STA 0x20 /* Master-mode start, HW clears when done */
43-
#define TWSI_CTL_STP 0x10 /* Master-mode stop, HW clears when done */
42+
#define TWSI_CTL_STA 0x20 /* Controller-mode start, HW clears when done */
43+
#define TWSI_CTL_STP 0x10 /* Controller-mode stop, HW clears when done */
4444
#define TWSI_CTL_IFLG 0x08 /* HW event, SW writes 0 to ACK */
4545
#define TWSI_CTL_AAK 0x04 /* Assert ACK */
4646

drivers/i2c/busses/i2c-octeon-platdrv.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ static u32 octeon_i2c_functionality(struct i2c_adapter *adap)
122122
}
123123

124124
static const struct i2c_algorithm octeon_i2c_algo = {
125-
.master_xfer = octeon_i2c_xfer,
125+
.xfer = octeon_i2c_xfer,
126126
.functionality = octeon_i2c_functionality,
127127
};
128128

0 commit comments

Comments
 (0)