Skip to content

Commit

Permalink
i2c: designware: Fix RX FIFO depth define on Wangxun 10Gb NIC
Browse files Browse the repository at this point in the history
[ Upstream commit c94612a ]

I believe RX FIFO depth define 0 is incorrect on Wangxun 10Gb NIC. It
must be at least 1 since code is able to read received data from the
DW_IC_DATA_CMD register.

For now this define is irrelevant since the txgbe_i2c_dw_xfer_quirk()
doesn't use the rx_fifo_depth member variable of struct dw_i2c_dev but
is needed when converting code into generic polling mode implementation.

Signed-off-by: Jarkko Nikula <jarkko.nikula@linux.intel.com>
Tested-by: Jiawen Wu <jiawenwu@trustnetic.com>
Signed-off-by: Andi Shyti <andi.shyti@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
  • Loading branch information
jhnikula authored and gregkh committed Apr 13, 2024
1 parent cd0a183 commit 30930f0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/i2c/busses/i2c-designware-core.h
Expand Up @@ -318,7 +318,7 @@ struct dw_i2c_dev {
#define AMD_UCSI_INTR_EN 0xd

#define TXGBE_TX_FIFO_DEPTH 4
#define TXGBE_RX_FIFO_DEPTH 0
#define TXGBE_RX_FIFO_DEPTH 1

struct i2c_dw_semaphore_callbacks {
int (*probe)(struct dw_i2c_dev *dev);
Expand Down

0 comments on commit 30930f0

Please sign in to comment.