Lines Matching refs:mtfd
44 static int print_config(int mtfd);
47 static int status(int mtfd, struct mtget *);
93 int mtfd; in main() local
127 mtfd = open(tape, comp->c_oflag); in main()
128 if (mtfd < 0) { in main()
153 if (ioctl(mtfd, comp->c_code) < 0) { in main()
173 (void) ioctl(mtfd, MTIOCGET, (char *)&mt_status); in main()
174 if (ioctl(mtfd, MTIOCGET, (char *)&mt_status) < 0) { in main()
190 if (ioctl(mtfd, MTIOCLTOP, &mt_com) < 0) { in main()
209 if (ioctl(mtfd, MTIOCLTOP, &mt_com) < 0) { in main()
216 return (print_config(mtfd)); in main()
230 if (ioctl(mtfd, MTIOCLTOP, &mt_com) < 0) { in main()
253 if (ioctl(mtfd, MTIOCGET, (char *)&mt_status) < 0) { in main()
257 return (status(mtfd, &mt_status)); in main()
263 print_config(int mtfd) in print_config() argument
275 if (ioctl(mtfd, MTIOCGETDRIVETYPE, &mdt_req) != 0) { in print_config()
346 status(int mtfd, struct mtget *bp) in status() argument
359 if (ioctl(mtfd, MTIOCGETDRIVETYPE, &mdt_req) == 0) { in status()