0001 .. SPDX-License-Identifier: GPL-2.0
0002
0003 ==============
0004 ACPI I2C Muxes
0005 ==============
0006
0007 Describing an I2C device hierarchy that includes I2C muxes requires an ACPI
0008 Device () scope per mux channel.
0009
0010 Consider this topology::
0011
0012 +------+ +------+
0013 | SMB1 |-->| MUX0 |--CH00--> i2c client A (0x50)
0014 | | | 0x70 |--CH01--> i2c client B (0x50)
0015 +------+ +------+
0016
0017 which corresponds to the following ASL::
0018
0019 Device (SMB1)
0020 {
0021 Name (_HID, ...)
0022 Device (MUX0)
0023 {
0024 Name (_HID, ...)
0025 Name (_CRS, ResourceTemplate () {
0026 I2cSerialBus (0x70, ControllerInitiated, I2C_SPEED,
0027 AddressingMode7Bit, "^SMB1", 0x00,
0028 ResourceConsumer,,)
0029 }
0030
0031 Device (CH00)
0032 {
0033 Name (_ADR, 0)
0034
0035 Device (CLIA)
0036 {
0037 Name (_HID, ...)
0038 Name (_CRS, ResourceTemplate () {
0039 I2cSerialBus (0x50, ControllerInitiated, I2C_SPEED,
0040 AddressingMode7Bit, "^CH00", 0x00,
0041 ResourceConsumer,,)
0042 }
0043 }
0044 }
0045
0046 Device (CH01)
0047 {
0048 Name (_ADR, 1)
0049
0050 Device (CLIB)
0051 {
0052 Name (_HID, ...)
0053 Name (_CRS, ResourceTemplate () {
0054 I2cSerialBus (0x50, ControllerInitiated, I2C_SPEED,
0055 AddressingMode7Bit, "^CH01", 0x00,
0056 ResourceConsumer,,)
0057 }
0058 }
0059 }
0060 }
0061 }