Modify *run_ioctl* function
Make *run_ioctl* a simple wrapper for *ioctl* function. *run_ioctl_retry* is old *run_ioctl* function. Signed-off-by: Slawomir Jankowski <slawomir.jankowski@intel.com>
This commit is contained in:
parent
606c4ea8f6
commit
0d1730af37
@ -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] fd as for IOCTL(2)
|
||||||
* @param[in] command as for IOCTL(2)
|
* @param[in] command as for IOCTL(2)
|
||||||
* @param[inout] cmd_info as for IOCTL(2)
|
* @param[inout] cmd_info as for IOCTL(2)
|
||||||
*/
|
*/
|
||||||
int run_ioctl(int fd, int command, void *cmd)
|
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;
|
int i, ret;
|
||||||
struct timespec timeout = {
|
struct timespec timeout = {
|
||||||
|
@ -28,6 +28,7 @@ struct progress_status {
|
|||||||
void init_progress_bar(struct progress_status *ps);
|
void init_progress_bar(struct progress_status *ps);
|
||||||
void print_progress_bar_or_indicator(float prog, 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(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,
|
int run_ioctl_interruptible(int fd, int command, void *cmd,
|
||||||
char *friendly_name, int cache_id, int core_id);
|
char *friendly_name, int cache_id, int core_id);
|
||||||
int open_ctrl_device();
|
int open_ctrl_device();
|
||||||
|
Loading…
Reference in New Issue
Block a user