Skip to content

Commit c9c593f

Browse files
urutvaPatater
authored andcommitted
tools: Remove obsolete API
The API is_PSA_non_secure_target() uses obsolete labels to detect if a target is PSA non-secure target and is not needed anymore. Mbed OS depends on TF-M for PSA SPM and services. TF-M is built using it's own build system. Therefore, we don't need to differentiate secure and non-secure targets anymore in Mbed OS as all PSA targets in Mbed OS are non-secure targets. Signed-off-by: Devaraj Ranganna <[email protected]>
1 parent 939ed69 commit c9c593f

File tree

3 files changed

+1
-14
lines changed

3 files changed

+1
-14
lines changed

tools/config/__init__.py

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -707,14 +707,6 @@ def _get_primary_memory_override(self, memory_type):
707707
)
708708
if hasattr(self.target, "mbed_{}_size".format(memory_type)):
709709
mem_size = getattr(self.target, "mbed_{}_size".format(memory_type))
710-
if self.target.is_PSA_non_secure_target:
711-
config, _ = self.get_config_data()
712-
mem_start = config.get(
713-
"target.non-secure-{}-start".format(memory_type), mem_start
714-
).value
715-
mem_size = config.get(
716-
"target.non-secure-{}-size".format(memory_type), mem_size
717-
).value
718710
if mem_start and not isinstance(mem_start, int):
719711
mem_start = int(mem_start, 0)
720712
if mem_size and not isinstance(mem_size, int):

tools/targets/PSOC6.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
#
22
# Copyright (c) 2017-2018 Future Electronics
33
# Copyright (c) 2018-2019 Cypress Semiconductor Corporation
4+
# Copyright (c) 2020 Arm Limited
45
#
56
# Licensed under the Apache License, Version 2.0 (the "License");
67
# you may not use this file except in compliance with the License.
@@ -134,8 +135,6 @@ def find_cm0_image(toolchain, resources, elf, hexf, hex_filename):
134135
from tools.resources import FileType
135136
hex_files = resources.get_file_paths(FileType.HEX)
136137
m0hexf = next((f for f in hex_files if os.path.basename(f) == hex_filename), None)
137-
if toolchain.target.is_PSA_non_secure_target:
138-
m0hexf = next((f for f in hex_files if os.path.basename(f) == os.path.basename(hexf)), m0hexf)
139138

140139
if m0hexf:
141140
toolchain.notify.info("M0 core image file found: %s." % m0hexf)

tools/targets/__init__.py

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -401,10 +401,6 @@ def is_TrustZone_non_secure_target(self):
401401
def is_TrustZone_target(self):
402402
return self.is_TrustZone_non_secure_target
403403

404-
@property
405-
def is_PSA_non_secure_target(self):
406-
return 'NSPE_Target' in self.labels
407-
408404
@property
409405
def is_PSA_target(self):
410406
return 'PSA' in self.features

0 commit comments

Comments
 (0)