diff options
Diffstat (limited to 'src/vendorcode/google/chromeos')
-rw-r--r-- | src/vendorcode/google/chromeos/Kconfig | 17 | ||||
-rw-r--r-- | src/vendorcode/google/chromeos/Makefile.inc | 1 | ||||
-rw-r--r-- | src/vendorcode/google/chromeos/chromeos.h | 10 | ||||
-rw-r--r-- | src/vendorcode/google/chromeos/dsm_calib.c | 39 |
4 files changed, 0 insertions, 67 deletions
diff --git a/src/vendorcode/google/chromeos/Kconfig b/src/vendorcode/google/chromeos/Kconfig index 868492062e..09796527a1 100644 --- a/src/vendorcode/google/chromeos/Kconfig +++ b/src/vendorcode/google/chromeos/Kconfig @@ -57,23 +57,6 @@ config CHROMEOS_USE_EC_WATCHDOG_FLAG help Use the AP watchdog flag stored in EC. -config CHROMEOS_DSM_CALIB - bool - default n - help - On some boards, there are calibrated parameters for Dynamic Speaker Management(DSM) - stored in VPD. Enable this config to read and parse these VPD values and write them - to ACPI DSD table in device driver. These parameters will be applied by kernel driver - through device property at boot. - -config CHROMEOS_DSM_PARAM_FILE_NAME - bool - default n - help - On some boards, there are different dsm parameter files for Dynamic Speaker - Management (DSM). Enable this config to assign dsm parameters file name in ACPI - SSDT table. Kernel driver uses this to load the DSM parameter file. - config CHROMEOS_CSE_BOARD_RESET_OVERRIDE bool default n diff --git a/src/vendorcode/google/chromeos/Makefile.inc b/src/vendorcode/google/chromeos/Makefile.inc index ce77194070..fbfd7a4e2f 100644 --- a/src/vendorcode/google/chromeos/Makefile.inc +++ b/src/vendorcode/google/chromeos/Makefile.inc @@ -8,7 +8,6 @@ ramstage-y += vpd_mac.c vpd_serialno.c vpd_calibration.c ramstage-$(CONFIG_CHROMEOS_DISABLE_PLATFORM_HIERARCHY_ON_RESUME) += tpm2.c ramstage-$(CONFIG_HAVE_REGULATORY_DOMAIN) += wrdd.c ramstage-$(CONFIG_USE_SAR) += sar.c -ramstage-$(CONFIG_CHROMEOS_DSM_CALIB) += dsm_calib.c ramstage-$(CONFIG_TPM_GOOGLE) += cr50_enable_update.c romstage-$(CONFIG_CHROMEOS_CSE_BOARD_RESET_OVERRIDE) += cse_board_reset.c diff --git a/src/vendorcode/google/chromeos/chromeos.h b/src/vendorcode/google/chromeos/chromeos.h index 98aa4faf9b..cab855d34e 100644 --- a/src/vendorcode/google/chromeos/chromeos.h +++ b/src/vendorcode/google/chromeos/chromeos.h @@ -27,16 +27,6 @@ void cbmem_add_vpd_calibration_data(void); void chromeos_set_me_hash(u32*, int); void chromeos_set_ramoops(void *ram_oops, size_t size); -/** - * get_dsm_calibration_from_key - Gets value related to DSM calibration from VPD - * @key: The key in RO_VPD. The valid prefix is "dsm_calib_". The valid keys are - * documented in https://chromeos.google.com/partner/dlm/docs/factory/vpd.html. - * @value: Output value. The value read from VPD parsed into uint64_t integer. - * - * Returns CB_SUCCESS on success or CB_ERR on failure. - */ -enum cb_err get_dsm_calibration_from_key(const char *key, uint64_t *value); - /* * Declaration for mainboards to use to generate ACPI-specific ChromeOS needs. */ diff --git a/src/vendorcode/google/chromeos/dsm_calib.c b/src/vendorcode/google/chromeos/dsm_calib.c deleted file mode 100644 index ad4291d776..0000000000 --- a/src/vendorcode/google/chromeos/dsm_calib.c +++ /dev/null @@ -1,39 +0,0 @@ -/* SPDX-License-Identifier: GPL-2.0-only */ - -#include <console/console.h> -#include <drivers/vpd/vpd.h> -#include <stdint.h> -#include <string.h> -#include <types.h> -#include <vendorcode/google/chromeos/chromeos.h> - -#define DSM_BUF_LEN 128 -#define DSM_PREFIX "dsm_calib_" - -enum cb_err get_dsm_calibration_from_key(const char *key, uint64_t *value) -{ - static char buf[DSM_BUF_LEN]; - char *ret; - long value_from_vpd; - - if (strncmp(key, DSM_PREFIX, strlen(DSM_PREFIX))) { - printk(BIOS_ERR, "got invalid dsm_calib key: %s\n", key); - return CB_ERR; - } - - ret = vpd_gets(key, buf, DSM_BUF_LEN, VPD_RO); - if (!ret) { - printk(BIOS_ERR, "failed to find key in VPD: %s\n", key); - return CB_ERR; - } - - value_from_vpd = atol(buf); - if (value_from_vpd <= 0) { - printk(BIOS_ERR, "got invalid dsm_calib from VPD: %ld\n", value_from_vpd); - return CB_ERR; - } - - *value = value_from_vpd; - - return CB_SUCCESS; -} |