Thread (61 messages) 61 messages, 10 authors, 2025-07-22

Re: [PATCH v3 15/28] i2c: core: Introduce i2c_get_adapter_physdev()

From: Andi Shyti <andi.shyti@kernel.org>
Date: 2025-07-22 14:04:35
Also in: imx, linux-acpi, linux-clk, linux-cxl, linux-devicetree, linux-i2c, linux-pci, linux-spi, lkml

Hi Herve,

On Fri, Jun 13, 2025 at 03:47:55PM +0200, Herve Codina wrote:
The physical device providing an I2C adapter is the device that calls
i2c_add_adapter() or variants and i2c_del_adapter().

Most of the time this physical device is the parent of the adapter
device.

Exceptions exist with i2c muxes. Indeed, in case of i2c muxes, the
parent of the mux adapter device points to the adapter device the mux is
connected to instead of the physical of this mux adapter.

Introduce i2c_get_adapter_physdev() and a new physdev field in the
adapter structure in order to ease the adapter physical device
retrieval.

Signed-off-by: Herve Codina <herve.codina@bootlin.com>
Makes sense to me,

Reviewed-by: Andi Shyti <andi.shyti@kernel.org>

Thanks,
Andi
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help