The Ftape Installation and Usage Guide - Ioctls
The purpose of this ioctl is to allow the major part of the formatting procedure to take place in user space rather than in the kernel level device driver. Please refer for to the comments in the code fragment below for the meaning of the components of the structure. Command definitions as used by ftape can be found in [/usr/src/ftape-4.03/]include/linux/qic117.h.
The ftformat
program (see ftformat) uses this ioctl.
struct mtftcmd { unsigned int ft_wait_before; /* timeout to wait for drive to get ready * before command is sent. Milliseconds */ qic117_cmd_t ft_cmd; /* command to send */ unsigned char ft_parm_cnt; /* zero: no parm is sent. */ unsigned char ft_parms[3]; /* parameter(s) to send to * the drive. The parms are nibbles * driver sends cmd + 2 step pulses */ unsigned int ft_result_bits; /* if non zero, number of bits * returned by the tape drive */ unsigned int ft_result; /* the result returned by the tape drive*/ unsigned int ft_wait_after; /* timeout to wait for drive to get ready * after command is sent. 0: don't wait */ int ft_status; /* status returned by ready wait * undefined if timeout was 0. */ int ft_error; /* error code if error status was set by * command */ }; #define MTIOCFTCMD _IOWR('m', 11, struct mtftcmd) /* send QIC-117 cmd */
![]() |
Use these buttons to jump to the top menu |