glados: Provide nau8825 platform data via _DSD

BUG=chrome-os-partner:41280
BRANCH=none
TEST=Audio jack insert/eject detection and headset buttons work
on glados with the nau8825 driver in chromeos-3.18 and the
staging kernel skl2.

Change-Id: I813a985b4a39249a2cdbe45117acbdb7710bfa29
Signed-off-by: Patrick Georgi <pgeorgi@chromium.org>
Original-Commit-Id: 7a5b3dafd407fea2376dff5c3dcde50dff4704fb
Original-Change-Id: Ic24a0c444761d0f3a35c268078e70d9aacca4c80
Original-Signed-off-by: Ben Zhang <benzh@chromium.org>
Original-Reviewed-on: https://chromium-review.googlesource.com/293610
Original-Reviewed-by: Anatol Pomazau <anatol@google.com>
Original-Reviewed-by: Duncan Laurie <dlaurie@chromium.org>
Reviewed-on: http://review.coreboot.org/11720
Tested-by: build bot (Jenkins)
Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
Reviewed-by: Martin Roth <martinroth@google.com>
This commit is contained in:
Ben Zhang 2015-08-04 22:02:53 -07:00 committed by Patrick Georgi
parent 4a399c2bae
commit 98a4431b99
1 changed files with 37 additions and 0 deletions

View File

@ -143,6 +143,43 @@ Scope (\_SB.PCI0.I2C4)
Name (_DDN, "NAU88L25 Codec") Name (_DDN, "NAU88L25 Codec")
Name (_UID, 1) Name (_UID, 1)
/*
* Add DT style bindings with _DSD
* Device property values are documented in kernel doc
* Documentation/devicetree/bindings/sound/nau8825.txt
*/
Name (_DSD, Package () {
ToUUID ("daffd814-6eba-4d8c-8a91-bc9bbf4aa301"),
Package () {
/* Enable jack detection via JKDET pin */
Package () {"nuvoton,jkdet-enable", 1},
/*
* JKDET pin is pulled up by R389 on board.
* JKDET pin polarity = active low
*/
Package () {"nuvoton,jkdet-polarity", 1},
/* VREF Impedance = 125 kOhm */
Package () {"nuvoton,vref-impedance", 2},
/* VDDA(1.8) * 1.53 = 2.754 */
Package () {"nuvoton,micbias-voltage", 6},
/*
* Setup 4 buttons impedance according to
* Android specification
*/
Package () {"nuvoton,sar-threshold-num", 4},
Package () {"nuvoton,sar-threshold",
Package () {0xc, 0x1e, 0x38, 0x60}},
Package () {"nuvoton,sar-hysteresis", 1},
/* VDDA for button impedance measurement */
Package () {"nuvoton,sar-voltage", 0},
/* 100ms short key press debounce */
Package () {"nuvoton,short-key-debounce", 2},
/* 2^(7+2) = 512 ms insert/eject debounce */
Package () {"nuvoton,jack-insert-debounce", 7},
Package () {"nuvoton,jack-eject-debounce", 7},
}
})
Name (_CRS, ResourceTemplate() Name (_CRS, ResourceTemplate()
{ {
I2cSerialBus ( I2cSerialBus (