static int last_majdev, last_mindev;
static struct disk_util *last_du;
static struct fio_mutex *disk_util_mutex;
static int last_majdev, last_mindev;
static struct disk_util *last_du;
static struct fio_mutex *disk_util_mutex;
static struct disk_util *__init_per_file_disk_util(struct thread_data *td,
int majdev, int mindev, char *path);
static struct disk_util *__init_per_file_disk_util(struct thread_data *td,
int majdev, int mindev, char *path);
static void update_io_tick_disk(struct disk_util *du)
{
struct disk_util_stat __dus, *dus, *ldus;
static void update_io_tick_disk(struct disk_util *du)
{
struct disk_util_stat __dus, *dus, *ldus;
- sprintf(temppath, "%s%s%s", slavesdir, FIO_OS_PATH_SEPARATOR, dirent->d_name);
+ sprintf(temppath, "%s/%s", slavesdir, dirent->d_name);
/* Can we always assume that the slaves device entries
* are links to the real directories for the slave
* devices?
/* Can we always assume that the slaves device entries
* are links to the real directories for the slave
* devices?
- sprintf(temppath, "%s%s%s", slavesdir, FIO_OS_PATH_SEPARATOR, slavepath);
+ sprintf(temppath, "%s/%s", slavesdir, slavepath);
__init_per_file_disk_util(td, majdev, mindev, temppath);
slavedu = disk_util_exists(majdev, mindev);
__init_per_file_disk_util(td, majdev, mindev, temppath);
slavedu = disk_util_exists(majdev, mindev);
dprint(FD_DISKUTIL, "add maj/min %d/%d: %s\n", majdev, mindev, path);
du = smalloc(sizeof(*du));
dprint(FD_DISKUTIL, "add maj/min %d/%d: %s\n", majdev, mindev, path);
du = smalloc(sizeof(*du));
memset(du, 0, sizeof(*du));
INIT_FLIST_HEAD(&du->list);
memset(du, 0, sizeof(*du));
INIT_FLIST_HEAD(&du->list);
- sprintf(full_path, "%s%s%s", path, FIO_OS_PATH_SEPARATOR, dir->d_name);
+ sprintf(full_path, "%s/%s", path, dir->d_name);
if (!strcmp(dir->d_name, "dev")) {
if (!check_dev_match(majdev, mindev, full_path)) {
if (!strcmp(dir->d_name, "dev")) {
if (!check_dev_match(majdev, mindev, full_path)) {
strncpy(tmp, p, PATH_MAX - 1);
sprintf(path, "%s", tmp);
}
strncpy(tmp, p, PATH_MAX - 1);
sprintf(path, "%s", tmp);
}
return disk_util_add(td, majdev, mindev, path);
}
return disk_util_add(td, majdev, mindev, path);
}