mirror of
https://github.com/opnsense/src.git
synced 2026-06-09 00:32:25 -04:00
zfs: enable FPU on powerpc*
Summary: MFC after: 1 week Test Plan: make kernel and boot with ZFS on / Reviewers: #powerpc Subscribers: imp, delphij Differential Revision: https://reviews.freebsd.org/D49538
This commit is contained in:
parent
aeddee8334
commit
5b02365ac6
2 changed files with 23 additions and 5 deletions
|
|
@ -17,8 +17,17 @@ contrib/openzfs/module/icp/asm-ppc64/blake3/b3_ppc64le_sse41.S optional zfs comp
|
|||
# zfs sha2 hash support
|
||||
contrib/openzfs/module/icp/asm-ppc64/sha2/sha256-p8.S optional zfs compile-with "${ZFS_S}"
|
||||
contrib/openzfs/module/icp/asm-ppc64/sha2/sha512-p8.S optional zfs compile-with "${ZFS_S}"
|
||||
contrib/openzfs/module/icp/asm-ppc64/sha2/sha256-ppc.S optional zfs compile-with "${ZFS_S}"
|
||||
contrib/openzfs/module/icp/asm-ppc64/sha2/sha512-ppc.S optional zfs compile-with "${ZFS_S}"
|
||||
zfs-sha256-ppc.o optional zfs \
|
||||
dependency "$S/contrib/openzfs/module/icp/asm-ppc64/sha2/sha256-ppc.S" \
|
||||
compile-with "${CC} -c ${ZFS_ASM_CFLAGS} -o ${.TARGET} ${WERROR} $S/contrib/openzfs/module/icp/asm-ppc64/sha2/sha256-ppc.S" \
|
||||
no-implicit-rule \
|
||||
clean "zfs-sha256-ppc.o"
|
||||
|
||||
zfs-sha512-ppc.o optional zfs \
|
||||
dependency "$S/contrib/openzfs/module/icp/asm-ppc64/sha2/sha512-ppc.S" \
|
||||
compile-with "${CC} -c ${ZFS_ASM_CFLAGS} -o ${.TARGET} ${WERROR} $S/contrib/openzfs/module/icp/asm-ppc64/sha2/sha512-ppc.S" \
|
||||
no-implicit-rule \
|
||||
clean "zfs-sha512-ppc.o"
|
||||
|
||||
# openssl ppc common files
|
||||
crypto/openssl/ossl_ppc.c optional ossl powerpc64 | ossl powerpc64le
|
||||
|
|
|
|||
|
|
@ -44,16 +44,25 @@
|
|||
#ifndef _FREEBSD_SIMD_POWERPC_H
|
||||
#define _FREEBSD_SIMD_POWERPC_H
|
||||
|
||||
#include <machine/pcpu.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/cdefs.h>
|
||||
|
||||
#include <machine/pcb.h>
|
||||
#include <machine/cpu.h>
|
||||
#include <machine/fpu.h>
|
||||
|
||||
#define kfpu_allowed() 0
|
||||
#define kfpu_allowed() 1
|
||||
#define kfpu_initialize(tsk) do {} while (0)
|
||||
#define kfpu_begin() do {} while (0)
|
||||
#define kfpu_end() do {} while (0)
|
||||
#define kfpu_begin() { \
|
||||
if (__predict_false(!is_fpu_kern_thread(0))) \
|
||||
fpu_kern_enter(PCPU_GET(curthread), NULL, FPU_KERN_NOCTX);\
|
||||
}
|
||||
#define kfpu_end() { \
|
||||
if (__predict_false(PCPU_GET(curpcb)->pcb_flags & PCB_KERN_FPU_NOSAVE))\
|
||||
fpu_kern_leave(PCPU_GET(curthread), NULL); \
|
||||
}
|
||||
#define kfpu_init() (0)
|
||||
#define kfpu_fini() do {} while (0)
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue