From: Bruce Cran Date: Wed, 4 Apr 2012 00:00:00 +0000 (-0600) Subject: Fix address truncation on Windows X-Git-Tag: fio-2.0.7~5 X-Git-Url: https://git.kernel.dk/?p=fio.git;a=commitdiff_plain;h=7078106dbbc524b6a3b2c39ddd04a9f676b10e53;hp=0d23771290c6bc8ed5c6e917b1eb90f86ef81931 Fix address truncation on Windows Avoid having PAGE_ALIGN truncate addresses by using a pointer-sized variable for the page size and mask. Signed-off-by: Jens Axboe --- diff --git a/fio.c b/fio.c index be60c5ff..ac026fba 100644 --- a/fio.c +++ b/fio.c @@ -36,8 +36,8 @@ #include "memalign.h" #include "server.h" -unsigned long page_mask; -unsigned long page_size; +uintptr_t page_mask; +uintptr_t page_size; static int endian_check(void) { diff --git a/fio.h b/fio.h index cf2e3c51..6da22f03 100644 --- a/fio.h +++ b/fio.h @@ -528,7 +528,7 @@ extern int groupid; extern int terse_output; extern int temp_stall_ts; extern unsigned long long mlock_size; -extern unsigned long page_mask, page_size; +extern uintptr_t page_mask, page_size; extern int read_only; extern int eta_print; extern unsigned long done_secs;