From 841227f99865aaaca336195550dd3ded49a66895 Mon Sep 17 00:00:00 2001 From: VNSL Durga Date: Wed, 5 Aug 2015 18:50:16 +0530 Subject: [PATCH] xilskey: Added new version v3_0 Modified tcl for adding macro in xparameters.h based on the processor.As support is being added for Ultrascale and hence supported processors are a9 and microblaze too, removed supported peripherals option in mld. Signed-off-by: VNSL Durga Reviewed-by: Harini Katakam --- lib/sw_services/xilskey/data/xilskey.mld | 6 ++++-- lib/sw_services/xilskey/data/xilskey.tcl | 19 +++++++++++++++++++ 2 files changed, 23 insertions(+), 2 deletions(-) diff --git a/lib/sw_services/xilskey/data/xilskey.mld b/lib/sw_services/xilskey/data/xilskey.mld index fd207bc1..6e7baa9f 100755 --- a/lib/sw_services/xilskey/data/xilskey.mld +++ b/lib/sw_services/xilskey/data/xilskey.mld @@ -35,6 +35,9 @@ # Ver Who Date Changes # ----- ---- -------- ----------------------------------------------- # 1.00a rpo 04/24/13 Initial Release +# 3.00 vns 31/07/15 Support is being added for Ultrascale and hence +# supported processors are a9 and microblaze too. +# so supported peripherals option has been removed. # ############################################################################## @@ -43,9 +46,8 @@ OPTION psf_version = 2.1; BEGIN LIBRARY xilskey OPTION copyfiles = all; OPTION REQUIRES_OS = (standalone); - OPTION SUPPORTED_PERIPHERALS = (ps7_cortexa9); OPTION APP_LINKER_FLAGS = "-Wl,--start-group,-lxilskey,-lxil,-lgcc,-lc,--end-group"; OPTION desc = "Xilinx Secure Key Library "; - OPTION VERSION = 2.1; + OPTION VERSION = 3.0; OPTION NAME = xilskey; END LIBRARY diff --git a/lib/sw_services/xilskey/data/xilskey.tcl b/lib/sw_services/xilskey/data/xilskey.tcl index b89cd857..ab4449c4 100755 --- a/lib/sw_services/xilskey/data/xilskey.tcl +++ b/lib/sw_services/xilskey/data/xilskey.tcl @@ -35,6 +35,8 @@ # Ver Who Date Changes # ----- ---- -------- ----------------------------------------------- # 1.00a rpo 04/25/13 Initial Release +# 3.00 vns 30/07/15 Added macro in xparameters.h based on the +# processor ############################################################################## #--------------------------------------------- @@ -66,6 +68,23 @@ proc execs_generate {libhandle} { proc xgen_opts_file {libhandle} { + set proc_instance [hsi::get_sw_processor]; + set hw_processor [common::get_property HW_INSTANCE $proc_instance] + + set proc_type [common::get_property IP_NAME [hsi::get_cells $hw_processor]]; + + set file_handle [::hsi::utils::open_include_file "xparameters.h"] + + puts $file_handle "\n/* Xilinx processor macro for Secure Library (Xilskey) */ " + if {$proc_type == "ps7_cortexa9"} { + puts $file_handle "\n#define XPAR_XSK_ARM_PLATFORM 1" + } + if {$proc_type == "microblaze"} { + puts $file_handle "\n#define XPAR_XSK_MICROBLAZE_PLATFORM 1" + } + + puts $file_handle "" + close $file_handle # Copy the include files to the include directory set srcdir [file join src include]