Orange Pi5 kernel

Deprecated Linux kernel 5.10.110 for OrangePi 5/5B/5+ boards

3 Commits   0 Branches   0 Tags
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  1) // SPDX-License-Identifier: GPL-2.0
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  2) #include <linux/types.h>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  3) #include <linux/errno.h>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  4) #include <linux/uaccess.h>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  5) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  6) #include <asm/sfp-machine.h>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  7) #include <math-emu/soft-fp.h>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  8) #include <math-emu/double.h>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  9) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 10) int
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 11) fctiw(u32 *frD, void *frB)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 12) {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 13) 	FP_DECL_D(B);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 14) 	FP_DECL_EX;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 15) 	unsigned int r;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 16) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 17) 	FP_UNPACK_DP(B, frB);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 18) 	FP_TO_INT_D(r, B, 32, 1);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 19) 	frD[1] = r;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 20) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 21) #ifdef DEBUG
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 22) 	printk("%s: D %p, B %p: ", __func__, frD, frB);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 23) 	dump_double(frD);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 24) 	printk("\n");
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 25) #endif
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 26) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 27) 	return 0;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 28) }