diff --git a/casadm/cas_lib_utils.c b/casadm/cas_lib_utils.c index b3ef085..da82788 100644 --- a/casadm/cas_lib_utils.c +++ b/casadm/cas_lib_utils.c @@ -469,12 +469,23 @@ int run_ioctl_interruptible(int fd, int command, void *cmd, } /* - * @brief ioctl wrapper that retries ioctl attempts within one second timeouts + * @brief ioctl wrapper * @param[in] fd as for IOCTL(2) * @param[in] command as for IOCTL(2) * @param[inout] cmd_info as for IOCTL(2) */ int run_ioctl(int fd, int command, void *cmd) +{ + return ioctl(fd, command, cmd); +} + +/* + * @brief ioctl wrapper that retries ioctl attempts within one second timeouts + * @param[in] fd as for IOCTL(2) + * @param[in] command as for IOCTL(2) + * @param[inout] cmd_info as for IOCTL(2) + */ +int run_ioctl_retry(int fd, int command, void *cmd) { int i, ret; struct timespec timeout = { diff --git a/casadm/cas_lib_utils.h b/casadm/cas_lib_utils.h index b707da8..77a9bf7 100644 --- a/casadm/cas_lib_utils.h +++ b/casadm/cas_lib_utils.h @@ -28,6 +28,7 @@ struct progress_status { void init_progress_bar(struct progress_status *ps); void print_progress_bar_or_indicator(float prog, struct progress_status *ps); int run_ioctl(int fd, int command, void *cmd); +int run_ioctl_retry(int fd, int command, void *cmd); int run_ioctl_interruptible(int fd, int command, void *cmd, char *friendly_name, int cache_id, int core_id); int open_ctrl_device();