192 lines
4.0 KiB
Diff
192 lines
4.0 KiB
Diff
From cdd5e78a275c8cda5d48d15acc96c3be5170bf2f Mon Sep 17 00:00:00 2001
|
|
From: Romain Naour <romain.naour@smile.fr>
|
|
Date: Sat, 6 Sep 2025 00:26:00 +0200
|
|
Subject: [PATCH] Fix build without ASYNC_IO
|
|
|
|
Fix the following build failure without ASYNC_IO:
|
|
|
|
/home/buildroot/autobuild/run/instance-1/output-1/host/opt/ext-toolchain/bin/../lib/gcc/mipsel-buildroot-linux-uclibc/12.3.0/../../../../mipsel-buildroot-linux-uclibc/bin/ld: iozone_linux-noaio.o: in function `read_perf_test':
|
|
iozone.c:(.text+0x11a74): undefined reference to `end_async'
|
|
|
|
Fixes:
|
|
- http://autobuild.buildroot.org/results/31a4f0ac9eeb71df5d2f40ffe9f1f256cb58e399
|
|
|
|
Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
|
|
Upstream: sent to capps@iozone.org
|
|
[Romain:
|
|
rebase on 3.508
|
|
convert to git format
|
|
]
|
|
Signed-off-by: Romain Naour <romain.naour@smile.fr>
|
|
---
|
|
src/current/iozone.c | 20 ++++++++++++++++++++
|
|
1 file changed, 20 insertions(+)
|
|
|
|
diff --git a/src/current/iozone.c b/src/current/iozone.c
|
|
index 6657a9b..8de26cf 100755
|
|
--- a/src/current/iozone.c
|
|
+++ b/src/current/iozone.c
|
|
@@ -9196,6 +9196,7 @@ long long *data1,*data2;
|
|
}
|
|
}
|
|
}
|
|
+#ifdef ASYNC_IO
|
|
if(async_flag)
|
|
{
|
|
if(no_copy_flag)
|
|
@@ -9203,6 +9204,7 @@ long long *data1,*data2;
|
|
end_async(gc);
|
|
gc=0;
|
|
}
|
|
+#endif
|
|
buffer1=0;
|
|
if(hist_summary)
|
|
{
|
|
@@ -9677,6 +9679,7 @@ long long *data1, *data2;
|
|
}
|
|
}
|
|
}
|
|
+#ifdef ASYNC_IO
|
|
if(async_flag)
|
|
{
|
|
if(no_copy_flag)
|
|
@@ -9684,6 +9687,7 @@ long long *data1, *data2;
|
|
end_async(gc);
|
|
gc=0;
|
|
}
|
|
+#endif
|
|
if(rlocking)
|
|
{
|
|
lock_offset=I_LSEEK(fd,0,SEEK_CUR);
|
|
@@ -10140,6 +10144,7 @@ long long *data1,*data2;
|
|
}
|
|
}
|
|
}
|
|
+#ifdef ASYNC_IO
|
|
if(async_flag)
|
|
{
|
|
if(no_copy_flag)
|
|
@@ -10147,6 +10152,7 @@ long long *data1,*data2;
|
|
end_async(gc);
|
|
gc=0;
|
|
}
|
|
+#endif
|
|
if(rlocking)
|
|
{
|
|
mylockr((int) fd, (int) 0, (int)1,
|
|
@@ -10792,6 +10798,7 @@ printf("Read_Stride\n");
|
|
}
|
|
}
|
|
}
|
|
+#ifdef ASYNC_IO
|
|
if(async_flag)
|
|
{
|
|
if(no_copy_flag)
|
|
@@ -10799,6 +10806,7 @@ printf("Read_Stride\n");
|
|
end_async(gc);
|
|
gc=0;
|
|
}
|
|
+#endif
|
|
|
|
/* This is a bit tricky. The goal is to read with a stride through
|
|
the file. The problem is that you need to touch all of the file
|
|
@@ -15528,6 +15536,7 @@ thread_read_test(x)
|
|
}
|
|
}
|
|
}
|
|
+#ifdef ASYNC_IO
|
|
if(async_flag)
|
|
{
|
|
if(no_copy_flag)
|
|
@@ -15535,6 +15544,7 @@ thread_read_test(x)
|
|
end_async(gc);
|
|
gc=0;
|
|
}
|
|
+#endif
|
|
read_so_far+=reclen/1024;
|
|
r_traj_bytes_completed+=reclen;
|
|
r_traj_ops_completed++;
|
|
@@ -16093,6 +16103,7 @@ thread_pread_test(x)
|
|
}
|
|
}
|
|
}
|
|
+#ifdef ASYNC_IO
|
|
if(async_flag)
|
|
{
|
|
if(no_copy_flag)
|
|
@@ -16100,6 +16111,7 @@ thread_pread_test(x)
|
|
end_async(gc);
|
|
gc=0;
|
|
}
|
|
+#endif
|
|
read_so_far+=reclen/1024;
|
|
r_traj_bytes_completed+=reclen;
|
|
r_traj_ops_completed++;
|
|
@@ -16708,6 +16720,7 @@ thread_rread_test(x)
|
|
}
|
|
}
|
|
}
|
|
+#ifdef ASYNC_IO
|
|
if(async_flag)
|
|
{
|
|
if(no_copy_flag)
|
|
@@ -16715,6 +16728,7 @@ thread_rread_test(x)
|
|
end_async(gc);
|
|
gc=0;
|
|
}
|
|
+#endif
|
|
re_read_so_far+=reclen/1024;
|
|
r_traj_bytes_completed+=reclen;
|
|
r_traj_ops_completed++;
|
|
@@ -17287,6 +17301,7 @@ thread_reverse_read_test(x)
|
|
lock_offset, reclen);
|
|
}
|
|
current_position+=reclen;
|
|
+#ifdef ASYNC_IO
|
|
if(async_flag)
|
|
{
|
|
if(no_copy_flag)
|
|
@@ -17294,6 +17309,7 @@ thread_reverse_read_test(x)
|
|
end_async(gc);
|
|
gc=0;
|
|
}
|
|
+#endif
|
|
t_offset = (off64_t)reclen*2;
|
|
if (!(h_flag || k_flag || mmapflag))
|
|
{
|
|
@@ -17821,6 +17837,7 @@ thread_stride_read_test(x)
|
|
}
|
|
}
|
|
}
|
|
+#ifdef ASYNC_IO
|
|
if(async_flag)
|
|
{
|
|
if(no_copy_flag)
|
|
@@ -17828,6 +17845,7 @@ thread_stride_read_test(x)
|
|
end_async(gc);
|
|
gc=0;
|
|
}
|
|
+#endif
|
|
if(current_position + (stride * reclen) >= (numrecs64 * reclen)-reclen)
|
|
{
|
|
current_position=0;
|
|
@@ -18571,6 +18589,7 @@ void *x;
|
|
}
|
|
}
|
|
}
|
|
+#ifdef ASYNC_IO
|
|
if(async_flag)
|
|
{
|
|
if(no_copy_flag)
|
|
@@ -18578,6 +18597,7 @@ void *x;
|
|
end_async(gc);
|
|
gc=0;
|
|
}
|
|
+#endif
|
|
ranread_so_far+=reclen/1024;
|
|
if(*stop_flag)
|
|
{
|
|
--
|
|
2.51.0
|
|
|