diff options
author | Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com> | 2019-02-14 10:07:45 -0500 |
---|---|---|
committer | Vineet Gupta <vgupta@synopsys.com> | 2019-02-21 14:03:19 -0500 |
commit | 493a2f812446e92bcb1e69a77381b4d39808d730 (patch) | |
tree | 81f0dcae81ba1431f584ded2934e88703efb01cb | |
parent | a66f2e57bd566240d8b3884eedf503928fbbe557 (diff) |
ARC: enable uboot support unconditionally
After reworking U-boot args handling code and adding paranoid
arguments check we can eliminate CONFIG_ARC_UBOOT_SUPPORT and
enable uboot support unconditionally.
For JTAG case we can assume that core registers will come up
reset value of 0 or in worst case we rely on user passing
'-on=clear_regs' to Metaware debugger.
Cc: stable@vger.kernel.org
Tested-by: Corentin LABBE <clabbe@baylibre.com>
Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com>
Signed-off-by: Vineet Gupta <vgupta@synopsys.com>
-rw-r--r-- | arch/arc/Kconfig | 12 | ||||
-rw-r--r-- | arch/arc/configs/nps_defconfig | 1 | ||||
-rw-r--r-- | arch/arc/configs/vdk_hs38_defconfig | 1 | ||||
-rw-r--r-- | arch/arc/configs/vdk_hs38_smp_defconfig | 2 | ||||
-rw-r--r-- | arch/arc/kernel/head.S | 2 | ||||
-rw-r--r-- | arch/arc/kernel/setup.c | 2 |
6 files changed, 0 insertions, 20 deletions
diff --git a/arch/arc/Kconfig b/arch/arc/Kconfig index 7215f52b3413..d750b302d5ab 100644 --- a/arch/arc/Kconfig +++ b/arch/arc/Kconfig | |||
@@ -191,7 +191,6 @@ config NR_CPUS | |||
191 | 191 | ||
192 | config ARC_SMP_HALT_ON_RESET | 192 | config ARC_SMP_HALT_ON_RESET |
193 | bool "Enable Halt-on-reset boot mode" | 193 | bool "Enable Halt-on-reset boot mode" |
194 | default y if ARC_UBOOT_SUPPORT | ||
195 | help | 194 | help |
196 | In SMP configuration cores can be configured as Halt-on-reset | 195 | In SMP configuration cores can be configured as Halt-on-reset |
197 | or they could all start at same time. For Halt-on-reset, non | 196 | or they could all start at same time. For Halt-on-reset, non |
@@ -523,17 +522,6 @@ config ARC_DBG_TLB_PARANOIA | |||
523 | 522 | ||
524 | endif | 523 | endif |
525 | 524 | ||
526 | config ARC_UBOOT_SUPPORT | ||
527 | bool "Support uboot arg Handling" | ||
528 | help | ||
529 | ARC Linux by default checks for uboot provided args as pointers to | ||
530 | external cmdline or DTB. This however breaks in absence of uboot, | ||
531 | when booting from Metaware debugger directly, as the registers are | ||
532 | not zeroed out on reset by mdb and/or ARCv2 based cores. The bogus | ||
533 | registers look like uboot args to kernel which then chokes. | ||
534 | So only enable the uboot arg checking/processing if users are sure | ||
535 | of uboot being in play. | ||
536 | |||
537 | config ARC_BUILTIN_DTB_NAME | 525 | config ARC_BUILTIN_DTB_NAME |
538 | string "Built in DTB" | 526 | string "Built in DTB" |
539 | help | 527 | help |
diff --git a/arch/arc/configs/nps_defconfig b/arch/arc/configs/nps_defconfig index 6e84060e7c90..621f59407d76 100644 --- a/arch/arc/configs/nps_defconfig +++ b/arch/arc/configs/nps_defconfig | |||
@@ -31,7 +31,6 @@ CONFIG_ARC_CACHE_LINE_SHIFT=5 | |||
31 | # CONFIG_ARC_HAS_LLSC is not set | 31 | # CONFIG_ARC_HAS_LLSC is not set |
32 | CONFIG_ARC_KVADDR_SIZE=402 | 32 | CONFIG_ARC_KVADDR_SIZE=402 |
33 | CONFIG_ARC_EMUL_UNALIGNED=y | 33 | CONFIG_ARC_EMUL_UNALIGNED=y |
34 | CONFIG_ARC_UBOOT_SUPPORT=y | ||
35 | CONFIG_PREEMPT=y | 34 | CONFIG_PREEMPT=y |
36 | CONFIG_NET=y | 35 | CONFIG_NET=y |
37 | CONFIG_UNIX=y | 36 | CONFIG_UNIX=y |
diff --git a/arch/arc/configs/vdk_hs38_defconfig b/arch/arc/configs/vdk_hs38_defconfig index 1e59a2e9c602..e447ace6fa1c 100644 --- a/arch/arc/configs/vdk_hs38_defconfig +++ b/arch/arc/configs/vdk_hs38_defconfig | |||
@@ -13,7 +13,6 @@ CONFIG_PARTITION_ADVANCED=y | |||
13 | CONFIG_ARC_PLAT_AXS10X=y | 13 | CONFIG_ARC_PLAT_AXS10X=y |
14 | CONFIG_AXS103=y | 14 | CONFIG_AXS103=y |
15 | CONFIG_ISA_ARCV2=y | 15 | CONFIG_ISA_ARCV2=y |
16 | CONFIG_ARC_UBOOT_SUPPORT=y | ||
17 | CONFIG_ARC_BUILTIN_DTB_NAME="vdk_hs38" | 16 | CONFIG_ARC_BUILTIN_DTB_NAME="vdk_hs38" |
18 | CONFIG_PREEMPT=y | 17 | CONFIG_PREEMPT=y |
19 | CONFIG_NET=y | 18 | CONFIG_NET=y |
diff --git a/arch/arc/configs/vdk_hs38_smp_defconfig b/arch/arc/configs/vdk_hs38_smp_defconfig index b5c3f6c54b03..c82cdb10aaf4 100644 --- a/arch/arc/configs/vdk_hs38_smp_defconfig +++ b/arch/arc/configs/vdk_hs38_smp_defconfig | |||
@@ -15,8 +15,6 @@ CONFIG_AXS103=y | |||
15 | CONFIG_ISA_ARCV2=y | 15 | CONFIG_ISA_ARCV2=y |
16 | CONFIG_SMP=y | 16 | CONFIG_SMP=y |
17 | # CONFIG_ARC_TIMERS_64BIT is not set | 17 | # CONFIG_ARC_TIMERS_64BIT is not set |
18 | # CONFIG_ARC_SMP_HALT_ON_RESET is not set | ||
19 | CONFIG_ARC_UBOOT_SUPPORT=y | ||
20 | CONFIG_ARC_BUILTIN_DTB_NAME="vdk_hs38_smp" | 18 | CONFIG_ARC_BUILTIN_DTB_NAME="vdk_hs38_smp" |
21 | CONFIG_PREEMPT=y | 19 | CONFIG_PREEMPT=y |
22 | CONFIG_NET=y | 20 | CONFIG_NET=y |
diff --git a/arch/arc/kernel/head.S b/arch/arc/kernel/head.S index 1f945d0f40da..30e090625916 100644 --- a/arch/arc/kernel/head.S +++ b/arch/arc/kernel/head.S | |||
@@ -100,7 +100,6 @@ ENTRY(stext) | |||
100 | st.ab 0, [r5, 4] | 100 | st.ab 0, [r5, 4] |
101 | 1: | 101 | 1: |
102 | 102 | ||
103 | #ifdef CONFIG_ARC_UBOOT_SUPPORT | ||
104 | ; Uboot - kernel ABI | 103 | ; Uboot - kernel ABI |
105 | ; r0 = [0] No uboot interaction, [1] cmdline in r2, [2] DTB in r2 | 104 | ; r0 = [0] No uboot interaction, [1] cmdline in r2, [2] DTB in r2 |
106 | ; r1 = magic number (always zero as of now) | 105 | ; r1 = magic number (always zero as of now) |
@@ -108,7 +107,6 @@ ENTRY(stext) | |||
108 | ; These are handled later in handle_uboot_args() | 107 | ; These are handled later in handle_uboot_args() |
109 | st r0, [@uboot_tag] | 108 | st r0, [@uboot_tag] |
110 | st r2, [@uboot_arg] | 109 | st r2, [@uboot_arg] |
111 | #endif | ||
112 | 110 | ||
113 | ; setup "current" tsk and optionally cache it in dedicated r25 | 111 | ; setup "current" tsk and optionally cache it in dedicated r25 |
114 | mov r9, @init_task | 112 | mov r9, @init_task |
diff --git a/arch/arc/kernel/setup.c b/arch/arc/kernel/setup.c index 8bb156164556..93d4d6639873 100644 --- a/arch/arc/kernel/setup.c +++ b/arch/arc/kernel/setup.c | |||
@@ -487,7 +487,6 @@ void __init handle_uboot_args(void) | |||
487 | bool use_embedded_dtb = true; | 487 | bool use_embedded_dtb = true; |
488 | bool append_cmdline = false; | 488 | bool append_cmdline = false; |
489 | 489 | ||
490 | #ifdef CONFIG_ARC_UBOOT_SUPPORT | ||
491 | /* check that we know this tag */ | 490 | /* check that we know this tag */ |
492 | if (uboot_tag != UBOOT_TAG_NONE && | 491 | if (uboot_tag != UBOOT_TAG_NONE && |
493 | uboot_tag != UBOOT_TAG_CMDLINE && | 492 | uboot_tag != UBOOT_TAG_CMDLINE && |
@@ -514,7 +513,6 @@ void __init handle_uboot_args(void) | |||
514 | append_cmdline = true; | 513 | append_cmdline = true; |
515 | 514 | ||
516 | ignore_uboot_args: | 515 | ignore_uboot_args: |
517 | #endif | ||
518 | 516 | ||
519 | if (use_embedded_dtb) { | 517 | if (use_embedded_dtb) { |
520 | machine_desc = setup_machine_fdt(__dtb_start); | 518 | machine_desc = setup_machine_fdt(__dtb_start); |