1 /* SPDX-License-Identifier: GPL-2.0 */ 2 /* 3 * Copyright (C) 2020-2022 Loongson Technology Corporation Limited 4 */ 5 #ifndef __ASM_PREFETCH_H 6 #define __ASM_PREFETCH_H 7 8 #define Pref_Load 0 9 #define Pref_Store 8 10 11 #ifdef __ASSEMBLY__ 12 13 .macro __pref hint addr 14 #ifdef CONFIG_CPU_HAS_PREFETCH 15 preld \hint, \addr, 0 16 #endif 17 .endm 18 19 .macro pref_load addr 20 __pref Pref_Load, \addr 21 .endm 22 23 .macro pref_store addr 24 __pref Pref_Store, \addr 25 .endm 26 27 #endif 28 29 #endif /* __ASM_PREFETCH_H */ 30