X-Git-Url: https://git.saurik.com/apple/xnu.git/blobdiff_plain/6d2010ae8f7a6078e10b361c6962983bab233e0f..3e170ce000f1506b7b5d2c5c7faec85ceabb573d:/libkern/kxld/kxld_util.h diff --git a/libkern/kxld/kxld_util.h b/libkern/kxld/kxld_util.h index 9d5720f04..f20bc18e2 100644 --- a/libkern/kxld/kxld_util.h +++ b/libkern/kxld/kxld_util.h @@ -28,13 +28,18 @@ #ifndef _KXLD_UTIL_H_ #define _KXLD_UTIL_H_ -#include #include #if KERNEL #include + #include #else #include #include "kxld_types.h" + + /* Get machine.h from the kernel source so we can support all platforms + * that the kernel supports. Otherwise we're at the mercy of the host. + */ + #include "../../osfmk/mach/machine.h" #endif /* 64-bit helpers */ @@ -200,4 +205,14 @@ const char * kxld_strstr(const char *s, const char *find) void kxld_print_memory_report(void) __attribute__((visibility("hidden"))); +/******************************************************************************* +* Cross Linking +*******************************************************************************/ +#if !KERNEL +boolean_t kxld_set_cross_link_page_size(kxld_size_t target_page_size); +#endif /* !KERNEL */ +kxld_size_t kxld_get_effective_page_size(void); +kxld_addr_t kxld_round_page_cross_safe(kxld_addr_t addr); + + #endif /* _KXLD_UTIL_H_ */