mb/google/rauru: Add NAU8318 support
NAU8318 supports beep function via GPIO control. Configure the GPIO pins and pass them to the payload. BUG=b:343143718 TEST=Verify beep function through CLI in depthcharge successfully. We can test with: firmware-shell: badusbbeep firmware-shell: devbeep Change-Id: I79277bc1947dab517dea5aba583c5b4e0ac81bc4 Signed-off-by: Amanda Huang <amanda_hwang@compal.corp-partner.google.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/84693 Reviewed-by: Yu-Ping Wu <yupingso@google.com> Reviewed-by: Yidi Lin <yidilin@google.com> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
This commit is contained in:
parent
d96cc8d2df
commit
ff0dcfb305
2 changed files with 6 additions and 0 deletions
|
|
@ -8,7 +8,9 @@
|
|||
void setup_chromeos_gpios(void)
|
||||
{
|
||||
gpio_output(GPIO_AP_FP_FW_UP_STRAP, 0);
|
||||
gpio_output(GPIO_BEEP_ON_OD, 0);
|
||||
gpio_output(GPIO_EN_PWR_FP, 0);
|
||||
gpio_output(GPIO_EN_SPKR, 0);
|
||||
gpio_output(GPIO_FP_RST_1V8_S3_L, 0);
|
||||
gpio_output(GPIO_XHCI_INIT_DONE, 0);
|
||||
}
|
||||
|
|
@ -17,6 +19,8 @@ void fill_lb_gpios(struct lb_gpios *gpios)
|
|||
{
|
||||
struct lb_gpio chromeos_gpios[] = {
|
||||
{ GPIO_XHCI_INIT_DONE.id, ACTIVE_HIGH, -1, "XHCI init done" },
|
||||
{ GPIO_EN_SPKR.id, ACTIVE_HIGH, -1, "speaker enable" },
|
||||
{ GPIO_BEEP_ON_OD.id, ACTIVE_HIGH, -1, "beep enable" },
|
||||
};
|
||||
lb_add_gpios(gpios, chromeos_gpios, ARRAY_SIZE(chromeos_gpios));
|
||||
}
|
||||
|
|
|
|||
|
|
@ -5,6 +5,8 @@
|
|||
|
||||
#include <soc/gpio.h>
|
||||
|
||||
#define GPIO_BEEP_ON_OD GPIO(PERIPHERAL_EN1)
|
||||
#define GPIO_EN_SPKR GPIO(PERIPHERAL_EN0)
|
||||
#define GPIO_XHCI_INIT_DONE GPIO(EINT28)
|
||||
#define GPIO_FP_RST_1V8_S3_L GPIO(EINT26)
|
||||
#define GPIO_AP_FP_FW_UP_STRAP GPIO(EINT27)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue