mirror_zfs/lib
Tino Reichardt 48cf170d5a Add PPC cpu feature tests for FreeBSD and Linux
Add needed cpu feature tests for powerpc architecture.

Overview:
zfs_altivec_available() - needed by RAID-Z
zfs_vsx_available()     - needed by BLAKE3
zfs_isa207_available()  - needed by SHA2

Part 1 - Userspace
- use getauxval() for Linux and elf_aux_info() for FreeBSD
- direct including <sys/auxv.h> fails with double definitions
- so we self define the needed functions and definitions

Part 2 - Kernel space FreeBSD
- use exported cpu_features of <powerpc/cpu.h>

Part 3 - Kernel space Linux
- use cpu_has_feature() function of <asm/cpufeature.h>

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Ryan Moeller <ryan@iXsystems.com>
Signed-off-by: Tino Reichardt <milky-zfs@mcmilk.de>
Closes #13725
2022-09-16 14:25:53 -07:00
..
libavl cppcheck: explicitly exclude kernel code from userspace checks 2022-05-10 10:20:55 -07:00
libefi Replace dead opensolaris.org license link 2022-07-11 14:16:13 -07:00
libicp Introduce BLAKE3 checksums as an OpenZFS feature 2022-06-08 15:55:57 -07:00
libnvpair Replace dead opensolaris.org license link 2022-07-11 14:16:13 -07:00
libshare Fix unable to export zpool without nfs-utils 2022-09-16 13:43:26 -07:00
libspl Add PPC cpu feature tests for FreeBSD and Linux 2022-09-16 14:25:53 -07:00
libtpool Replace dead opensolaris.org license link 2022-07-11 14:16:13 -07:00
libunicode cppcheck: explicitly exclude kernel code from userspace checks 2022-05-10 10:20:55 -07:00
libuutil Replace dead opensolaris.org license link 2022-07-11 14:16:13 -07:00
libzfs Handle ECKSUM as new EZFS_CKSUM ‒ "insufficient replicas" 2022-09-16 13:59:25 -07:00
libzfs_core Implement a new type of zfs receive: corrective receive (-c) 2022-07-28 15:52:46 -07:00
libzfsbootenv Replace EXTRA_DIST with dist_noinst_DATA 2022-05-26 09:24:50 -07:00
libzpool Cleanup dead spa_boot code 2022-09-13 16:40:10 -07:00
libzstd cppcheck: explicitly exclude kernel code from userspace checks 2022-05-10 10:20:55 -07:00
libzutil Remove incorrect free() in zfs_get_pci_slots_sys_path() 2022-09-13 17:00:53 -07:00
Makefile.am autoconf: use include directives instead of recursing down lib 2022-05-10 10:18:11 -07:00