summaryrefslogtreecommitdiff
path: root/src/mainboard/google/dedede
diff options
context:
space:
mode:
authorStanley Wu <stanley1.wu@lcfc.corp-partner.google.com>2020-12-30 20:59:53 +0800
committerKarthik Ramasubramanian <kramasub@google.com>2021-01-21 05:09:07 +0000
commit375d460f5f0d85cec588e6696fdeb644f57514e0 (patch)
treed286ecb095e5a9841c2e529545d7f3dfdcd56d31 /src/mainboard/google/dedede
parent68d19f83c39ff758a78883a4fa98e59ff330eb59 (diff)
mb/google/dedede/var/boten: Replace generic driver with sx9324 driver
Replace i2c driver for the SX9324 proximity detector device. This is first draft settings, will modify it after fine tuning. BUG=b:175932166 BRANCH=dedede TEST=run "i2cdump -y -f 15 0x28" to confirm registers as except. un-approach: => register address: 0x01 value: 0x00 approach: => register address: 0x01 value: 0x02 Change-Id: I0c8b5948266a07092799c6db556383fa08b924e6 Signed-off-by: Stanley Wu <stanley1.wu@lcfc.corp-partner.google.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/49018 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Karthik Ramasubramanian <kramasub@google.com>
Diffstat (limited to 'src/mainboard/google/dedede')
-rw-r--r--src/mainboard/google/dedede/Kconfig1
-rw-r--r--src/mainboard/google/dedede/variants/boten/overridetree.cb51
2 files changed, 49 insertions, 3 deletions
diff --git a/src/mainboard/google/dedede/Kconfig b/src/mainboard/google/dedede/Kconfig
index cb7eba4e63..69280025ee 100644
--- a/src/mainboard/google/dedede/Kconfig
+++ b/src/mainboard/google/dedede/Kconfig
@@ -7,6 +7,7 @@ config BOARD_GOOGLE_BASEBOARD_DEDEDE
select DRIVERS_I2C_GENERIC
select DRIVERS_I2C_GPIO_MUX
select DRIVERS_I2C_HID
+ select DRIVERS_I2C_SX9324
select DRIVERS_INTEL_DPTF
select DRIVERS_SPI_ACPI
select DRIVERS_USB_ACPI
diff --git a/src/mainboard/google/dedede/variants/boten/overridetree.cb b/src/mainboard/google/dedede/variants/boten/overridetree.cb
index ff7a4d6b3b..6c0fdd62d1 100644
--- a/src/mainboard/google/dedede/variants/boten/overridetree.cb
+++ b/src/mainboard/google/dedede/variants/boten/overridetree.cb
@@ -209,11 +209,56 @@ chip soc/intel/jasperlake
end
end # I2C 4
device pci 19.1 on
- chip drivers/i2c/generic
- register "hid" = ""STH9324""
- register "name" = ""SEMTECH SX9324""
+ chip drivers/i2c/sx9324
register "desc" = ""SAR Proximity Sensor""
register "irq" = "ACPI_IRQ_LEVEL_LOW(GPP_E11_IRQ)"
+ register "uid" = "2"
+ register "reg_gnrl_ctrl0" = "0x0a"
+ register "reg_gnrl_ctrl1" = "0x22"
+ register "reg_afe_ctrl0" = "0x20"
+ register "reg_afe_ctrl3" = "0x00"
+ register "reg_afe_ctrl4" = "0x47"
+ register "reg_afe_ctrl6" = "0x00"
+ register "reg_afe_ctrl7" = "0x47"
+ register "reg_afe_ctrl8" = "0x12"
+ register "reg_afe_ctrl9" = "0x08"
+ register "reg_afe_ph0" = "0x37"
+ register "reg_afe_ph1" = "0x10"
+ register "reg_afe_ph2" = "0x1f"
+ register "reg_afe_ph3" = "0x3d"
+ register "reg_prox_ctrl0" = "0x0b"
+ register "reg_prox_ctrl1" = "0x0b"
+ register "reg_prox_ctrl2" = "0x20"
+ register "reg_prox_ctrl3" = "0x20"
+ register "reg_prox_ctrl4" = "0x0c"
+ register "reg_prox_ctrl5" = "0x00"
+ register "reg_prox_ctrl6" = "0x1c"
+ register "reg_prox_ctrl7" = "0xc0"
+ register "reg_adv_ctrl0" = "0x00"
+ register "reg_adv_ctrl1" = "0x00"
+ register "reg_adv_ctrl2" = "0x00"
+ register "reg_adv_ctrl3" = "0x00"
+ register "reg_adv_ctrl4" = "0x00"
+ register "reg_adv_ctrl5" = "0x05"
+ register "reg_adv_ctrl6" = "0x00"
+ register "reg_adv_ctrl7" = "0x00"
+ register "reg_adv_ctrl8" = "0x00"
+ register "reg_adv_ctrl9" = "0x00"
+ register "reg_adv_ctrl10" = "0x00"
+ register "reg_adv_ctrl11" = "0x00"
+ register "reg_adv_ctrl12" = "0x00"
+ register "reg_adv_ctrl13" = "0x00"
+ register "reg_adv_ctrl14" = "0x80"
+ register "reg_adv_ctrl15" = "0x0c"
+ register "reg_adv_ctrl16" = "0x04"
+ register "reg_adv_ctrl17" = "0x70"
+ register "reg_adv_ctrl18" = "0x20"
+ register "reg_adv_ctrl19" = "0x00"
+ register "reg_adv_ctrl20" = "0x00"
+ register "reg_irq_msk" = "0x6f"
+ register "reg_irq_cfg0" = "0x00"
+ register "reg_irq_cfg1" = "0x80"
+ register "reg_irq_cfg2" = "0x01"
device i2c 28 on end
end
end # I2C 5