Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge tag 'i2c-for-6.16-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux

Pull i2c fixes from Wolfram Sang:

- imx: fix SMBus protocol compliance during block read

- omap: fix error handling path in probe

- robotfuzz, tiny-usb: prevent zero-length reads

- x86, designware, amdisp: fix build error when modules are disabled
(agreed to go in via i2c)

- scx200_acb: fix build error because of missing HAS_IOPORT

* tag 'i2c-for-6.16-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux:
i2c: scx200_acb: depends on HAS_IOPORT
i2c: omap: Fix an error handling path in omap_i2c_probe()
platform/x86: Use i2c adapter name to fix build errors
i2c: amd-isp: Initialize unique adapter name
i2c: designware: Initialize adapter name only when not set
i2c: tiny-usb: disable zero-length read messages
i2c: robotfuzz-osif: disable zero-length read messages
i2c: imx: fix emulated smbus block read

+40 -7
+1
MAINTAINERS
··· 24099 24099 L: linux-i2c@vger.kernel.org 24100 24100 S: Maintained 24101 24101 F: drivers/i2c/busses/i2c-designware-amdisp.c 24102 + F: include/linux/soc/amd/isp4_misc.h 24102 24103 24103 24104 SYNOPSYS DESIGNWARE MMC/SD/SDIO DRIVER 24104 24105 M: Jaehoon Chung <jh80.chung@samsung.com>
+1 -1
drivers/i2c/busses/Kconfig
··· 1530 1530 1531 1531 config SCx200_ACB 1532 1532 tristate "Geode ACCESS.bus support" 1533 - depends on X86_32 && PCI 1533 + depends on X86_32 && PCI && HAS_IOPORT 1534 1534 help 1535 1535 Enable the use of the ACCESS.bus controllers on the Geode SCx200 and 1536 1536 SC1100 processors and the CS5535 and CS5536 Geode companion devices.
+2
drivers/i2c/busses/i2c-designware-amdisp.c
··· 8 8 #include <linux/module.h> 9 9 #include <linux/platform_device.h> 10 10 #include <linux/pm_runtime.h> 11 + #include <linux/soc/amd/isp4_misc.h> 11 12 12 13 #include "i2c-designware-core.h" 13 14 ··· 63 62 64 63 adap = &isp_i2c_dev->adapter; 65 64 adap->owner = THIS_MODULE; 65 + scnprintf(adap->name, sizeof(adap->name), AMDISP_I2C_ADAP_NAME); 66 66 ACPI_COMPANION_SET(&adap->dev, ACPI_COMPANION(&pdev->dev)); 67 67 adap->dev.of_node = pdev->dev.of_node; 68 68 /* use dynamically allocated adapter id */
+3 -2
drivers/i2c/busses/i2c-designware-master.c
··· 1042 1042 if (ret) 1043 1043 return ret; 1044 1044 1045 - snprintf(adap->name, sizeof(adap->name), 1046 - "Synopsys DesignWare I2C adapter"); 1045 + if (!adap->name[0]) 1046 + scnprintf(adap->name, sizeof(adap->name), 1047 + "Synopsys DesignWare I2C adapter"); 1047 1048 adap->retries = 3; 1048 1049 adap->algo = &i2c_dw_algo; 1049 1050 adap->quirks = &i2c_dw_quirks;
+2 -1
drivers/i2c/busses/i2c-imx.c
··· 1008 1008 /* setup bus to read data */ 1009 1009 temp = imx_i2c_read_reg(i2c_imx, IMX_I2C_I2CR); 1010 1010 temp &= ~I2CR_MTX; 1011 - if (i2c_imx->msg->len - 1) 1011 + if ((i2c_imx->msg->len - 1) || (i2c_imx->msg->flags & I2C_M_RECV_LEN)) 1012 1012 temp &= ~I2CR_TXAK; 1013 1013 1014 1014 imx_i2c_write_reg(temp, i2c_imx, IMX_I2C_I2CR); ··· 1063 1063 wake_up(&i2c_imx->queue); 1064 1064 } 1065 1065 i2c_imx->msg->len += len; 1066 + i2c_imx->msg->buf[i2c_imx->msg_buf_idx++] = len; 1066 1067 } 1067 1068 1068 1069 static irqreturn_t i2c_imx_master_isr(struct imx_i2c_struct *i2c_imx, unsigned int status)
+5 -2
drivers/i2c/busses/i2c-omap.c
··· 1461 1461 if (IS_ERR(mux_state)) { 1462 1462 r = PTR_ERR(mux_state); 1463 1463 dev_dbg(&pdev->dev, "failed to get I2C mux: %d\n", r); 1464 - goto err_disable_pm; 1464 + goto err_put_pm; 1465 1465 } 1466 1466 omap->mux_state = mux_state; 1467 1467 r = mux_state_select(omap->mux_state); 1468 1468 if (r) { 1469 1469 dev_err(&pdev->dev, "failed to select I2C mux: %d\n", r); 1470 - goto err_disable_pm; 1470 + goto err_put_pm; 1471 1471 } 1472 1472 } 1473 1473 ··· 1515 1515 1516 1516 err_unuse_clocks: 1517 1517 omap_i2c_write_reg(omap, OMAP_I2C_CON_REG, 0); 1518 + if (omap->mux_state) 1519 + mux_state_deselect(omap->mux_state); 1520 + err_put_pm: 1518 1521 pm_runtime_dont_use_autosuspend(omap->dev); 1519 1522 pm_runtime_put_sync(omap->dev); 1520 1523 err_disable_pm:
+6
drivers/i2c/busses/i2c-robotfuzz-osif.c
··· 111 111 return I2C_FUNC_I2C | I2C_FUNC_SMBUS_EMUL; 112 112 } 113 113 114 + /* prevent invalid 0-length usb_control_msg */ 115 + static const struct i2c_adapter_quirks osif_quirks = { 116 + .flags = I2C_AQ_NO_ZERO_LEN_READ, 117 + }; 118 + 114 119 static const struct i2c_algorithm osif_algorithm = { 115 120 .xfer = osif_xfer, 116 121 .functionality = osif_func, ··· 148 143 149 144 priv->adapter.owner = THIS_MODULE; 150 145 priv->adapter.class = I2C_CLASS_HWMON; 146 + priv->adapter.quirks = &osif_quirks; 151 147 priv->adapter.algo = &osif_algorithm; 152 148 priv->adapter.algo_data = priv; 153 149 snprintf(priv->adapter.name, sizeof(priv->adapter.name),
+6
drivers/i2c/busses/i2c-tiny-usb.c
··· 139 139 return ret; 140 140 } 141 141 142 + /* prevent invalid 0-length usb_control_msg */ 143 + static const struct i2c_adapter_quirks usb_quirks = { 144 + .flags = I2C_AQ_NO_ZERO_LEN_READ, 145 + }; 146 + 142 147 /* This is the actual algorithm we define */ 143 148 static const struct i2c_algorithm usb_algorithm = { 144 149 .xfer = usb_xfer, ··· 252 247 /* setup i2c adapter description */ 253 248 dev->adapter.owner = THIS_MODULE; 254 249 dev->adapter.class = I2C_CLASS_HWMON; 250 + dev->adapter.quirks = &usb_quirks; 255 251 dev->adapter.algo = &usb_algorithm; 256 252 dev->adapter.algo_data = dev; 257 253 snprintf(dev->adapter.name, sizeof(dev->adapter.name),
+2 -1
drivers/platform/x86/amd/amd_isp4.c
··· 11 11 #include <linux/mutex.h> 12 12 #include <linux/platform_device.h> 13 13 #include <linux/property.h> 14 + #include <linux/soc/amd/isp4_misc.h> 14 15 #include <linux/string.h> 15 16 #include <linux/types.h> 16 17 #include <linux/units.h> ··· 152 151 153 152 static inline bool is_isp_i2c_adapter(struct i2c_adapter *adap) 154 153 { 155 - return !strcmp(adap->owner->name, "i2c_designware_amdisp"); 154 + return !strcmp(adap->name, AMDISP_I2C_ADAP_NAME); 156 155 } 157 156 158 157 static void instantiate_isp_i2c_client(struct amdisp_platform *isp4_platform,
+12
include/linux/soc/amd/isp4_misc.h
··· 1 + // SPDX-License-Identifier: GPL-2.0+ 2 + 3 + /* 4 + * Copyright (C) 2025 Advanced Micro Devices, Inc. 5 + */ 6 + 7 + #ifndef __SOC_ISP4_MISC_H 8 + #define __SOC_ISP4_MISC_H 9 + 10 + #define AMDISP_I2C_ADAP_NAME "AMDISP DesignWare I2C adapter" 11 + 12 + #endif