coreboot
coreboot is an Open Source project aimed at replacing the proprietary BIOS found in most computers.
nhlt.c
Go to the documentation of this file.
1
/* SPDX-License-Identifier: GPL-2.0-only */
2
3
#include <baseboard/variants.h>
4
#include <
console/console.h
>
5
#include <nhlt.h>
6
#include <soc/nhlt.h>
7
8
void
variant_nhlt_init
(
struct
nhlt
*
nhlt
)
9
{
10
/* 4 Channel DMIC array. */
11
if
(
nhlt_soc_add_dmic_array
(
nhlt
, 4))
12
printk
(
BIOS_ERR
,
"Couldn't add 4CH DMIC arrays.\n"
);
13
14
/* Dialog DA7219 Headset codec. */
15
if
(
nhlt_soc_add_da7219
(
nhlt
,
AUDIO_LINK_SSP1
))
16
printk
(
BIOS_ERR
,
"Couldn't add Dialog DA7219 codec.\n"
);
17
18
/* MAXIM Smart Amps for left and right speakers. */
19
if
(
nhlt_soc_add_max98373
(
nhlt
,
AUDIO_LINK_SSP0
))
20
printk
(
BIOS_ERR
,
"Couldn't add Maxim 98373 codec.\n"
);
21
}
22
23
void
variant_nhlt_oem_overrides
(
const
char
**oem_id,
const
char
**oem_table_id,
24
uint32_t
*oem_revision)
25
{
26
*oem_id =
"GOOGLE"
;
27
*oem_table_id =
"ATLASMAX"
;
28
*oem_revision = 0;
29
}
printk
#define printk(level,...)
Definition:
stdlib.h:16
console.h
BIOS_ERR
#define BIOS_ERR
BIOS_ERR - System in incomplete state.
Definition:
loglevel.h:72
variant_nhlt_oem_overrides
void __weak variant_nhlt_oem_overrides(const char **oem_id, const char **oem_table_id, uint32_t *oem_revision)
Definition:
nhlt.c:16
variant_nhlt_init
void __weak variant_nhlt_init(struct nhlt *nhlt)
Definition:
nhlt.c:7
AUDIO_LINK_SSP0
@ AUDIO_LINK_SSP0
Definition:
nhlt.h:15
AUDIO_LINK_SSP1
@ AUDIO_LINK_SSP1
Definition:
nhlt.h:16
nhlt_soc_add_da7219
int nhlt_soc_add_da7219(struct nhlt *nhlt, int hwlink)
Definition:
nhlt.c:232
nhlt_soc_add_dmic_array
int nhlt_soc_add_dmic_array(struct nhlt *nhlt, int num_channels)
Definition:
nhlt.c:168
nhlt_soc_add_max98373
int nhlt_soc_add_max98373(struct nhlt *nhlt, int hwlink)
Definition:
nhlt.c:253
uint32_t
unsigned int uint32_t
Definition:
stdint.h:14
nhlt
Definition:
nhlt.h:287
src
mainboard
google
poppy
variants
atlas
nhlt.c
Generated by
1.9.1