1 /* SPDX-License-Identifier: GPL-2.0-or-later */ 2 /* 3 * 4 * Copyright (C) IBM Corporation, 2012 5 * 6 * Author: Anton Blanchard <anton@au.ibm.com> 7 */ 8 #include <asm/cpu_has_feature.h> 9 10 extern struct xor_block_template xor_block_altivec; 11 12 static __always_inline void __init arch_xor_init(void) 13 { 14 xor_register(&xor_block_8regs); 15 xor_register(&xor_block_8regs_p); 16 xor_register(&xor_block_32regs); 17 xor_register(&xor_block_32regs_p); 18 #ifdef CONFIG_ALTIVEC 19 if (cpu_has_feature(CPU_FTR_ALTIVEC)) 20 xor_register(&xor_block_altivec); 21 #endif 22 } 23