From 1894d1716a2ec193dbec35c29602984eb23cdf9a Mon Sep 17 00:00:00 2001 From: Tomohiro Kusumi Date: Tue, 23 May 2017 21:44:48 +0300 Subject: [PATCH] Include sg headers in os/os-linux.h Since sg is Linux kernel's SCSI subsystem specific interface, it's better to include required headers in os/os-linux.h which also defines FIO_HAVE_SGIO, rather than conditionally including them in os/os.h. Android has FIO_HAVE_SGIO disabled, so no need to do this for Android. Even if another platform implements sg (compatible) ioctls within their SCSI driver, there is no guarantee the required kernel header will be "linux/fs.h", which then fails to compile. Signed-off-by: Tomohiro Kusumi Signed-off-by: Jens Axboe --- os/os-linux.h | 2 ++ os/os.h | 5 ----- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/os/os-linux.h b/os/os-linux.h index ba53590d..0e6246ef 100644 --- a/os/os-linux.h +++ b/os/os-linux.h @@ -16,6 +16,8 @@ #include #include #include +#include +#include #include "./os-linux-syscall.h" #include "binject.h" diff --git a/os/os.h b/os/os.h index 21b7a9d0..3c96b4d1 100644 --- a/os/os.h +++ b/os/os.h @@ -60,11 +60,6 @@ typedef struct aiocb os_aiocb_t; #endif #endif -#ifdef FIO_HAVE_SGIO -#include -#include -#endif - #ifndef CONFIG_STRSEP #include "../oslib/strsep.h" #endif -- 2.25.1