Allow LinuxKPI types to be used in bootloaders, by checking for the

_STANDALONE definition.

No functional change intended.

MFC after:	1 week
Sponsored by:	Mellanox Technologies // NVIDIA Networking
This commit is contained in:
Hans Petter Selasky 2020-11-18 13:47:11 +00:00
parent db4df56365
commit 99f20bdc47
2 changed files with 5 additions and 3 deletions

View File

@ -31,7 +31,7 @@
#ifndef _ASM_TYPES_H_
#define _ASM_TYPES_H_
#ifdef _KERNEL
#if defined(_KERNEL) || defined(_STANDALONE)
#include <sys/types.h>
@ -59,6 +59,6 @@ typedef vm_paddr_t dma64_addr_t;
typedef unsigned short umode_t;
#endif /* _KERNEL */
#endif /* _KERNEL || _STANDALONE */
#endif /* _ASM_TYPES_H_ */

View File

@ -57,8 +57,10 @@ typedef uint16_t __aligned_u16 __aligned(sizeof(uint16_t));
typedef uint32_t __aligned_u32 __aligned(sizeof(uint32_t));
typedef uint64_t __aligned_u64 __aligned(sizeof(uint64_t));
#ifdef _KERNEL
typedef unsigned short ushort;
typedef unsigned int uint;
#endif
typedef unsigned long ulong;
typedef unsigned gfp_t;
typedef off_t loff_t;
@ -67,7 +69,7 @@ typedef uint16_t __bitwise__ __sum16;
typedef unsigned long pgoff_t;
typedef unsigned __poll_t;
typedef u64 phys_addr_t;
typedef uint64_t phys_addr_t;
typedef size_t __kernel_size_t;