blob: 763b28e6ad3cb64caea3009b9844a4941340d5c2 [file] [log] [blame]
/* SPDX-License-Identifier: GPL-2.0-only */
#ifndef _ASMRISCV_ASM_H_
#define _ASMRISCV_ASM_H_
#if __riscv_xlen == 64
#define __REG_SEL(a, b) a
#elif __riscv_xlen == 32
#define __REG_SEL(a, b) b
#else
#error "Unexpected __riscv_xlen"
#endif
#define REG_L __REG_SEL(ld, lw)
#define REG_S __REG_SEL(sd, sw)
#define SZREG __REG_SEL(8, 4)
#define FP_SIZE 16
#endif /* _ASMRISCV_ASM_H_ */