stat: Add iops stat and sample number information to terse format
[fio.git] / os / os-linux.h
index 008ce2d0af1c15e78d0bcf19574f5d0ba0a0df02..3e7a2fc3303639564d47e06595c932f3b6322fb2 100644 (file)
@@ -303,11 +303,23 @@ static inline int fio_set_sched_idle(void)
 }
 #endif
 
-#ifndef POSIX_FADV_STREAMID
-#define POSIX_FADV_STREAMID    8
+#ifndef F_GET_RW_HINT
+#ifndef F_LINUX_SPECIFIC_BASE
+#define F_LINUX_SPECIFIC_BASE  1024
+#endif
+#define F_GET_RW_HINT          (F_LINUX_SPECIFIC_BASE + 11)
+#define F_SET_RW_HINT          (F_LINUX_SPECIFIC_BASE + 12)
+#endif
+
+#ifndef RWH_WRITE_LIFE_NONE
+#define RWH_WRITE_LIFE_NONE    0
+#define RWH_WRITE_LIFE_SHORT   1
+#define RWH_WRITE_LIFE_MEDIUM  2
+#define RWH_WRITE_LIFE_LONG    3
+#define RWH_WRITE_LIFE_EXTREME 4
 #endif
 
-#define FIO_HAVE_STREAMID
+#define FIO_HAVE_WRITE_HINT
 
 #ifndef RWF_HIPRI
 #define RWF_HIPRI      0x00000001
@@ -319,6 +331,14 @@ static inline int fio_set_sched_idle(void)
 #define RWF_SYNC       0x00000004
 #endif
 
+#ifndef RWF_WRITE_LIFE_SHIFT
+#define RWF_WRITE_LIFE_SHIFT           4
+#define RWF_WRITE_LIFE_SHORT           (1 << RWF_WRITE_LIFE_SHIFT)
+#define RWF_WRITE_LIFE_MEDIUM          (2 << RWF_WRITE_LIFE_SHIFT)
+#define RWF_WRITE_LIFE_LONG            (3 << RWF_WRITE_LIFE_SHIFT)
+#define RWF_WRITE_LIFE_EXTREME         (4 << RWF_WRITE_LIFE_SHIFT)
+#endif
+
 #ifndef CONFIG_PWRITEV2
 #ifdef __NR_preadv2
 static inline void make_pos_h_l(unsigned long *pos_h, unsigned long *pos_l,