1 /* SPDX-License-Identifier: GPL-2.0-only */ 2 /* 3 * Authors: Jackie Liu <liuyun01@kylinos.cn> 4 * Copyright (C) 2018,Tianjin KYLIN Information Technology Co., Ltd. 5 */ 6 #include <asm/simd.h> 7 8 extern struct xor_block_template xor_block_neon; 9 extern struct xor_block_template xor_block_eor3; 10 11 static __always_inline void __init arch_xor_init(void) 12 { 13 xor_register(&xor_block_8regs); 14 xor_register(&xor_block_32regs); 15 if (cpu_has_neon()) { 16 if (cpu_have_named_feature(SHA3)) 17 xor_register(&xor_block_eor3); 18 else 19 xor_register(&xor_block_neon); 20 } 21 } 22