2018-05-07 06:58:06 +09:00
|
|
|
/* SPDX-License-Identifier: GPL-2.0+ */
|
2017-12-26 14:55:51 +09:00
|
|
|
/*
|
|
|
|
* Copyright (C) 2017 Andes Technology Corporation
|
|
|
|
* Rick Chen, Andes Technology Corporation <rick@andestech.com>
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef __ASM_RISCV_MACH_TYPE_H
|
|
|
|
#define __ASM_RISCV_MACH_TYPE_H
|
|
|
|
|
|
|
|
#ifndef __ASSEMBLY__
|
|
|
|
/* The type of machine we're running on */
|
|
|
|
extern unsigned int __machine_arch_type;
|
|
|
|
#endif
|
|
|
|
|
2018-05-29 10:54:40 +09:00
|
|
|
#define MACH_TYPE_AE350 1
|
2017-12-26 14:55:51 +09:00
|
|
|
|
2018-05-29 10:54:40 +09:00
|
|
|
#ifdef CONFIG_ARCH_AE350
|
2017-12-26 14:55:51 +09:00
|
|
|
# ifdef machine_arch_type
|
|
|
|
# undef machine_arch_type
|
|
|
|
# define machine_arch_type __machine_arch_type
|
|
|
|
# else
|
2018-05-29 10:54:40 +09:00
|
|
|
# define machine_arch_type MACH_TYPE_AE350
|
2017-12-26 14:55:51 +09:00
|
|
|
# endif
|
2018-05-29 10:54:40 +09:00
|
|
|
# define machine_is_ae350() (machine_arch_type == MACH_TYPE_AE350)
|
2017-12-26 14:55:51 +09:00
|
|
|
#else
|
2018-05-29 10:54:40 +09:00
|
|
|
# define machine_is_ae350() (1)
|
2017-12-26 14:55:51 +09:00
|
|
|
#endif
|
|
|
|
|
|
|
|
#endif /* __ASM_RISCV_MACH_TYPE_H */
|