stand/ficl 64-bit compatibility
Currently, the only thing that prevents a functioning 64-bit FICL build is a few integer types that were intended to be fixed-width. Changing them to C99 integer types allows building a functioning 64-bit FICL. While this isn't applicable to the default settings of any in-tree loaders, it is necessary for a future Petitboot loader, due to the requirement that it be compiled as a 64-bit program. Reviewed by: tsoome, imp (earlier revision) Sponsored by: Tag1 Consulting, Inc. Differential Revision: https://reviews.freebsd.org/D26364
This commit is contained in:
parent
115c987b3f
commit
9e4c35f867
@ -249,7 +249,7 @@ typedef struct ficl_system_info FICL_SYSTEM_INFO;
|
||||
** complement of false... that unifies logical and bitwise operations
|
||||
** nicely.
|
||||
*/
|
||||
#define FICL_TRUE ((unsigned long)~(0L))
|
||||
#define FICL_TRUE ((FICL_UNS)~(0LL))
|
||||
#define FICL_FALSE (0)
|
||||
#define FICL_BOOL(x) ((x) ? FICL_TRUE : FICL_FALSE)
|
||||
|
||||
|
@ -79,15 +79,15 @@
|
||||
** System dependent data type declarations...
|
||||
*/
|
||||
#if !defined INT32
|
||||
#define INT32 int
|
||||
#define INT32 int32_t
|
||||
#endif
|
||||
|
||||
#if !defined UNS32
|
||||
#define UNS32 unsigned int
|
||||
#define UNS32 uint32_t
|
||||
#endif
|
||||
|
||||
#if !defined UNS16
|
||||
#define UNS16 unsigned short
|
||||
#define UNS16 uint16_t
|
||||
#endif
|
||||
|
||||
#if !defined UNS8
|
||||
@ -367,6 +367,9 @@ typedef struct
|
||||
*/
|
||||
#if !defined FICL_ALIGN
|
||||
#define FICL_ALIGN 2
|
||||
#endif
|
||||
|
||||
#if !defined FICL_ALIGN_ADD
|
||||
#define FICL_ALIGN_ADD ((1 << FICL_ALIGN) - 1)
|
||||
#endif
|
||||
|
||||
|
@ -63,7 +63,7 @@ init_heap(void)
|
||||
{
|
||||
bzero(heap, HEAP_SIZE);
|
||||
|
||||
setheap(heap, (void *)((int)heap + HEAP_SIZE));
|
||||
setheap(heap, (void *)((uintptr_t)heap + HEAP_SIZE));
|
||||
}
|
||||
|
||||
uint64_t
|
||||
|
Loading…
Reference in New Issue
Block a user