[LTP] [PATCH v2 25/30] ltp-aiodio/read_checkzero: Remove
Cyril Hrubis
chrubis@suse.cz
Tue May 3 19:47:13 CEST 2022
Remove leftovers that are not used anymore.
CC: Andrea Cervesato <andrea.cervesato@suse.de>
Signed-off-by: Cyril Hrubis <chrubis@suse.cz>
---
runtest/ltp-aiodio.part4 | 2 -
testcases/kernel/io/ltp-aiodio/.gitignore | 1 -
.../kernel/io/ltp-aiodio/read_checkzero.c | 84 -------------------
3 files changed, 87 deletions(-)
delete mode 100644 testcases/kernel/io/ltp-aiodio/read_checkzero.c
diff --git a/runtest/ltp-aiodio.part4 b/runtest/ltp-aiodio.part4
index 54019d47b..d88c27a83 100644
--- a/runtest/ltp-aiodio.part4
+++ b/runtest/ltp-aiodio.part4
@@ -59,8 +59,6 @@ ADI009 dio_append
DIT000 dio_truncate
DIT001 dio_truncate
DIT002 dio_truncate
-#Running read_checkzero
-#gread_checkzero
#Running dio_read
DOR000 dio_read -n 1 -i 100 -r 512k -w 512k -s 32M
DOR001 dio_read -n 10 -i 30 -r 512k -w 512k -s 32M
diff --git a/testcases/kernel/io/ltp-aiodio/.gitignore b/testcases/kernel/io/ltp-aiodio/.gitignore
index f5f20d57e..09a49bfbf 100644
--- a/testcases/kernel/io/ltp-aiodio/.gitignore
+++ b/testcases/kernel/io/ltp-aiodio/.gitignore
@@ -7,4 +7,3 @@
/dio_truncate
/dio_read
/dirty
-/read_checkzero
diff --git a/testcases/kernel/io/ltp-aiodio/read_checkzero.c b/testcases/kernel/io/ltp-aiodio/read_checkzero.c
deleted file mode 100644
index b48197a7b..000000000
--- a/testcases/kernel/io/ltp-aiodio/read_checkzero.c
+++ /dev/null
@@ -1,84 +0,0 @@
-/*
- * Copyright (c) 2004 Daniel McNeil <daniel@osdl.org>
- * 2004 Open Source Development Lab
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See
- * the GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
- *
- * Module: .c
- */
-
-/*
- * Change History:
- *
- * 2/2004 Marty Ridgeway (mridge@us.ibm.com) Changes to adapt to LTP
- *
- */
-#define _GNU_SOURCE
-
-#include <stdlib.h>
-#include <sys/types.h>
-#include <signal.h>
-#include <fcntl.h>
-#include <stdio.h>
-#include <unistd.h>
-
-#include "common_checkzero.h"
-
-int read_eof(char *filename)
-{
- int fd;
- int i;
- int r;
- char buf[4096];
-
- if ((fd = open(filename, O_RDWR)) < 0) {
- fprintf(stderr, "can't open file %s \n", filename);
- exit(1);
- }
-
- for (i = 0; i < 100000; i++) {
- off_t offset;
- char *bufoff;
-
- offset = lseek(fd, 4096, SEEK_END);
- r = write(fd, "A", 1);
-
- offset = lseek(fd, offset - 4096, SEEK_SET);
-
- r = read(fd, buf, 4096);
- if (r > 0) {
- if ((bufoff = check_zero(buf, r))) {
- fprintf(stderr, "non-zero read at offset %p\n",
- offset + bufoff);
- exit(1);
- }
- }
- }
- fprintf(stderr, "read_checkzero done\n");
- return 0;
-}
-
-int main(int argc, char **argv)
-{
- if (argc < 2) {
- printf("You must pass a filename to the test \n");
- exit(1);
- }
-
- char *filename = argv[1];
-
- read_eof(filename);
-
- return 0;
-}
--
2.35.1
More information about the ltp
mailing list