Aaron Durbin (adurbin(a)chromium.org) just uploaded a new patch set to gerrit, which you can find at https://review.coreboot.org/15489
-gerrit
commit fe7c08f472749be2c3d500ef4c0237fd2d8dbdaf
Author: Aaron Durbin <adurbin(a)chromium.org>
Date: Tue Jun 28 15:36:01 2016 -0500
lib/nhlt: drop nhlt_soc_add_endpoint()
The nhlt_soc_add_endpoint() is no longer used. Drop its declaration.
Change-Id: I3b68471650a43c5faae44bde523abca7ba250a34
Signed-off-by: Aaron Durbin <adurbin(a)chromium.org>
---
src/include/nhlt.h | 10 ++--------
1 file changed, 2 insertions(+), 8 deletions(-)
diff --git a/src/include/nhlt.h b/src/include/nhlt.h
index 3300d43..17b7d11 100644
--- a/src/include/nhlt.h
+++ b/src/include/nhlt.h
@@ -45,7 +45,7 @@ struct nhlt_format_config;
* An example sequence:
*
* nhlt = nhlt_init()
- * ep = nhlt_soc_add_endpoint()
+ * ep = nhlt_add_endpoint()
* nhlt_endpoint_append_config(ep)
* nhlt_endpoint_add_formats(ep)
* nhlt_soc_serialize()
@@ -97,19 +97,13 @@ int nhlt_add_ssp_endpoints(struct nhlt *nhlt, int virtual_bus_id,
/*
* Add endpoint to NHLT object. Returns NULL on error.
*
- * Note that the SoC variant uses SoC-specifc types for the hardware interface
- * and device types. This is to allow the SoC code to validate its particular
- * device support for specific hardware interfaces.
- *
- * The more generic nhlt_add_endpoint() is called by the SoC code to provide
+ * generic nhlt_add_endpoint() is called by the SoC code to provide
* the specific assumptions/uses for NHLT for that platform. All fields
* are the NHLT enumerations found within this header file.
*/
struct nhlt_endpoint *nhlt_add_endpoint(struct nhlt *nhlt, int link_type,
int device_type, int dir,
uint16_t vid, uint16_t did);
-struct nhlt_endpoint *nhlt_soc_add_endpoint(struct nhlt *nhlt, int soc_hwintf,
- int soc_devtype, int dir);
/*
* Append blob of configuration to the endpoint proper. Returns 0 on
Aaron Durbin (adurbin(a)chromium.org) just uploaded a new patch set to gerrit, which you can find at https://review.coreboot.org/15490
-gerrit
commit aa237f2b45bd7204811e785a08837372cd3c2d87
Author: Aaron Durbin <adurbin(a)chromium.org>
Date: Tue Jun 28 15:41:07 2016 -0500
soc/intel/{common,skylake}: provide common NHLT SoC support
The nhlt_soc_serialize() and nhlt_soc_serialize_oem_overrides()
functions should be able to be levearaged on all Intel SoCs
which support NHLT. Therefore provide that functionality and
make skylake use it.
Change-Id: Ib5535cc874f2680ec22554cecaf97b09753cacd0
Signed-off-by: Aaron Durbin <adurbin(a)chromium.org>
---
src/soc/intel/common/Kconfig | 4 ++++
src/soc/intel/common/Makefile.inc | 1 +
src/soc/intel/common/nhlt.c | 41 +++++++++++++++++++++++++++++++++
src/soc/intel/skylake/Kconfig | 1 +
src/soc/intel/skylake/nhlt/Makefile.inc | 1 -
src/soc/intel/skylake/nhlt/nhlt.c | 41 ---------------------------------
6 files changed, 47 insertions(+), 42 deletions(-)
diff --git a/src/soc/intel/common/Kconfig b/src/soc/intel/common/Kconfig
index fdd8f04..776004b 100644
--- a/src/soc/intel/common/Kconfig
+++ b/src/soc/intel/common/Kconfig
@@ -99,4 +99,8 @@ config SOC_INTEL_COMMON_ACPI
bool
default n
+config SOC_INTEL_COMMON_NHLT
+ bool
+ default n
+
endif # SOC_INTEL_COMMON
diff --git a/src/soc/intel/common/Makefile.inc b/src/soc/intel/common/Makefile.inc
index 88d5fd2..e9ad508 100644
--- a/src/soc/intel/common/Makefile.inc
+++ b/src/soc/intel/common/Makefile.inc
@@ -20,6 +20,7 @@ ramstage-$(CONFIG_SOC_INTEL_COMMON_ACPI_WAKE_SOURCE) += acpi_wake_source.c
ramstage-y += vbt.c
ramstage-$(CONFIG_SOC_INTEL_COMMON_GFX_OPREGION) += opregion.c
ramstage-$(CONFIG_SOC_INTEL_COMMON_ACPI) += ./acpi/acpi.c
+ramstage-$(CONFIG_SOC_INTEL_COMMON_NHLT) += nhlt.c
smm-$(CONFIG_SOC_INTEL_COMMON_SMI) += smihandler.c
diff --git a/src/soc/intel/common/nhlt.c b/src/soc/intel/common/nhlt.c
new file mode 100644
index 0000000..d498152
--- /dev/null
+++ b/src/soc/intel/common/nhlt.c
@@ -0,0 +1,41 @@
+/*
+ * This file is part of the coreboot project.
+ *
+ * Copyright 2015 Google, Inc.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; version 2 of the License.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ */
+
+#include <cbmem.h>
+#include <nhlt.h>
+#include <soc/acpi.h>
+
+uintptr_t nhlt_soc_serialize(struct nhlt *nhlt, uintptr_t acpi_addr)
+{
+ return nhlt_soc_serialize_oem_overrides(nhlt, acpi_addr, NULL, NULL);
+}
+
+uintptr_t nhlt_soc_serialize_oem_overrides(struct nhlt *nhlt,
+ uintptr_t acpi_addr, const char *oem_id, const char *oem_table_id)
+{
+ global_nvs_t *gnvs;
+
+ gnvs = cbmem_find(CBMEM_ID_ACPI_GNVS);
+
+ if (gnvs == NULL)
+ return acpi_addr;
+
+ /* Update NHLT GNVS Data */
+ gnvs->nhla = (uintptr_t)acpi_addr;
+ gnvs->nhll = nhlt_current_size(nhlt);
+
+ return nhlt_serialize_oem_overrides(nhlt, acpi_addr,
+ oem_id, oem_table_id);
+}
diff --git a/src/soc/intel/skylake/Kconfig b/src/soc/intel/skylake/Kconfig
index a134d1c..6843cef 100644
--- a/src/soc/intel/skylake/Kconfig
+++ b/src/soc/intel/skylake/Kconfig
@@ -38,6 +38,7 @@ config CPU_SPECIFIC_OPTIONS
select SOC_INTEL_COMMON
select SOC_INTEL_COMMON_ACPI_WAKE_SOURCE
select SOC_INTEL_COMMON_LPSS_I2C
+ select SOC_INTEL_COMMON_NHLT
select SOC_INTEL_COMMON_RESET
select SMM_TSEG
select SMP
diff --git a/src/soc/intel/skylake/nhlt/Makefile.inc b/src/soc/intel/skylake/nhlt/Makefile.inc
index aff182c..e022482 100644
--- a/src/soc/intel/skylake/nhlt/Makefile.inc
+++ b/src/soc/intel/skylake/nhlt/Makefile.inc
@@ -1,4 +1,3 @@
-ramstage-y += nhlt.c
ramstage-y += dmic.c
ramstage-y += nau88l25.c
ramstage-y += max98357.c
diff --git a/src/soc/intel/skylake/nhlt/nhlt.c b/src/soc/intel/skylake/nhlt/nhlt.c
deleted file mode 100644
index d498152..0000000
--- a/src/soc/intel/skylake/nhlt/nhlt.c
+++ /dev/null
@@ -1,41 +0,0 @@
-/*
- * This file is part of the coreboot project.
- *
- * Copyright 2015 Google, Inc.
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- */
-
-#include <cbmem.h>
-#include <nhlt.h>
-#include <soc/acpi.h>
-
-uintptr_t nhlt_soc_serialize(struct nhlt *nhlt, uintptr_t acpi_addr)
-{
- return nhlt_soc_serialize_oem_overrides(nhlt, acpi_addr, NULL, NULL);
-}
-
-uintptr_t nhlt_soc_serialize_oem_overrides(struct nhlt *nhlt,
- uintptr_t acpi_addr, const char *oem_id, const char *oem_table_id)
-{
- global_nvs_t *gnvs;
-
- gnvs = cbmem_find(CBMEM_ID_ACPI_GNVS);
-
- if (gnvs == NULL)
- return acpi_addr;
-
- /* Update NHLT GNVS Data */
- gnvs->nhla = (uintptr_t)acpi_addr;
- gnvs->nhll = nhlt_current_size(nhlt);
-
- return nhlt_serialize_oem_overrides(nhlt, acpi_addr,
- oem_id, oem_table_id);
-}
Aaron Durbin (adurbin(a)chromium.org) just uploaded a new patch set to gerrit, which you can find at https://review.coreboot.org/15490
-gerrit
commit 27097e4baeacea8c0ed45f9be6226c862c61990f
Author: Aaron Durbin <adurbin(a)chromium.org>
Date: Tue Jun 28 15:41:07 2016 -0500
soc/intel/{common,skylake}: provide common NHLT SoC support
The nhlt_soc_serialize() and nhlt_soc_serialize_oem_overrides()
functions should be able to be levearaged on all Intel SoCs
which support NHLT. Therefore provide that functionality and
make skylake use it.
Change-Id: Ib5535cc874f2680ec22554cecaf97b09753cacd0
Signed-off-by: Aaron Durbin <adurbin(a)chromium.org>
---
src/soc/intel/common/Kconfig | 4 ++++
src/soc/intel/common/Makefile.inc | 1 +
src/soc/intel/common/nhlt.c | 41 +++++++++++++++++++++++++++++++++
src/soc/intel/skylake/Kconfig | 1 +
src/soc/intel/skylake/nhlt/Makefile.inc | 1 -
src/soc/intel/skylake/nhlt/nhlt.c | 41 ---------------------------------
6 files changed, 47 insertions(+), 42 deletions(-)
diff --git a/src/soc/intel/common/Kconfig b/src/soc/intel/common/Kconfig
index fdd8f04..776004b 100644
--- a/src/soc/intel/common/Kconfig
+++ b/src/soc/intel/common/Kconfig
@@ -99,4 +99,8 @@ config SOC_INTEL_COMMON_ACPI
bool
default n
+config SOC_INTEL_COMMON_NHLT
+ bool
+ default n
+
endif # SOC_INTEL_COMMON
diff --git a/src/soc/intel/common/Makefile.inc b/src/soc/intel/common/Makefile.inc
index 88d5fd2..e9ad508 100644
--- a/src/soc/intel/common/Makefile.inc
+++ b/src/soc/intel/common/Makefile.inc
@@ -20,6 +20,7 @@ ramstage-$(CONFIG_SOC_INTEL_COMMON_ACPI_WAKE_SOURCE) += acpi_wake_source.c
ramstage-y += vbt.c
ramstage-$(CONFIG_SOC_INTEL_COMMON_GFX_OPREGION) += opregion.c
ramstage-$(CONFIG_SOC_INTEL_COMMON_ACPI) += ./acpi/acpi.c
+ramstage-$(CONFIG_SOC_INTEL_COMMON_NHLT) += nhlt.c
smm-$(CONFIG_SOC_INTEL_COMMON_SMI) += smihandler.c
diff --git a/src/soc/intel/common/nhlt.c b/src/soc/intel/common/nhlt.c
new file mode 100644
index 0000000..d498152
--- /dev/null
+++ b/src/soc/intel/common/nhlt.c
@@ -0,0 +1,41 @@
+/*
+ * This file is part of the coreboot project.
+ *
+ * Copyright 2015 Google, Inc.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; version 2 of the License.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ */
+
+#include <cbmem.h>
+#include <nhlt.h>
+#include <soc/acpi.h>
+
+uintptr_t nhlt_soc_serialize(struct nhlt *nhlt, uintptr_t acpi_addr)
+{
+ return nhlt_soc_serialize_oem_overrides(nhlt, acpi_addr, NULL, NULL);
+}
+
+uintptr_t nhlt_soc_serialize_oem_overrides(struct nhlt *nhlt,
+ uintptr_t acpi_addr, const char *oem_id, const char *oem_table_id)
+{
+ global_nvs_t *gnvs;
+
+ gnvs = cbmem_find(CBMEM_ID_ACPI_GNVS);
+
+ if (gnvs == NULL)
+ return acpi_addr;
+
+ /* Update NHLT GNVS Data */
+ gnvs->nhla = (uintptr_t)acpi_addr;
+ gnvs->nhll = nhlt_current_size(nhlt);
+
+ return nhlt_serialize_oem_overrides(nhlt, acpi_addr,
+ oem_id, oem_table_id);
+}
diff --git a/src/soc/intel/skylake/Kconfig b/src/soc/intel/skylake/Kconfig
index a134d1c..6843cef 100644
--- a/src/soc/intel/skylake/Kconfig
+++ b/src/soc/intel/skylake/Kconfig
@@ -38,6 +38,7 @@ config CPU_SPECIFIC_OPTIONS
select SOC_INTEL_COMMON
select SOC_INTEL_COMMON_ACPI_WAKE_SOURCE
select SOC_INTEL_COMMON_LPSS_I2C
+ select SOC_INTEL_COMMON_NHLT
select SOC_INTEL_COMMON_RESET
select SMM_TSEG
select SMP
diff --git a/src/soc/intel/skylake/nhlt/Makefile.inc b/src/soc/intel/skylake/nhlt/Makefile.inc
index aff182c..e022482 100644
--- a/src/soc/intel/skylake/nhlt/Makefile.inc
+++ b/src/soc/intel/skylake/nhlt/Makefile.inc
@@ -1,4 +1,3 @@
-ramstage-y += nhlt.c
ramstage-y += dmic.c
ramstage-y += nau88l25.c
ramstage-y += max98357.c
diff --git a/src/soc/intel/skylake/nhlt/nhlt.c b/src/soc/intel/skylake/nhlt/nhlt.c
deleted file mode 100644
index d498152..0000000
--- a/src/soc/intel/skylake/nhlt/nhlt.c
+++ /dev/null
@@ -1,41 +0,0 @@
-/*
- * This file is part of the coreboot project.
- *
- * Copyright 2015 Google, Inc.
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; version 2 of the License.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- */
-
-#include <cbmem.h>
-#include <nhlt.h>
-#include <soc/acpi.h>
-
-uintptr_t nhlt_soc_serialize(struct nhlt *nhlt, uintptr_t acpi_addr)
-{
- return nhlt_soc_serialize_oem_overrides(nhlt, acpi_addr, NULL, NULL);
-}
-
-uintptr_t nhlt_soc_serialize_oem_overrides(struct nhlt *nhlt,
- uintptr_t acpi_addr, const char *oem_id, const char *oem_table_id)
-{
- global_nvs_t *gnvs;
-
- gnvs = cbmem_find(CBMEM_ID_ACPI_GNVS);
-
- if (gnvs == NULL)
- return acpi_addr;
-
- /* Update NHLT GNVS Data */
- gnvs->nhla = (uintptr_t)acpi_addr;
- gnvs->nhll = nhlt_current_size(nhlt);
-
- return nhlt_serialize_oem_overrides(nhlt, acpi_addr,
- oem_id, oem_table_id);
-}
Aaron Durbin (adurbin(a)chromium.org) just uploaded a new patch set to gerrit, which you can find at https://review.coreboot.org/15489
-gerrit
commit 05ae4ba9ecc5992e4bd36c6be93a0d1c007d1e36
Author: Aaron Durbin <adurbin(a)chromium.org>
Date: Tue Jun 28 15:36:01 2016 -0500
lib/nhlt: drop nhlt_soc_add_endpoint()
The nhlt_soc_add_endpoint() is no longer used. Drop its declaration.
Change-Id: I3b68471650a43c5faae44bde523abca7ba250a34
Signed-off-by: Aaron Durbin <adurbin(a)chromium.org>
---
src/include/nhlt.h | 10 ++--------
1 file changed, 2 insertions(+), 8 deletions(-)
diff --git a/src/include/nhlt.h b/src/include/nhlt.h
index 3300d43..17b7d11 100644
--- a/src/include/nhlt.h
+++ b/src/include/nhlt.h
@@ -45,7 +45,7 @@ struct nhlt_format_config;
* An example sequence:
*
* nhlt = nhlt_init()
- * ep = nhlt_soc_add_endpoint()
+ * ep = nhlt_add_endpoint()
* nhlt_endpoint_append_config(ep)
* nhlt_endpoint_add_formats(ep)
* nhlt_soc_serialize()
@@ -97,19 +97,13 @@ int nhlt_add_ssp_endpoints(struct nhlt *nhlt, int virtual_bus_id,
/*
* Add endpoint to NHLT object. Returns NULL on error.
*
- * Note that the SoC variant uses SoC-specifc types for the hardware interface
- * and device types. This is to allow the SoC code to validate its particular
- * device support for specific hardware interfaces.
- *
- * The more generic nhlt_add_endpoint() is called by the SoC code to provide
+ * generic nhlt_add_endpoint() is called by the SoC code to provide
* the specific assumptions/uses for NHLT for that platform. All fields
* are the NHLT enumerations found within this header file.
*/
struct nhlt_endpoint *nhlt_add_endpoint(struct nhlt *nhlt, int link_type,
int device_type, int dir,
uint16_t vid, uint16_t did);
-struct nhlt_endpoint *nhlt_soc_add_endpoint(struct nhlt *nhlt, int soc_hwintf,
- int soc_devtype, int dir);
/*
* Append blob of configuration to the endpoint proper. Returns 0 on
the following patch was just integrated into master:
commit cbaa2abd6f5df9d97678920f1c3e78cad3614ace
Author: Saurabh Satija <saurabh.satija(a)intel.com>
Date: Tue Mar 8 17:33:29 2016 -0800
apollolake: Add ACPI device for audio controller
Add the audio controller device to ACPI and define the _DSM handler
to return the address of the NHLT table, if set in NVS.
Change-Id: I619dbfb562b94255e42a3e5d5a3926c28b14db3e
Signed-off-by: Saurabh Satija <saurabh.satija(a)intel.com>
Reviewed-on: https://review.coreboot.org/15026
Reviewed-by: Duncan Laurie <dlaurie(a)chromium.org>
Tested-by: build bot (Jenkins)
See https://review.coreboot.org/15026 for details.
-gerrit