diff options
author | Lokesh Vutla | 2020-08-11 16:33:03 -0500 |
---|---|---|
committer | Dave Gerlach | 2020-08-14 12:11:07 -0500 |
commit | ce61f3b2f893d4cc08bc64332f2027d62133bbcb (patch) | |
tree | f8ac7f02a1dc943eba7bb8e819dbe390980a7e0a /soc | |
parent | 5ab440cacdd0ae62da3c06c28965f2fb520da113 (diff) | |
download | k3-image-gen-ce61f3b2f893d4cc08bc64332f2027d62133bbcb.tar.gz k3-image-gen-ce61f3b2f893d4cc08bc64332f2027d62133bbcb.tar.xz k3-image-gen-ce61f3b2f893d4cc08bc64332f2027d62133bbcb.zip |
soc: j7200: Add sysfw board config data
Add the following board configurations specific to j7200 SoC:
- board-cfg
- pm-cfg
- rm-cfg
- sec-cfg
Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
Signed-off-by: Nikhil Devshatwar <nikhil.nd@ti.com>
Diffstat (limited to 'soc')
-rw-r--r-- | soc/j7200/evm/board-cfg.c | 92 | ||||
-rw-r--r-- | soc/j7200/evm/pm-cfg.c | 43 | ||||
-rw-r--r-- | soc/j7200/evm/rm-cfg.c | 74 | ||||
-rw-r--r-- | soc/j7200/evm/sec-cfg.c | 93 | ||||
-rw-r--r-- | soc/j7200/evm/sysfw_img_cfg.h | 40 |
5 files changed, 342 insertions, 0 deletions
diff --git a/soc/j7200/evm/board-cfg.c b/soc/j7200/evm/board-cfg.c new file mode 100644 index 000000000..d5965236a --- /dev/null +++ b/soc/j7200/evm/board-cfg.c | |||
@@ -0,0 +1,92 @@ | |||
1 | /* | ||
2 | * K3 System Firmware Board Configuration Data | ||
3 | * | ||
4 | * Copyright (C) 2020 Texas Instruments Incorporated - https://www.ti.com/ | ||
5 | * | ||
6 | * Redistribution and use in source and binary forms, with or without | ||
7 | * modification, are permitted provided that the following conditions | ||
8 | * are met: | ||
9 | * | ||
10 | * Redistributions of source code must retain the above copyright | ||
11 | * notice, this list of conditions and the following disclaimer. | ||
12 | * | ||
13 | * Redistributions in binary form must reproduce the above copyright | ||
14 | * notice, this list of conditions and the following disclaimer in the | ||
15 | * documentation and/or other materials provided with the | ||
16 | * distribution. | ||
17 | * | ||
18 | * Neither the name of Texas Instruments Incorporated nor the names of | ||
19 | * its contributors may be used to endorse or promote products derived | ||
20 | * from this software without specific prior written permission. | ||
21 | * | ||
22 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS | ||
23 | * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT | ||
24 | * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR | ||
25 | * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT | ||
26 | * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, | ||
27 | * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT | ||
28 | * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, | ||
29 | * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY | ||
30 | * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | ||
31 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | ||
32 | * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | ||
33 | */ | ||
34 | |||
35 | #include "common.h" | ||
36 | |||
37 | const struct boardcfg j7200_boardcfg_data = { | ||
38 | /* boardcfg_abi_rev */ | ||
39 | .rev = { | ||
40 | .boardcfg_abi_maj = 0x0, | ||
41 | .boardcfg_abi_min = 0x1, | ||
42 | }, | ||
43 | |||
44 | /* boardcfg_control */ | ||
45 | .control = { | ||
46 | .subhdr = { | ||
47 | .magic = BOARDCFG_CONTROL_MAGIC_NUM, | ||
48 | .size = sizeof(struct boardcfg_control), | ||
49 | }, | ||
50 | .main_isolation_enable = 0x5A, | ||
51 | .main_isolation_hostid = 0x2, | ||
52 | }, | ||
53 | |||
54 | /* boardcfg sec_proxy */ | ||
55 | .secproxy = { | ||
56 | .subhdr = { | ||
57 | .magic = BOARDCFG_SECPROXY_MAGIC_NUM, | ||
58 | .size = sizeof(struct boardcfg_secproxy), | ||
59 | }, | ||
60 | .scaling_factor = 0x1, | ||
61 | .scaling_profile = 0x1, | ||
62 | .disable_main_nav_secure_proxy = 0, | ||
63 | }, | ||
64 | |||
65 | /* boardcfg_msmc */ | ||
66 | .msmc = { | ||
67 | .subhdr = { | ||
68 | .magic = BOARDCFG_MSMC_MAGIC_NUM, | ||
69 | .size = sizeof(struct boardcfg_msmc), | ||
70 | }, | ||
71 | .msmc_cache_size = 0x10, | ||
72 | }, | ||
73 | |||
74 | /* boardcfg_dbg_cfg */ | ||
75 | .debug_cfg = { | ||
76 | .subhdr = { | ||
77 | .magic = BOARDCFG_DBG_CFG_MAGIC_NUM, | ||
78 | .size = sizeof(struct boardcfg_dbg_cfg), | ||
79 | }, | ||
80 | #ifdef ENABLE_TRACE | ||
81 | .trace_dst_enables = BOARDCFG_TRACE_DST_UART0 | | ||
82 | BOARDCFG_TRACE_DST_ITM | | ||
83 | BOARDCFG_TRACE_DST_MEM, | ||
84 | .trace_src_enables = BOARDCFG_TRACE_SRC_PM | | ||
85 | BOARDCFG_TRACE_SRC_RM | | ||
86 | BOARDCFG_TRACE_SRC_SEC | | ||
87 | BOARDCFG_TRACE_SRC_BASE | | ||
88 | BOARDCFG_TRACE_SRC_USER | | ||
89 | BOARDCFG_TRACE_SRC_SUPR, | ||
90 | #endif | ||
91 | }, | ||
92 | }; | ||
diff --git a/soc/j7200/evm/pm-cfg.c b/soc/j7200/evm/pm-cfg.c new file mode 100644 index 000000000..778639423 --- /dev/null +++ b/soc/j7200/evm/pm-cfg.c | |||
@@ -0,0 +1,43 @@ | |||
1 | /* | ||
2 | * K3 System Firmware Power Management Configuration Data | ||
3 | * | ||
4 | * Copyright (C) 2020 Texas Instruments Incorporated - https://www.ti.com/ | ||
5 | * | ||
6 | * Redistribution and use in source and binary forms, with or without | ||
7 | * modification, are permitted provided that the following conditions | ||
8 | * are met: | ||
9 | * | ||
10 | * Redistributions of source code must retain the above copyright | ||
11 | * notice, this list of conditions and the following disclaimer. | ||
12 | * | ||
13 | * Redistributions in binary form must reproduce the above copyright | ||
14 | * notice, this list of conditions and the following disclaimer in the | ||
15 | * documentation and/or other materials provided with the | ||
16 | * distribution. | ||
17 | * | ||
18 | * Neither the name of Texas Instruments Incorporated nor the names of | ||
19 | * its contributors may be used to endorse or promote products derived | ||
20 | * from this software without specific prior written permission. | ||
21 | * | ||
22 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS | ||
23 | * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT | ||
24 | * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR | ||
25 | * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT | ||
26 | * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, | ||
27 | * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT | ||
28 | * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, | ||
29 | * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY | ||
30 | * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | ||
31 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | ||
32 | * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | ||
33 | */ | ||
34 | |||
35 | #include "common.h" | ||
36 | |||
37 | const struct boardcfg_pm j7200_boardcfg_pm_data = { | ||
38 | /* boardcfg_abi_rev */ | ||
39 | .rev = { | ||
40 | .boardcfg_abi_maj = 0x0, | ||
41 | .boardcfg_abi_min = 0x1, | ||
42 | }, | ||
43 | }; | ||
diff --git a/soc/j7200/evm/rm-cfg.c b/soc/j7200/evm/rm-cfg.c new file mode 100644 index 000000000..96d2270f6 --- /dev/null +++ b/soc/j7200/evm/rm-cfg.c | |||
@@ -0,0 +1,74 @@ | |||
1 | /* | ||
2 | * K3 System Firmware Resource Management Configuration Data | ||
3 | * | ||
4 | * Copyright (C) 2020 Texas Instruments Incorporated - https://www.ti.com/ | ||
5 | * | ||
6 | * Redistribution and use in source and binary forms, with or without | ||
7 | * modification, are permitted provided that the following conditions | ||
8 | * are met: | ||
9 | * | ||
10 | * Redistributions of source code must retain the above copyright | ||
11 | * notice, this list of conditions and the following disclaimer. | ||
12 | * | ||
13 | * Redistributions in binary form must reproduce the above copyright | ||
14 | * notice, this list of conditions and the following disclaimer in the | ||
15 | * documentation and/or other materials provided with the | ||
16 | * distribution. | ||
17 | * | ||
18 | * Neither the name of Texas Instruments Incorporated nor the names of | ||
19 | * its contributors may be used to endorse or promote products derived | ||
20 | * from this software without specific prior written permission. | ||
21 | * | ||
22 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS | ||
23 | * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT | ||
24 | * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR | ||
25 | * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT | ||
26 | * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, | ||
27 | * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT | ||
28 | * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, | ||
29 | * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY | ||
30 | * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | ||
31 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | ||
32 | * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | ||
33 | */ | ||
34 | |||
35 | #include "common.h" | ||
36 | #include <hosts.h> | ||
37 | #include <devices.h> | ||
38 | #include <resasg_types.h> | ||
39 | |||
40 | const struct boardcfg_rm_local j7200_boardcfg_rm_data = { | ||
41 | .rm_boardcfg = { | ||
42 | /* boardcfg_abi_rev */ | ||
43 | .rev = { | ||
44 | .boardcfg_abi_maj = 0x0, | ||
45 | .boardcfg_abi_min = 0x1, | ||
46 | }, | ||
47 | |||
48 | /* boardcfg_rm_host_cfg */ | ||
49 | .host_cfg = { | ||
50 | .subhdr = { | ||
51 | .magic = BOARDCFG_RM_HOST_CFG_MAGIC_NUM, | ||
52 | .size = sizeof (struct boardcfg_rm_host_cfg), | ||
53 | }, | ||
54 | .host_cfg_entries = {{0}}, | ||
55 | }, | ||
56 | |||
57 | /* boardcfg_rm_resasg */ | ||
58 | .resasg = { | ||
59 | .subhdr = { | ||
60 | .magic = BOARDCFG_RM_RESASG_MAGIC_NUM, | ||
61 | .size = sizeof (struct boardcfg_rm_resasg), | ||
62 | }, | ||
63 | .resasg_entries_size = | ||
64 | BOARDCFG_RM_RESASG_ENTRIES * | ||
65 | sizeof (struct boardcfg_rm_resasg_entry), | ||
66 | .reserved = 0, | ||
67 | /* .resasg_entries is set via boardcfg_rm_local */ | ||
68 | }, | ||
69 | }, | ||
70 | |||
71 | /* This is actually part of .resasg */ | ||
72 | .resasg_entries = { | ||
73 | }, | ||
74 | }; | ||
diff --git a/soc/j7200/evm/sec-cfg.c b/soc/j7200/evm/sec-cfg.c new file mode 100644 index 000000000..280f9296c --- /dev/null +++ b/soc/j7200/evm/sec-cfg.c | |||
@@ -0,0 +1,93 @@ | |||
1 | /* | ||
2 | * K3 System Firmware Security Configuration Data | ||
3 | * | ||
4 | * Copyright (C) 2020 Texas Instruments Incorporated - https://www.ti.com/ | ||
5 | * | ||
6 | * Redistribution and use in source and binary forms, with or without | ||
7 | * modification, are permitted provided that the following conditions | ||
8 | * are met: | ||
9 | * | ||
10 | * Redistributions of source code must retain the above copyright | ||
11 | * notice, this list of conditions and the following disclaimer. | ||
12 | * | ||
13 | * Redistributions in binary form must reproduce the above copyright | ||
14 | * notice, this list of conditions and the following disclaimer in the | ||
15 | * documentation and/or other materials provided with the | ||
16 | * distribution. | ||
17 | * | ||
18 | * Neither the name of Texas Instruments Incorporated nor the names of | ||
19 | * its contributors may be used to endorse or promote products derived | ||
20 | * from this software without specific prior written permission. | ||
21 | * | ||
22 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS | ||
23 | * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT | ||
24 | * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR | ||
25 | * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT | ||
26 | * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, | ||
27 | * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT | ||
28 | * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, | ||
29 | * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY | ||
30 | * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | ||
31 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | ||
32 | * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | ||
33 | */ | ||
34 | |||
35 | #include "common.h" | ||
36 | |||
37 | const struct boardcfg_security j7200_boardcfg_security_data = { | ||
38 | /* boardcfg_abi_rev */ | ||
39 | .rev = { | ||
40 | .boardcfg_abi_maj = 0x0, | ||
41 | .boardcfg_abi_min = 0x1, | ||
42 | }, | ||
43 | |||
44 | /* boardcfg_proc_acl */ | ||
45 | .processor_acl_list = { | ||
46 | .subhdr = { | ||
47 | .magic = BOARDCFG_PROC_ACL_MAGIC_NUM, | ||
48 | .size = sizeof(struct boardcfg_proc_acl), | ||
49 | }, | ||
50 | .proc_acl_entries = {{ 0 } }, | ||
51 | }, | ||
52 | |||
53 | /* boardcfg_host_hierarchy */ | ||
54 | .host_hierarchy = { | ||
55 | .subhdr = { | ||
56 | .magic = BOARDCFG_HOST_HIERARCHY_MAGIC_NUM, | ||
57 | .size = sizeof(struct boardcfg_host_hierarchy), | ||
58 | }, | ||
59 | .host_hierarchy_entries = {{ 0 } }, | ||
60 | }, | ||
61 | |||
62 | /* OTP access configuration */ | ||
63 | .otp_config = { | ||
64 | .subhdr = { | ||
65 | .magic = BOARDCFG_OTP_CFG_MAGIC_NUM, | ||
66 | .size = sizeof(struct boardcfg_extended_otp), | ||
67 | }, | ||
68 | /* Host ID 0 is DMSC. This means no host has write access to OTP array */ | ||
69 | .write_host_id = 0, | ||
70 | /* This is an array with 32 entries */ | ||
71 | .otp_entry = {{ 0 } }, | ||
72 | }, | ||
73 | |||
74 | /* DKEK configuration */ | ||
75 | .dkek_config = { | ||
76 | .subhdr = { | ||
77 | .magic = BOARDCFG_DKEK_CFG_MAGIC_NUM, | ||
78 | .size = sizeof(struct boardcfg_dkek), | ||
79 | }, | ||
80 | .allowed_hosts = { HOST_ID_ALL, 0, 0, 0 }, | ||
81 | .allow_dkek_export_tisci = 0x5A, | ||
82 | .rsvd = {0, 0, 0}, | ||
83 | }, | ||
84 | |||
85 | /* SA2UL configuration */ | ||
86 | .sa2ul_cfg = { | ||
87 | .subhdr = { | ||
88 | .magic = BOARDCFG_SA2UL_CFG_MAGIC_NUM_RSVD, | ||
89 | .size = 0, | ||
90 | }, | ||
91 | .rsvd = {0, 0, 0, 0}, | ||
92 | }, | ||
93 | }; | ||
diff --git a/soc/j7200/evm/sysfw_img_cfg.h b/soc/j7200/evm/sysfw_img_cfg.h new file mode 100644 index 000000000..93c90ecd5 --- /dev/null +++ b/soc/j7200/evm/sysfw_img_cfg.h | |||
@@ -0,0 +1,40 @@ | |||
1 | /* | ||
2 | * K3 System Firmware Configuration Data | ||
3 | * | ||
4 | * Copyright (C) 2020 Texas Instruments Incorporated - https://www.ti.com/ | ||
5 | * | ||
6 | * Redistribution and use in source and binary forms, with or without | ||
7 | * modification, are permitted provided that the following conditions | ||
8 | * are met: | ||
9 | * | ||
10 | * Redistributions of source code must retain the above copyright | ||
11 | * notice, this list of conditions and the following disclaimer. | ||
12 | * | ||
13 | * Redistributions in binary form must reproduce the above copyright | ||
14 | * notice, this list of conditions and the following disclaimer in the | ||
15 | * documentation and/or other materials provided with the | ||
16 | * distribution. | ||
17 | * | ||
18 | * Neither the name of Texas Instruments Incorporated nor the names of | ||
19 | * its contributors may be used to endorse or promote products derived | ||
20 | * from this software without specific prior written permission. | ||
21 | * | ||
22 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS | ||
23 | * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT | ||
24 | * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR | ||
25 | * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT | ||
26 | * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, | ||
27 | * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT | ||
28 | * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, | ||
29 | * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY | ||
30 | * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | ||
31 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | ||
32 | * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | ||
33 | */ | ||
34 | |||
35 | #ifndef SYSFW_IMG_CFG_H | ||
36 | #define SYSFW_IMG_CFG_H | ||
37 | |||
38 | #define BOARDCFG_RM_RESASG_ENTRIES 0 | ||
39 | |||
40 | #endif /* SYSFW_IMG_CFG_H */ | ||