mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-11-15 08:14:15 +08:00
i2c-host fixes for v6.12-rc7
In designware an incorrect behavior has been fixes when concluding a transmission. Fixed return error value evaluation in the Mule multiplexer. -----BEGIN PGP SIGNATURE----- iIwEABYIADQWIQScDfrjQa34uOld1VLaeAVmJtMtbgUCZy5V7xYcYW5kaS5zaHl0 aUBrZXJuZWwub3JnAAoJENp4BWYm0y1uXX8A/1lNym7o2X4Ljei8GALbbXYtuJBd VNP+ARWZenH1QAgIAQDrNLIauSPNnFbD2RCm+mZGVlcY8I0JC7Fp6fOzOoEYCg== =shLT -----END PGP SIGNATURE----- Merge tag 'i2c-host-fixes-6.12-rc7' of git://git.kernel.org/pub/scm/linux/kernel/git/andi.shyti/linux into i2c/for-current i2c-host fixes for v6.12-rc7 In designware an incorrect behavior has been fixes when concluding a transmission. Fixed return error value evaluation in the Mule multiplexer.
This commit is contained in:
commit
547aad93e0
@ -524,7 +524,7 @@ err_release_lock:
|
||||
void __i2c_dw_disable(struct dw_i2c_dev *dev)
|
||||
{
|
||||
struct i2c_timings *t = &dev->timings;
|
||||
unsigned int raw_intr_stats;
|
||||
unsigned int raw_intr_stats, ic_stats;
|
||||
unsigned int enable;
|
||||
int timeout = 100;
|
||||
bool abort_needed;
|
||||
@ -532,9 +532,11 @@ void __i2c_dw_disable(struct dw_i2c_dev *dev)
|
||||
int ret;
|
||||
|
||||
regmap_read(dev->map, DW_IC_RAW_INTR_STAT, &raw_intr_stats);
|
||||
regmap_read(dev->map, DW_IC_STATUS, &ic_stats);
|
||||
regmap_read(dev->map, DW_IC_ENABLE, &enable);
|
||||
|
||||
abort_needed = raw_intr_stats & DW_IC_INTR_MST_ON_HOLD;
|
||||
abort_needed = (raw_intr_stats & DW_IC_INTR_MST_ON_HOLD) ||
|
||||
(ic_stats & DW_IC_STATUS_MASTER_HOLD_TX_FIFO_EMPTY);
|
||||
if (abort_needed) {
|
||||
if (!(enable & DW_IC_ENABLE_ENABLE)) {
|
||||
regmap_write(dev->map, DW_IC_ENABLE, DW_IC_ENABLE_ENABLE);
|
||||
|
@ -116,6 +116,7 @@
|
||||
#define DW_IC_STATUS_RFNE BIT(3)
|
||||
#define DW_IC_STATUS_MASTER_ACTIVITY BIT(5)
|
||||
#define DW_IC_STATUS_SLAVE_ACTIVITY BIT(6)
|
||||
#define DW_IC_STATUS_MASTER_HOLD_TX_FIFO_EMPTY BIT(7)
|
||||
|
||||
#define DW_IC_SDA_HOLD_RX_SHIFT 16
|
||||
#define DW_IC_SDA_HOLD_RX_MASK GENMASK(23, 16)
|
||||
|
@ -66,8 +66,8 @@ static int mule_i2c_mux_probe(struct platform_device *pdev)
|
||||
priv = i2c_mux_priv(muxc);
|
||||
|
||||
priv->regmap = dev_get_regmap(mux_dev->parent, NULL);
|
||||
if (IS_ERR(priv->regmap))
|
||||
return dev_err_probe(mux_dev, PTR_ERR(priv->regmap),
|
||||
if (!priv->regmap)
|
||||
return dev_err_probe(mux_dev, -ENODEV,
|
||||
"No parent i2c register map\n");
|
||||
|
||||
platform_set_drvdata(pdev, muxc);
|
||||
|
Loading…
Reference in New Issue
Block a user