U-Boot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: macro.wave.z at gmail.com <macro.wave.z@gmail.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 1/6] ARMv8: LS1043A: change macro CONFIG_ARMV8_PSCI definition
Date: Tue, 27 Sep 2016 17:29:01 +0800	[thread overview]
Message-ID: <1474968546-8285-2-git-send-email-hongbo.zhang@nxp.com> (raw)
In-Reply-To: <1474968546-8285-1-git-send-email-hongbo.zhang@nxp.com>

From: Hongbo Zhang <hongbo.zhang@nxp.com>

NXP/Freescale uses macro CONFIG_ARMV8_PSCI to enable their private PSCI
implementation in PPA firmware, but this macro naming too generic, so this
patch replaces it with a specic one CONFIG_FSL_PPA_ARMV8_PSCI.
And this macro CONFIG_ARMV8_PSCI will be used for a generic PSCI for ARMv8
which will be added in following patchs.

Signed-off-by: Hongbo Zhang <hongbo.zhang@nxp.com>
---
 arch/arm/cpu/armv8/cpu-dt.c               | 2 +-
 arch/arm/cpu/armv8/fsl-layerscape/cpu.c   | 3 ++-
 arch/arm/cpu/armv8/fsl-layerscape/fdt.c   | 3 ++-
 arch/arm/cpu/armv8/sec_firmware.c         | 2 +-
 arch/arm/cpu/armv8/sec_firmware_asm.S     | 2 +-
 arch/arm/include/asm/armv8/sec_firmware.h | 2 +-
 arch/arm/lib/bootm-fdt.c                  | 2 +-
 arch/arm/lib/psci-dt.c                    | 2 +-
 include/configs/ls1043ardb.h              | 2 +-
 9 files changed, 11 insertions(+), 9 deletions(-)

diff --git a/arch/arm/cpu/armv8/cpu-dt.c b/arch/arm/cpu/armv8/cpu-dt.c
index 9ffb49c..659ec27 100644
--- a/arch/arm/cpu/armv8/cpu-dt.c
+++ b/arch/arm/cpu/armv8/cpu-dt.c
@@ -13,7 +13,7 @@
 int psci_update_dt(void *fdt)
 {
 #ifdef CONFIG_MP
-#if defined(CONFIG_ARMV8_PSCI)
+#if defined(CONFIG_FSL_PPA_ARMV8_PSCI)
 #ifdef CONFIG_ARMV8_SEC_FIRMWARE_SUPPORT
 	/*
 	 * If the PSCI in SEC Firmware didn't work, avoid to update the
diff --git a/arch/arm/cpu/armv8/fsl-layerscape/cpu.c b/arch/arm/cpu/armv8/fsl-layerscape/cpu.c
index 20be323..2929d45 100644
--- a/arch/arm/cpu/armv8/fsl-layerscape/cpu.c
+++ b/arch/arm/cpu/armv8/fsl-layerscape/cpu.c
@@ -379,7 +379,8 @@ int arch_early_init_r(void)
 #endif
 
 #ifdef CONFIG_MP
-#if defined(CONFIG_ARMV8_SEC_FIRMWARE_SUPPORT) && defined(CONFIG_ARMV8_PSCI)
+#if defined(CONFIG_ARMV8_SEC_FIRMWARE_SUPPORT) && \
+	defined(CONFIG_FSL_PPA_ARMV8_PSCI)
 	/* Check the psci version to determine if the psci is supported */
 	psci_ver = sec_firmware_support_psci_version();
 #endif
diff --git a/arch/arm/cpu/armv8/fsl-layerscape/fdt.c b/arch/arm/cpu/armv8/fsl-layerscape/fdt.c
index 40d6a76..7851d15 100644
--- a/arch/arm/cpu/armv8/fsl-layerscape/fdt.c
+++ b/arch/arm/cpu/armv8/fsl-layerscape/fdt.c
@@ -41,7 +41,8 @@ void ft_fixup_cpu(void *blob)
 	int addr_cells;
 	u64 val, core_id;
 	size_t *boot_code_size = &(__secondary_boot_code_size);
-#if defined(CONFIG_ARMV8_SEC_FIRMWARE_SUPPORT) && defined(CONFIG_ARMV8_PSCI)
+#if defined(CONFIG_ARMV8_SEC_FIRMWARE_SUPPORT) && \
+	defined(CONFIG_FSL_PPA_ARMV8_PSCI)
 	int node;
 	u32 psci_ver;
 
diff --git a/arch/arm/cpu/armv8/sec_firmware.c b/arch/arm/cpu/armv8/sec_firmware.c
index e21e199..488ad8a 100644
--- a/arch/arm/cpu/armv8/sec_firmware.c
+++ b/arch/arm/cpu/armv8/sec_firmware.c
@@ -199,7 +199,7 @@ __weak bool sec_firmware_is_valid(const void *sec_firmware_img)
 	return true;
 }
 
-#ifdef CONFIG_ARMV8_PSCI
+#ifdef CONFIG_FSL_PPA_ARMV8_PSCI
 /*
  * The PSCI_VERSION function is added from PSCI v0.2. When the PSCI
  * v0.1 received this function, the NOT_SUPPORTED (0xffff_ffff) error
diff --git a/arch/arm/cpu/armv8/sec_firmware_asm.S b/arch/arm/cpu/armv8/sec_firmware_asm.S
index 0c6a462..d4a26b4 100644
--- a/arch/arm/cpu/armv8/sec_firmware_asm.S
+++ b/arch/arm/cpu/armv8/sec_firmware_asm.S
@@ -41,7 +41,7 @@ WEAK(_sec_firmware_entry)
         ret
 ENDPROC(_sec_firmware_entry)
 
-#ifdef CONFIG_ARMV8_PSCI
+#ifdef CONFIG_FSL_PPA_ARMV8_PSCI
 ENTRY(_sec_firmware_support_psci_version)
 	mov	x0, 0x84000000
 	mov	x1, 0x0
diff --git a/arch/arm/include/asm/armv8/sec_firmware.h b/arch/arm/include/asm/armv8/sec_firmware.h
index eb68185..a4e144b 100644
--- a/arch/arm/include/asm/armv8/sec_firmware.h
+++ b/arch/arm/include/asm/armv8/sec_firmware.h
@@ -14,7 +14,7 @@
 int sec_firmware_init(const void *, u32 *, u32 *);
 int _sec_firmware_entry(const void *, u32 *, u32 *);
 bool sec_firmware_is_valid(const void *);
-#ifdef CONFIG_ARMV8_PSCI
+#ifdef CONFIG_FSL_PPA_ARMV8_PSCI
 unsigned int sec_firmware_support_psci_version(void);
 unsigned int _sec_firmware_support_psci_version(void);
 #endif
diff --git a/arch/arm/lib/bootm-fdt.c b/arch/arm/lib/bootm-fdt.c
index a517550..10a56e8 100644
--- a/arch/arm/lib/bootm-fdt.c
+++ b/arch/arm/lib/bootm-fdt.c
@@ -53,7 +53,7 @@ int arch_fixup_fdt(void *blob)
 		return ret;
 #endif
 
-#if defined(CONFIG_ARMV7_NONSEC) || defined(CONFIG_ARMV8_PSCI)
+#if defined(CONFIG_ARMV7_NONSEC) || defined(CONFIG_FSL_PPA_ARMV8_PSCI)
 	ret = psci_update_dt(blob);
 	if (ret)
 		return ret;
diff --git a/arch/arm/lib/psci-dt.c b/arch/arm/lib/psci-dt.c
index baf6d70..41e139e 100644
--- a/arch/arm/lib/psci-dt.c
+++ b/arch/arm/lib/psci-dt.c
@@ -16,7 +16,7 @@
 
 int fdt_psci(void *fdt)
 {
-#if defined(CONFIG_ARMV8_PSCI) || defined(CONFIG_ARMV7_PSCI)
+#if defined(CONFIG_FSL_PPA_ARMV8_PSCI) || defined(CONFIG_ARMV7_PSCI)
 	int nodeoff;
 	unsigned int psci_ver = 0;
 	int tmp;
diff --git a/include/configs/ls1043ardb.h b/include/configs/ls1043ardb.h
index 70ee046..e1307c6 100644
--- a/include/configs/ls1043ardb.h
+++ b/include/configs/ls1043ardb.h
@@ -12,7 +12,7 @@
 #if defined(CONFIG_FSL_LS_PPA)
 #define CONFIG_ARMV8_SEC_FIRMWARE_SUPPORT
 #define SEC_FIRMWARE_ERET_ADDR_REVERT
-#define CONFIG_ARMV8_PSCI
+#define CONFIG_FSL_PPA_ARMV8_PSCI
 
 #define CONFIG_SYS_LS_PPA_FW_IN_XIP
 #ifdef CONFIG_SYS_LS_PPA_FW_IN_XIP
-- 
2.1.4

  reply	other threads:[~2016-09-27  9:29 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-09-27  9:29 [U-Boot] [PATCH 0/6] Add ARMv8 PSCI framework macro.wave.z at gmail.com
2016-09-27  9:29 ` macro.wave.z at gmail.com [this message]
2016-09-27  9:29 ` [U-Boot] [PATCH 2/6] ARMv8: Add secure sections for PSCI text and data macro.wave.z at gmail.com
2016-09-27  9:29 ` [U-Boot] [PATCH 3/6] ARMv8: Add basic PSCI framework macro.wave.z at gmail.com
2016-09-27  9:29 ` [U-Boot] [PATCH 4/6] ARMv8: Setup PSCI memory and dt macro.wave.z at gmail.com
2016-09-27 16:00   ` york sun
2016-09-28  7:41     ` Hongbo Zhang
2016-09-27  9:29 ` [U-Boot] [PATCH 5/6] ARMv8: Enable SMC instruction macro.wave.z at gmail.com
2016-09-28  7:48   ` Hongbo Zhang
2016-09-27  9:29 ` [U-Boot] [PATCH 6/6] ARMv8: LS1043A: Enable LS1043A default PSCI support macro.wave.z at gmail.com
2016-09-27 17:23 ` [U-Boot] [PATCH 0/6] Add ARMv8 PSCI framework Tom Rini
2016-09-28  7:16   ` Hongbo Zhang
2016-09-28  8:27     ` Hongbo Zhang
2016-10-18  7:18       ` Hongbo Zhang
2016-10-26 18:17         ` york sun
2016-10-27  2:45           ` Hongbo Zhang
2016-10-28 13:30     ` Tom Rini
2016-10-31  3:00       ` Hongbo Zhang

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1474968546-8285-2-git-send-email-hongbo.zhang@nxp.com \
    --to=macro.wave.z@gmail.com \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox