Recent changes

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The following changes since commit f2e714707b27f5918a4020e3090d2b346094379c:

  Fio 1.53 (2011-05-05 12:07:24 -0600)

are available in the git repository at:
  git://git.kernel.dk/fio.git master

Jens Axboe (5):
      Fix signed int/long truncation on 32-bit architectures
      Constify l_opts strings
      Ensure we quit on SIGTERM
      Revert "Constify l_opts strings"
      Cast l_opts string names to char *

 filesetup.c |    2 +-
 fio.c       |    9 +--------
 init.c      |   32 ++++++++++++++++----------------
 io_u.c      |    6 +++---
 trim.c      |    2 +-
 5 files changed, 22 insertions(+), 29 deletions(-)

---

Diff of recent changes:

diff --git a/filesetup.c b/filesetup.c
index 2b690c8..1350857 100644
--- a/filesetup.c
+++ b/filesetup.c
@@ -208,7 +208,7 @@ static int pre_read_file(struct thread_data *td, struct fio_file *f)
 static unsigned long long get_rand_file_size(struct thread_data *td)
 {
 	unsigned long long ret, sized;
-	long r;
+	unsigned long r;
 
 	if (td->o.use_os_rand) {
 		r = os_random_long(&td->file_size_state);
diff --git a/fio.c b/fio.c
index 284e9f2..76c6ebd 100644
--- a/fio.c
+++ b/fio.c
@@ -114,13 +114,6 @@ static void terminate_threads(int group_id)
 	}
 }
 
-/*
- * Happens on thread runs with ctrl-c, ignore our own SIGQUIT
- */
-static void sig_quit(int sig)
-{
-}
-
 static void sig_int(int sig)
 {
 	if (threads) {
@@ -178,7 +171,7 @@ static void set_sig_handlers(void)
 	sigaction(SIGINT, &act, NULL);
 
 	memset(&act, 0, sizeof(act));
-	act.sa_handler = sig_quit;
+	act.sa_handler = sig_int;
 	act.sa_flags = SA_RESTART;
 	sigaction(SIGTERM, &act, NULL);
 }
diff --git a/init.c b/init.c
index 6382666..37e0c48 100644
--- a/init.c
+++ b/init.c
@@ -64,82 +64,82 @@ static char cmd_optstr[256];
  */
 static struct option l_opts[FIO_NR_OPTIONS] = {
 	{
-		.name		= "output",
+		.name		= (char *) "output",
 		.has_arg	= required_argument,
 		.val		= 'o',
 	},
 	{
-		.name		= "timeout",
+		.name		= (char *) "timeout",
 		.has_arg	= required_argument,
 		.val		= 't',
 	},
 	{
-		.name		= "latency-log",
+		.name		= (char *) "latency-log",
 		.has_arg	= required_argument,
 		.val		= 'l',
 	},
 	{
-		.name		= "bandwidth-log",
+		.name		= (char *) "bandwidth-log",
 		.has_arg	= required_argument,
 		.val		= 'b',
 	},
 	{
-		.name		= "minimal",
+		.name		= (char *) "minimal",
 		.has_arg	= optional_argument,
 		.val		= 'm',
 	},
 	{
-		.name		= "version",
+		.name		= (char *) "version",
 		.has_arg	= no_argument,
 		.val		= 'v',
 	},
 	{
-		.name		= "help",
+		.name		= (char *) "help",
 		.has_arg	= no_argument,
 		.val		= 'h',
 	},
 	{
-		.name		= "cmdhelp",
+		.name		= (char *) "cmdhelp",
 		.has_arg	= optional_argument,
 		.val		= 'c',
 	},
 	{
-		.name		= "showcmd",
+		.name		= (char *) "showcmd",
 		.has_arg	= no_argument,
 		.val		= 's',
 	},
 	{
-		.name		= "readonly",
+		.name		= (char *) "readonly",
 		.has_arg	= no_argument,
 		.val		= 'r',
 	},
 	{
-		.name		= "eta",
+		.name		= (char *) "eta",
 		.has_arg	= required_argument,
 		.val		= 'e',
 	},
 	{
-		.name		= "debug",
+		.name		= (char *) "debug",
 		.has_arg	= required_argument,
 		.val		= 'd',
 	},
 	{
-		.name		= "section",
+		.name		= (char *) "section",
 		.has_arg	= required_argument,
 		.val		= 'x',
 	},
 	{
-		.name		= "alloc-size",
+		.name		= (char *) "alloc-size",
 		.has_arg	= required_argument,
 		.val		= 'a',
 	},
 	{
-		.name		= "profile",
+		.name		= (char *) "profile",
 		.has_arg	= required_argument,
 		.val		= 'p',
 	},
 	{
-		.name		= "warnings-fatal",
+		.name		= (char *) "warnings-fatal",
 		.has_arg	= no_argument,
 		.val		= 'w',
 	},
diff --git a/io_u.c b/io_u.c
index 787f382..d35b844 100644
--- a/io_u.c
+++ b/io_u.c
@@ -346,7 +346,7 @@ static unsigned int __get_next_buflen(struct thread_data *td, struct io_u *io_u)
 	const int ddir = io_u->ddir;
 	unsigned int uninitialized_var(buflen);
 	unsigned int minbs, maxbs;
-	long r, rand_max;
+	unsigned long r, rand_max;
 
 	assert(ddir_rw(ddir));
 
@@ -423,7 +423,7 @@ static void set_rwmix_bytes(struct thread_data *td)
 static inline enum fio_ddir get_rand_ddir(struct thread_data *td)
 {
 	unsigned int v;
-	long r;
+	unsigned long r;
 
 	if (td->o.use_os_rand) {
 		r = os_random_long(&td->rwmix_state);
@@ -849,7 +849,7 @@ static struct fio_file *get_next_file_rand(struct thread_data *td,
 
 	do {
 		int opened = 0;
-		long r;
+		unsigned long r;
 
 		if (td->o.use_os_rand) {
 			r = os_random_long(&td->next_file_state);
diff --git a/trim.c b/trim.c
index a9b15d6..de792dc 100644
--- a/trim.c
+++ b/trim.c
@@ -70,7 +70,7 @@ int get_next_trim(struct thread_data *td, struct io_u *io_u)
 int io_u_should_trim(struct thread_data *td, struct io_u *io_u)
 {
 	unsigned long long val;
-	long r;
+	unsigned long r;
 
 	if (!td->o.trim_percentage)
 		return 0;
--
To unsubscribe from this list: send the line "unsubscribe fio" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel]     [Linux SCSI]     [Linux IDE]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux SCSI]

  Powered by Linux