summaryrefslogtreecommitdiff
path: root/arch/riscv/include/asm
diff options
context:
space:
mode:
authorTom Rini <trini@konsulko.com>2018-05-30 08:43:04 -0400
committerTom Rini <trini@konsulko.com>2018-05-30 08:43:04 -0400
commit964d4f7211ec85b890e852d0226adba0b4f8c1c9 (patch)
tree7b682f156a9bde3b9c3d82a184091bd4445f15cd /arch/riscv/include/asm
parent9c2369a554437f072733c53ba0f5f5384f35b6d3 (diff)
parent6ffea11b89099d72029bc644f7664736ee7ca667 (diff)
Merge git://git.denx.de/u-boot-riscv
Diffstat (limited to 'arch/riscv/include/asm')
-rw-r--r--arch/riscv/include/asm/mach-types.h10
-rw-r--r--arch/riscv/include/asm/setjmp.h25
-rw-r--r--arch/riscv/include/asm/u-boot-riscv.h1
3 files changed, 31 insertions, 5 deletions
diff --git a/arch/riscv/include/asm/mach-types.h b/arch/riscv/include/asm/mach-types.h
index 93afff70b3..f219cedfd3 100644
--- a/arch/riscv/include/asm/mach-types.h
+++ b/arch/riscv/include/asm/mach-types.h
@@ -12,18 +12,18 @@
extern unsigned int __machine_arch_type;
#endif
-#define MACH_TYPE_AE250 1
+#define MACH_TYPE_AE350 1
-#ifdef CONFIG_ARCH_AE250
+#ifdef CONFIG_ARCH_AE350
# ifdef machine_arch_type
# undef machine_arch_type
# define machine_arch_type __machine_arch_type
# else
-# define machine_arch_type MACH_TYPE_AE250
+# define machine_arch_type MACH_TYPE_AE350
# endif
-# define machine_is_ae250() (machine_arch_type == MACH_TYPE_AE250)
+# define machine_is_ae350() (machine_arch_type == MACH_TYPE_AE350)
#else
-# define machine_is_ae250() (1)
+# define machine_is_ae350() (1)
#endif
#endif /* __ASM_RISCV_MACH_TYPE_H */
diff --git a/arch/riscv/include/asm/setjmp.h b/arch/riscv/include/asm/setjmp.h
new file mode 100644
index 0000000000..72383d4330
--- /dev/null
+++ b/arch/riscv/include/asm/setjmp.h
@@ -0,0 +1,25 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
+/*
+ * (C) Copyright 2018 Alexander Graf <agraf@suse.de>
+ */
+
+#ifndef _SETJMP_H_
+#define _SETJMP_H_ 1
+
+/*
+ * This really should be opaque, but the EFI implementation wrongly
+ * assumes that a 'struct jmp_buf_data' is defined.
+ */
+struct jmp_buf_data {
+ /* x2, x8, x9, x18, x19, x20, x21, x22, x23, x24, x25, x26, x27, sp */
+ unsigned long s_regs[12]; /* s0 - s11 */
+ unsigned long ra;
+ unsigned long sp;
+};
+
+typedef struct jmp_buf_data jmp_buf[1];
+
+int setjmp(jmp_buf jmp);
+void longjmp(jmp_buf jmp, int ret);
+
+#endif /* _SETJMP_H_ */
diff --git a/arch/riscv/include/asm/u-boot-riscv.h b/arch/riscv/include/asm/u-boot-riscv.h
index c4c068f9e2..49febd5881 100644
--- a/arch/riscv/include/asm/u-boot-riscv.h
+++ b/arch/riscv/include/asm/u-boot-riscv.h
@@ -16,5 +16,6 @@ int cleanup_before_linux(void);
/* board/.../... */
int board_init(void);
+void board_quiesce_devices(void);
#endif /* _U_BOOT_RISCV_H_ */