]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
microblaze: exception: migrate MICROBLAZE_V5 to Kconfig
authorOvidiu Panait <ovidiu.panait@windriver.com>
Sun, 13 Feb 2022 08:09:20 +0000 (10:09 +0200)
committerMichal Simek <michal.simek@xilinx.com>
Tue, 15 Feb 2022 12:11:43 +0000 (13:11 +0100)
Also, rename it to XILINX_MICROBLAZE0_DELAY_SLOT_EXCEP, since it only
covers delay slot exception support.

Signed-off-by: Ovidiu Panait <ovidiu.panait@windriver.com>
Link: https://lore.kernel.org/r/20220213080925.1548411-2-ovidiu.panait@windriver.com
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
arch/microblaze/cpu/exception.c
board/xilinx/microblaze-generic/Kconfig
include/configs/microblaze-generic.h

index f60f1fc6936cae22f34e836ca0b79f97d369a83c..5601dde5b47d95520e6b1d4bfd2b57427053dbb0 100644 (file)
@@ -40,7 +40,7 @@ void _hw_exception_handler (void)
        case 0x7:
                puts("Priviledged or stack protection violation exception\n");
                break;
-#ifdef MICROBLAZE_V5
+#if CONFIG_IS_ENABLED(XILINX_MICROBLAZE0_DELAY_SLOT_EXCEP)
        case 0x1000:
                puts("Exception in delay slot\n");
                break;
index e31257d3351d54c500d971b5232c798a68807b9b..117b476f3f4133487f87c1748cf1d963bbf5be7d 100644 (file)
@@ -47,6 +47,15 @@ config XILINX_MICROBLAZE0_USR_EXCEP
          the exception vector table. The user exception vector is located at
          C_BASE_VECTORS + 0x8 address.
 
+config XILINX_MICROBLAZE0_DELAY_SLOT_EXCEP
+       bool "MicroBlaze delay slot exception support"
+       default y
+       help
+         Enable this option if the MicroBlaze processor supports exceptions
+         caused by delay slot instructions (processor version >= v5.00). When
+         enabled, the hw exception handler will print a message indicating
+         whether the exception was triggered by a delay slot instruction.
+
 config XILINX_MICROBLAZE0_VECTOR_BASE_ADDR
        hex "Location of MicroBlaze vectors"
        default 0x0
index ca749ed18ac9eb676dd612287eb58bad66b6cec4..fd5a9cf8b8e2b3c650c9ff4e9313f4fc13c4d6d6 100644 (file)
@@ -11,9 +11,6 @@
 /* Microblaze is microblaze_0 */
 #define XILINX_FSL_NUMBER      3
 
-/* MicroBlaze CPU */
-#define        MICROBLAZE_V5           1
-
 #define CONFIG_SYS_BOOTM_LEN   (64 * 1024 * 1024)
 
 /* uart */