diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/sg_dd.c | 6 | ||||
-rw-r--r-- | src/sg_read.c | 6 | ||||
-rw-r--r-- | src/sgm_dd.c | 6 | ||||
-rw-r--r-- | src/sgp_dd.c | 6 |
4 files changed, 12 insertions, 12 deletions
diff --git a/src/sg_dd.c b/src/sg_dd.c index cd8eb4b2..8392f31d 100644 --- a/src/sg_dd.c +++ b/src/sg_dd.c @@ -182,7 +182,7 @@ static long seed; static struct drand48_data drand;/* opaque, used by srand48_r and mrand48_r */ #endif -static const char * proc_allow_dio = "/proc/scsi/sg/allow_dio"; +static const char * sg_allow_dio = "/sys/module/sg/parameters/allow_dio"; struct flags_t { bool append; @@ -2733,11 +2733,11 @@ bypass_copy: pr2serr(">> Direct IO requested but incomplete %d times\n", dio_incomplete_count); - if ((fd = open(proc_allow_dio, O_RDONLY)) >= 0) { + if ((fd = open(sg_allow_dio, O_RDONLY)) >= 0) { if (1 == read(fd, &c, 1)) { if ('0' == c) pr2serr(">>> %s set to '0' but should be set to '1' for " - "direct IO\n", proc_allow_dio); + "direct IO\n", sg_allow_dio); } close(fd); } diff --git a/src/sg_read.c b/src/sg_read.c index 4c48b474..abeb4774 100644 --- a/src/sg_read.c +++ b/src/sg_read.c @@ -98,7 +98,7 @@ static int in_partial = 0; static int pack_id_count = 0; static int verbose = 0; -static const char * proc_allow_dio = "/proc/scsi/sg/allow_dio"; +static const char * sg_allow_dio = "/sys/module/sg/parameters/allow_dio"; static void @@ -916,11 +916,11 @@ main(int argc, char * argv[]) pr2serr(">> Direct IO requested but incomplete %d times\n", dio_incomplete); - if ((fd = open(proc_allow_dio, O_RDONLY)) >= 0) { + if ((fd = open(sg_allow_dio, O_RDONLY)) >= 0) { if (1 == read(fd, &c, 1)) { if ('0' == c) pr2serr(">>> %s set to '0' but should be set to '1' for " - "direct IO\n", proc_allow_dio); + "direct IO\n", sg_allow_dio); } close(fd); } diff --git a/src/sgm_dd.c b/src/sgm_dd.c index d85a6fa2..8c9723a1 100644 --- a/src/sgm_dd.c +++ b/src/sgm_dd.c @@ -126,7 +126,7 @@ static struct timeval start_tm; static int blk_sz = 0; static uint32_t glob_pack_id = 0; /* pre-increment */ -static const char * proc_allow_dio = "/proc/scsi/sg/allow_dio"; +static const char * sg_allow_dio = "/sys/module/sg/parameters/allow_dio"; struct flags_t { bool append; @@ -1285,11 +1285,11 @@ main(int argc, char * argv[]) int fd; char c; - if ((fd = open(proc_allow_dio, O_RDONLY)) >= 0) { + if ((fd = open(sg_allow_dio, O_RDONLY)) >= 0) { if (1 == read(fd, &c, 1)) { if ('0' == c) pr2serr(">>> %s set to '0' but should be set to '1' for " - "direct IO\n", proc_allow_dio); + "direct IO\n", sg_allow_dio); } close(fd); } diff --git a/src/sgp_dd.c b/src/sgp_dd.c index e88f3330..6a039f43 100644 --- a/src/sgp_dd.c +++ b/src/sgp_dd.c @@ -214,7 +214,7 @@ typedef struct request_element static sigset_t signal_set; static pthread_t sig_listen_thread_id; -static const char * proc_allow_dio = "/proc/scsi/sg/allow_dio"; +static const char * sg_allow_dio = "/sys/module/sg/parameters/allow_dio"; static void sg_in_operation(struct opts_t * clp, Rq_elem * rep); static void sg_out_operation(struct opts_t * clp, Rq_elem * rep, @@ -1991,11 +1991,11 @@ fini: pr2serr(">> Direct IO requested but incomplete %d times\n", clp->dio_incomplete_count); - if ((fd = open(proc_allow_dio, O_RDONLY)) >= 0) { + if ((fd = open(sg_allow_dio, O_RDONLY)) >= 0) { if (1 == read(fd, &c, 1)) { if ('0' == c) pr2serr(">>> %s set to '0' but should be set to '1' for " - "direct IO\n", proc_allow_dio); + "direct IO\n", sg_allow_dio); } close(fd); } |