soc: j721e: Add processors info
authorLokesh Vutla <lokeshvutla@ti.com>
Thu, 22 Aug 2019 06:28:52 +0000 (11:58 +0530)
committerLokesh Vutla <lokeshvutla@ti.com>
Sun, 25 Aug 2019 03:14:04 +0000 (08:44 +0530)
Add Processors information for J721e devices.

Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
Makefile
common/socinfo.c
include/soc/j721e/j721e_processors_info.h [new file with mode: 0644]
soc/j721e/j721e_processors_info.c [new file with mode: 0644]

index deb28fd36e3493573a802ead3fee20c36e895ba3..0d711a5f306a8def063561fb3f1ffccf08ff6ab2 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -73,7 +73,8 @@ AM65XSOURCES =\
 
 J721ESOURCES =\
              soc/j721e/j721e_host_info.c \
-             soc/j721e/j721e_sec_proxy_info.c
+             soc/j721e/j721e_sec_proxy_info.c \
+             soc/j721e/j721e_processors_info.c
 
 COMMONOBJECTS= $(COMMONSOURCES:.c=.o)
 AM65XOBJECTS=  $(AM65XSOURCES:.c=.o)
index 880ebf97eec02926a7bd52dc169651719fba4422..b5182525530a587f2fad83a6786d6cfc9a12d021 100644 (file)
@@ -42,6 +42,7 @@
 #include <soc/am65x/am65x_processors_info.h>
 #include <soc/j721e/j721e_host_info.h>
 #include <soc/j721e/j721e_sec_proxy_info.h>
+#include <soc/j721e/j721e_processors_info.h>
 
 /* Assuming these addresses and definitions stay common across K3 devices */
 #define CTRLMMR_WKUP_JTAG_DEVICE_ID    0x43000018
@@ -105,6 +106,8 @@ static void j721e_init(void)
        sci_info->num_sp_threads[MAIN_SEC_PROXY] = J721E_MAIN_SEC_PROXY_THREADS;
        sci_info->sp_info[MCU_SEC_PROXY] = j721e_mcu_sp_info;
        sci_info->num_sp_threads[MCU_SEC_PROXY] = J721E_MCU_SEC_PROXY_THREADS;
+       sci_info->processors_info = j721e_processors_info;
+       sci_info->num_processors = J721E_MAX_PROCESSORS_IDS;
 }
 
 int soc_init(void)
diff --git a/include/soc/j721e/j721e_processors_info.h b/include/soc/j721e/j721e_processors_info.h
new file mode 100644 (file)
index 0000000..59c9af1
--- /dev/null
@@ -0,0 +1,44 @@
+/*
+ * SoC Processors Info
+ *
+ * Copyright (C) 2019 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 __J721E_PROCESSORS_INFO
+#define __J721E_PROCESSORS_INFO
+
+#include <stdio.h>
+#include <stdint.h>
+
+#define J721E_MAX_PROCESSORS_IDS       11
+
+extern struct ti_sci_processors_info j721e_processors_info[];
+#endif
diff --git a/soc/j721e/j721e_processors_info.c b/soc/j721e/j721e_processors_info.c
new file mode 100644 (file)
index 0000000..9e44f79
--- /dev/null
@@ -0,0 +1,50 @@
+/*
+ * SoC Processors Info
+ *
+ * Copyright (C) 2019 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_processors_info j721e_processors_info[] = {
+       [0] = {202, 2, 0x20, "A72SS0_CORE0"},
+       [1] = {203, 0, 0x21, "A72SS0_CORE1"},
+       [2] = {142, 0, 0x03, "C66SS0_CORE0"},
+       [3] = {143, 0, 0x04, "C66SS1_CORE0"},
+       [4] = {15, 0, 0x30, "C71SS0"},
+       [5] = {250, 0, 0x01, "MCU_R5FSS0_CORE0"},
+       [6] = {251, 0, 0x02, "MCU_R5FSS0_CORE1"},
+       [7] = {245, 0, 0x06, "R5FSS0_CORE0"},
+       [8] = {246, 0, 0x07, "R5FSS0_CORE1"},
+       [9] = {247, 0, 0x08, "R5FSS1_CORE0"},
+       [10] = {248, 0, 0x09, "R5FSS1_CORE1"},
+};