summaryrefslogtreecommitdiff
path: root/src/drivers/i2c/sx9324/Kconfig
diff options
context:
space:
mode:
authorVictor Ding <victording@google.com>2022-11-02 08:24:41 +0000
committerEric Lai <eric_lai@quanta.corp-partner.google.com>2022-11-09 07:51:57 +0000
commit20265b09dc6bbfb8c708accf6c0cf67f63cb79c3 (patch)
treea9ef6de1caa5c9ef0e132b2b1aa1a210c421d09a /src/drivers/i2c/sx9324/Kconfig
parentb4d71e1ab2010083f61e218a70abc0ec5803d08b (diff)
drivers/i2c/sx9324: Add support for Linux's SX9324 driver
SX9324 driver is updated per Linux's documentation found at https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/devicetree/bindings/iio/proximity/semtech,sx9324.yaml Supporting logic for the deprecated SX932x driver is hence guarded by DRIVERS_I2C_SX9324_SUPPORT_LEGACY_LINUX_DRIVER This patch by itself does not introduce functional changes to any board. The legacy SX932x Linux driver never reached upstream Linux and is only available in ChromeOS kernel fork of 4.4 and 5.4. Linux later accepted a different implementation named SX9324 and has been available since 5.4. Ideally all variants should adopt the new driver; however, during the transition phase, coreboot must support both drivers. It is better to have a single firmware build that can work with both Linux kernel drivers by specifying both sets of properties. Legacy driver support should be deleted once all variants finish migration. BUG=b:242662878 TEST=Dump ACPI SSDT then verify _DSD entries related to the legacy SX932x driver are identical w/ and w/o this patch (Tested on Craask and Nivviks) Change-Id: I42cd6841c3a270c242ed2e739db245e858eadb3b Signed-off-by: Victor Ding <victording@google.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/69192 Reviewed-by: Reka Norman <rekanorman@chromium.org> Reviewed-by: Tarun Tuli <taruntuli@google.com> Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Eric Lai <eric_lai@quanta.corp-partner.google.com>
Diffstat (limited to 'src/drivers/i2c/sx9324/Kconfig')
-rw-r--r--src/drivers/i2c/sx9324/Kconfig16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/drivers/i2c/sx9324/Kconfig b/src/drivers/i2c/sx9324/Kconfig
index 77f6967b7e..222ff8d476 100644
--- a/src/drivers/i2c/sx9324/Kconfig
+++ b/src/drivers/i2c/sx9324/Kconfig
@@ -4,3 +4,19 @@ config DRIVERS_I2C_SX9324
depends on HAVE_ACPI_TABLES
help
Board has a Semtech SX9324 proximity sensor.
+
+config DRIVERS_I2C_SX9324_SUPPORT_LEGACY_LINUX_DRIVER
+ bool
+ default n
+ depends on DRIVERS_I2C_SX9324
+ help
+ Board may use the legacy sx932x linux driver.
+ This option is mainly to ease migrating from the legacy driver to the
+ Linux one and should be deleted once all variants finish migration.
+ This driver never reached upstream Linux and is only available in
+ ChromeOS kernel fork of 4.4 and 5.4. Linux later accepted a different
+ implementation named SX9324 and has been available since 5.4.
+ Ideally all variants should adopt the new driver; however, during the
+ transition phase, coreboot must support both drivers. By selecting this
+ option, coreboot's SX9324 driver will specify all properties to work with
+ both Linux kernel drivers.