summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (from parent 1: d1b4488)
raw | patch | inline | side by side (from parent 1: d1b4488)
author | Lokesh Vutla <lokeshvutla@ti.com> | |
Fri, 10 Apr 2020 10:38:16 +0000 (16:08 +0530) | ||
committer | Lokesh Vutla <lokeshvutla@ti.com> | |
Wed, 15 Apr 2020 03:29:14 +0000 (08:59 +0530) |
Add TISCI Host Id information for AM65x sr2 devices. Data derived from
sysfw 2020.02 Documentation.
Also assign this data to sci_info based on SoC detection.
Tested-by: Dave Gerlach <d-gerlach@ti.com>
Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
sysfw 2020.02 Documentation.
Also assign this data to sci_info based on SoC detection.
Tested-by: Dave Gerlach <d-gerlach@ti.com>
Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
Makefile | patch | blob | history | |
common/socinfo.c | patch | blob | history | |
soc/am65x_sr2/am65x_sr2_host_info.c | [new file with mode: 0644] | patch | blob |
soc/am65x_sr2/am65x_sr2_host_info.h | [new file with mode: 0644] | patch | blob |
diff --git a/Makefile b/Makefile
index ef9e047461a9efe365c65c35eeda61a16a02ad7f..f4fec0c448f8857e06a9212a8132018a84245b9a 100644 (file)
--- a/Makefile
+++ b/Makefile
soc/am65x/am65x_sec_proxy_info.c \
soc/am65x/am65x_processors_info.c \
soc/am65x/am65x_devices_info.c \
- soc/am65x/am65x_clocks_info.c
+ soc/am65x/am65x_clocks_info.c \
+ soc/am65x_sr2/am65x_sr2_host_info.c
J721ESOURCES =\
soc/j721e/j721e_host_info.c \
diff --git a/common/socinfo.c b/common/socinfo.c
index ad35bdd24453b6934e5e7dd9e8f41bcc70b6f766..fb0cbaf8a9b0dc61150678407e1133653644a046 100644 (file)
--- a/common/socinfo.c
+++ b/common/socinfo.c
#include <soc/am65x/am65x_processors_info.h>
#include <soc/am65x/am65x_devices_info.h>
#include <soc/am65x/am65x_clocks_info.h>
+#include <soc/am65x_sr2/am65x_sr2_host_info.h>
#include <soc/j721e/j721e_host_info.h>
#include <soc/j721e/j721e_sec_proxy_info.h>
#include <soc/j721e/j721e_processors_info.h>
sci_info->num_clocks = AM65X_MAX_CLOCKS;
}
+static void am654_sr2_init(void)
+{
+ struct ti_sci_info *sci_info = &soc_info.sci_info;
+
+ sci_info->host_info = am65x_sr2_host_info;
+ sci_info->num_hosts = AM65X_SR2_MAX_HOST_IDS;
+}
+
static void j721e_init(void)
{
struct ti_sci_info *sci_info = &soc_info.sci_info;
soc_info.host_id = host_id;
- if (soc_info.soc == AM654)
+ if (soc_info.soc == AM654 && soc_info.rev == REV_SR1_0)
am654_init();
+ else if (soc_info.soc == AM654 && soc_info.rev == REV_SR2_0)
+ am654_sr2_init();
else if (soc_info.soc == J721E)
j721e_init();
diff --git a/soc/am65x_sr2/am65x_sr2_host_info.c b/soc/am65x_sr2/am65x_sr2_host_info.c
--- /dev/null
@@ -0,0 +1,57 @@
+/*
+ * AM65X_SR2 Hosts Info
+ *
+ * Copyright (C) 2020 Texas Instruments Incorporated - http://www.ti.com/
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ *
+ * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the
+ * distribution.
+ *
+ * Neither the name of Texas Instruments Incorporated nor the names of
+ * its contributors may be used to endorse or promote products derived
+ * from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#include <tisci.h>
+#include <socinfo.h>
+
+struct ti_sci_host_info am65x_sr2_host_info[] = {
+ [0] = {0, "DMSC", "Secure", "Device Management and Security Control"},
+ [1] = {3, "R5_0", "Non Secure", "Cortex R5 Context 0 on MCU island"},
+ [2] = {4, "R5_1", "Secure", "Cortex R5 Context 1 on MCU island(Boot)"},
+ [3] = {5, "R5_2", "Non Secure", "Cortex R5 Context 2 on MCU island"},
+ [4] = {6, "R5_3", "Secure", "Cortex R5 Context 3 on MCU island"},
+ [5] = {10, "A53_0", "Secure", "Cortex A53 context 0 on Main island"},
+ [6] = {11, "A53_1", "Secure", "Cortex A53 context 1 on Main island"},
+ [7] = {12, "A53_2", "Non Secure", "Cortex A53 context 2 on Main island"},
+ [8] = {13, "A53_3", "Non Secure", "Cortex A53 context 3 on Main island"},
+ [9] = {14, "A53_4", "Non Secure", "Cortex A53 context 4 on Main island"},
+ [10] = {15, "A53_5", "Non Secure", "Cortex A53 context 5 on Main island"},
+ [11] = {16, "A53_6", "Non Secure", "Cortex A53 context 6 on Main island"},
+ [12] = {17, "A53_7", "Non Secure", "Cortex A53 context 7 on Main island"},
+ [13] = {30, "GPU_0", "Non Secure", "SGX544 Context 0 on Main island"},
+ [14] = {31, "GPU_1", "Non Secure", "SGX544 Context 1 on Main island"},
+ [15] = {50, "ICSSG_0", "Non Secure", "ICSS Context 0 on Main island"},
+ [16] = {51, "ICSSG_1", "Non Secure", "ICSS Context 1 on Main island"},
+ [17] = {52, "ICSSG_2", "Non Secure", "ICSS Context 2 on Main island"},
+};
diff --git a/soc/am65x_sr2/am65x_sr2_host_info.h b/soc/am65x_sr2/am65x_sr2_host_info.h
--- /dev/null
@@ -0,0 +1,61 @@
+/*
+ * AM65X_SR2 Host Info
+ *
+ * Copyright (C) 2020 Texas Instruments Incorporated - http://www.ti.com/
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ *
+ * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the
+ * distribution.
+ *
+ * Neither the name of Texas Instruments Incorporated nor the names of
+ * its contributors may be used to endorse or promote products derived
+ * from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+ * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#ifndef __AM65X_SR2_HOST_INFO_H
+#define __AM65X_SR2_HOST_INFO_H
+
+#define AM65X_SR2_HOST_ID_DMSC 0
+#define AM65X_SR2_HOST_ID_R5_0 3
+#define AM65X_SR2_HOST_ID_R5_1 4
+#define AM65X_SR2_HOST_ID_R5_2 5
+#define AM65X_SR2_HOST_ID_R5_3 6
+#define AM65X_SR2_HOST_ID_A53_0 10
+#define AM65X_SR2_HOST_ID_A53_1 11
+#define AM65X_SR2_HOST_ID_A53_2 12
+#define AM65X_SR2_HOST_ID_A53_3 13
+#define AM65X_SR2_HOST_ID_A53_4 14
+#define AM65X_SR2_HOST_ID_A53_5 15
+#define AM65X_SR2_HOST_ID_A53_6 16
+#define AM65X_SR2_HOST_ID_A53_7 17
+#define AM65X_SR2_HOST_ID_GPU_0 30
+#define AM65X_SR2_HOST_ID_GPU_1 31
+#define AM65X_SR2_HOST_ID_ICSSG_0 50
+#define AM65X_SR2_HOST_ID_ICSSG_1 51
+#define AM65X_SR2_HOST_ID_ICSSG_2 52
+
+#define AM65X_SR2_MAX_HOST_IDS 18
+
+extern struct ti_sci_host_info am65x_sr2_host_info[];
+
+#endif /* __AM65X_SR2_HOST_INFO_H */
\ No newline at end of file