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

Configure Feed

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

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

Pull i2c fixes from Wolfram Sang:

- sanitize more input parameters in the core (found by syzkaller)

- usual set of driver fixes (proper completion handling, applying
quirks, correct workqueue selection...)

- ID additions to simplify dependency handling

- new email address for Peter Rosin

* tag 'i2c-for-7.1-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux:
i2c: smbus: reject oversized block transfers in the common path
MAINTAINERS: Update mail for Peter Rosin
i2c: stub: Reject I2C block transfers with invalid length
i2c: Compare the return value of gpiod_get_direction against GPIO_LINE_DIRECTION_OUT
i2c: dev: prevent integer overflow in I2C_TIMEOUT ioctl
i2c: acpi: Add ELAN0678 to i2c_acpi_force_100khz_device_ids
dt-bindings: i2c: apple,i2c: Add t8122 compatible
i2c: stm32f7: reinit_completion() per transfer not per msg
dt-bindings: i2c: amlogic: Add compatible for T7 SOC
i2c: testunit: Replace system_long_wq with system_dfl_long_wq

+53 -29
+1
.mailmap
··· 682 682 Peter Hilber <peter.hilber@oss.qualcomm.com> <quic_philber@quicinc.com> 683 683 Peter Oruba <peter.oruba@amd.com> 684 684 Peter Oruba <peter@oruba.de> 685 + Peter Rosin <peda@lysator.liu.se> <peda@axentia.se> 685 686 Pierre-Louis Bossart <pierre-louis.bossart@linux.dev> <pierre-louis.bossart@linux.intel.com> 686 687 Pratyush Anand <pratyush.anand@gmail.com> <pratyush.anand@st.com> 687 688 Pratyush Yadav <pratyush@kernel.org> <ptyadav@amazon.de>
+9 -4
Documentation/devicetree/bindings/i2c/amlogic,meson6-i2c.yaml
··· 16 16 17 17 properties: 18 18 compatible: 19 - enum: 20 - - amlogic,meson6-i2c # Meson6, Meson8 and compatible SoCs 21 - - amlogic,meson-gxbb-i2c # GXBB and compatible SoCs 22 - - amlogic,meson-axg-i2c # AXG and compatible SoCs 19 + oneOf: 20 + - items: 21 + - enum: 22 + - amlogic,t7-i2c 23 + - const: amlogic,meson-axg-i2c 24 + - enum: 25 + - amlogic,meson6-i2c # Meson6, Meson8 and compatible SoCs 26 + - amlogic,meson-gxbb-i2c # GXBB and compatible SoCs 27 + - amlogic,meson-axg-i2c # AXG and compatible SoCs 23 28 24 29 reg: 25 30 maxItems: 1
+3 -1
Documentation/devicetree/bindings/i2c/apple,i2c.yaml
··· 22 22 compatible: 23 23 oneOf: 24 24 - items: 25 - - const: apple,t6020-i2c 25 + - enum: 26 + - apple,t6020-i2c 27 + - apple,t8122-i2c 26 28 - const: apple,t8103-i2c 27 29 - items: 28 30 - enum:
+11 -13
MAINTAINERS
··· 4299 4299 F: drivers/video/backlight/aw99706.c 4300 4300 4301 4301 AXENTIA ARM DEVICES 4302 - M: Peter Rosin <peda@axentia.se> 4303 4302 L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers) 4304 - S: Maintained 4303 + S: Orphan 4305 4304 F: arch/arm/boot/dts/microchip/at91-linea.dtsi 4306 4305 F: arch/arm/boot/dts/microchip/at91-natte.dtsi 4307 4306 F: arch/arm/boot/dts/microchip/at91-nattis-2-natte-2.dts 4308 4307 F: arch/arm/boot/dts/microchip/at91-tse850-3.dts 4309 4308 4310 4309 AXENTIA ASOC DRIVERS 4311 - M: Peter Rosin <peda@axentia.se> 4312 4310 L: linux-sound@vger.kernel.org 4313 - S: Maintained 4311 + S: Orphan 4314 4312 F: Documentation/devicetree/bindings/sound/axentia,* 4315 4313 F: sound/soc/atmel/tse850-pcm5142.c 4316 4314 ··· 12048 12050 F: drivers/i2c/busses/i2c-nvidia-gpu.c 12049 12051 12050 12052 I2C MUXES 12051 - M: Peter Rosin <peda@axentia.se> 12053 + M: Peter Rosin <peda@lysator.liu.se> 12052 12054 L: linux-i2c@vger.kernel.org 12053 12055 S: Maintained 12054 12056 F: Documentation/devicetree/bindings/i2c/i2c-arb* ··· 12449 12451 F: include/linux/iio/backend.h 12450 12452 12451 12453 IIO DIGITAL POTENTIOMETER DAC 12452 - M: Peter Rosin <peda@axentia.se> 12454 + M: Peter Rosin <peda@lysator.liu.se> 12453 12455 L: linux-iio@vger.kernel.org 12454 12456 S: Maintained 12455 12457 F: Documentation/ABI/testing/sysfs-bus-iio-dac-dpot-dac ··· 12457 12459 F: drivers/iio/dac/dpot-dac.c 12458 12460 12459 12461 IIO ENVELOPE DETECTOR 12460 - M: Peter Rosin <peda@axentia.se> 12462 + M: Peter Rosin <peda@lysator.liu.se> 12461 12463 L: linux-iio@vger.kernel.org 12462 12464 S: Maintained 12463 12465 F: Documentation/ABI/testing/sysfs-bus-iio-adc-envelope-detector ··· 12473 12475 F: drivers/iio/test/iio-test-gts.c 12474 12476 12475 12477 IIO MULTIPLEXER 12476 - M: Peter Rosin <peda@axentia.se> 12478 + M: Peter Rosin <peda@lysator.liu.se> 12477 12479 L: linux-iio@vger.kernel.org 12478 12480 S: Maintained 12479 12481 F: Documentation/devicetree/bindings/iio/multiplexer/io-channel-mux.yaml ··· 12504 12506 F: tools/iio/ 12505 12507 12506 12508 IIO UNIT CONVERTER 12507 - M: Peter Rosin <peda@axentia.se> 12509 + M: Peter Rosin <peda@lysator.liu.se> 12508 12510 L: linux-iio@vger.kernel.org 12509 12511 S: Maintained 12510 12512 F: Documentation/devicetree/bindings/iio/afe/current-sense-amplifier.yaml ··· 15720 15722 F: drivers/media/i2c/max96717.c 15721 15723 15722 15724 MAX9860 MONO AUDIO VOICE CODEC DRIVER 15723 - M: Peter Rosin <peda@axentia.se> 15725 + M: Peter Rosin <peda@lysator.liu.se> 15724 15726 L: linux-sound@vger.kernel.org 15725 15727 S: Maintained 15726 15728 F: Documentation/devicetree/bindings/sound/max9860.txt ··· 15935 15937 F: drivers/net/can/spi/mcp251xfd/ 15936 15938 15937 15939 MCP4018 AND MCP4531 MICROCHIP DIGITAL POTENTIOMETER DRIVERS 15938 - M: Peter Rosin <peda@axentia.se> 15940 + M: Peter Rosin <peda@lysator.liu.se> 15939 15941 L: linux-iio@vger.kernel.org 15940 15942 S: Maintained 15941 15943 F: Documentation/ABI/testing/sysfs-bus-iio-potentiometer-mcp4531 ··· 18240 18242 F: include/uapi/linux/mmc/ 18241 18243 18242 18244 MULTIPLEXER SUBSYSTEM 18243 - M: Peter Rosin <peda@axentia.se> 18245 + M: Peter Rosin <peda@lysator.liu.se> 18244 18246 S: Odd Fixes 18245 18247 F: Documentation/ABI/testing/sysfs-class-mux* 18246 18248 F: Documentation/devicetree/bindings/mux/ ··· 19349 19351 K: "nxp,tda998x" 19350 19352 19351 19353 NXP TFA9879 DRIVER 19352 - M: Peter Rosin <peda@axentia.se> 19354 + M: Peter Rosin <peda@lysator.liu.se> 19353 19355 L: linux-sound@vger.kernel.org 19354 19356 S: Maintained 19355 19357 F: Documentation/devicetree/bindings/sound/trivial-codec.yaml
+3 -3
drivers/i2c/busses/i2c-stm32f7.c
··· 895 895 f7_msg->result = 0; 896 896 f7_msg->stop = (i2c_dev->msg_id >= i2c_dev->msg_num - 1); 897 897 898 - reinit_completion(&i2c_dev->complete); 899 - 900 898 cr1 = readl_relaxed(base + STM32F7_I2C_CR1); 901 899 cr2 = readl_relaxed(base + STM32F7_I2C_CR2); 902 900 ··· 1726 1728 if (ret) 1727 1729 goto pm_free; 1728 1730 1731 + reinit_completion(&i2c_dev->complete); 1732 + 1729 1733 stm32f7_i2c_xfer_msg(i2c_dev, msgs); 1730 1734 1731 1735 if (!i2c_dev->atomic) ··· 2253 2253 snprintf(adap->name, sizeof(adap->name), "STM32F7 I2C(%pa)", 2254 2254 &res->start); 2255 2255 adap->owner = THIS_MODULE; 2256 - adap->timeout = 2 * HZ; 2256 + adap->timeout = 8 * HZ; 2257 2257 adap->retries = 3; 2258 2258 adap->algo = &stm32f7_i2c_algo; 2259 2259 adap->dev.parent = &pdev->dev;
+1
drivers/i2c/i2c-core-acpi.c
··· 371 371 * a 400KHz frequency. The root cause of the issue is not known. 372 372 */ 373 373 { "DLL0945", 0 }, 374 + { "ELAN0678", 0 }, 374 375 { "ELAN06FA", 0 }, 375 376 {} 376 377 };
+1 -2
drivers/i2c/i2c-core-base.c
··· 445 445 bri->set_scl = set_scl_gpio_value; 446 446 if (bri->sda_gpiod) { 447 447 bri->get_sda = get_sda_gpio_value; 448 - /* FIXME: add proper flag instead of '0' once available */ 449 - if (gpiod_get_direction(bri->sda_gpiod) == 0) 448 + if (gpiod_get_direction(bri->sda_gpiod) == GPIO_LINE_DIRECTION_OUT) 450 449 bri->set_sda = set_sda_gpio_value; 451 450 } 452 451 } else if (bri->recover_bus == i2c_generic_scl_recovery) {
+12
drivers/i2c/i2c-core-smbus.c
··· 566 566 if (res) 567 567 return res; 568 568 569 + /* Reject invalid caller-supplied block lengths before any 570 + * tracepoint or native smbus_xfer callback runs. 571 + */ 572 + if (data && 573 + (protocol == I2C_SMBUS_I2C_BLOCK_DATA || 574 + protocol == I2C_SMBUS_BLOCK_PROC_CALL || 575 + (protocol == I2C_SMBUS_BLOCK_DATA && 576 + read_write == I2C_SMBUS_WRITE)) && 577 + (data->block[0] == 0 || 578 + data->block[0] > I2C_SMBUS_BLOCK_MAX)) 579 + return -EINVAL; 580 + 569 581 /* If enabled, the following two tracepoints are conditional on 570 582 * read_write and protocol. 571 583 */
+5 -4
drivers/i2c/i2c-dev.c
··· 487 487 client->adapter->retries = arg; 488 488 break; 489 489 case I2C_TIMEOUT: 490 - if (arg > INT_MAX) 490 + /* 491 + * For historical reasons, user-space sets the timeout value in 492 + * units of 10 ms. 493 + */ 494 + if (arg > INT_MAX / 10) 491 495 return -EINVAL; 492 496 493 - /* For historical reasons, user-space sets the timeout 494 - * value in units of 10 ms. 495 - */ 496 497 client->adapter->timeout = msecs_to_jiffies(arg * 10); 497 498 break; 498 499 default:
+2 -2
drivers/i2c/i2c-slave-testunit.c
··· 15 15 #include <linux/module.h> 16 16 #include <linux/of.h> 17 17 #include <linux/slab.h> 18 - #include <linux/workqueue.h> /* FIXME: is system_long_wq the best choice? */ 18 + #include <linux/workqueue.h> 19 19 20 20 #define TU_VERSION_MAX_LENGTH 128 21 21 ··· 124 124 case I2C_SLAVE_STOP: 125 125 if (tu->reg_idx == TU_NUM_REGS) { 126 126 set_bit(TU_FLAG_IN_PROCESS, &tu->flags); 127 - queue_delayed_work(system_long_wq, &tu->worker, 127 + queue_delayed_work(system_dfl_long_wq, &tu->worker, 128 128 msecs_to_jiffies(10 * tu->regs[TU_REG_DELAY])); 129 129 } 130 130
+5
drivers/i2c/i2c-stub.c
··· 214 214 * We ignore banks here, because banked chips don't use I2C 215 215 * block transfers 216 216 */ 217 + if (data->block[0] == 0 || 218 + data->block[0] > I2C_SMBUS_BLOCK_MAX) { 219 + ret = -EINVAL; 220 + break; 221 + } 217 222 if (data->block[0] > 256 - command) /* Avoid overrun */ 218 223 data->block[0] = 256 - command; 219 224 len = data->block[0];