ioctl.c 365 B

123456789101112131415161718
  1. #include <stdarg.h>
  2. #include <sys/ioctl.h>
  3. extern int __syscall_ioctl(int fd, int request, void *arg);
  4. /* powerpc has its own special version... */
  5. int ioctl(int fd, unsigned long int request, ...)
  6. {
  7. void *arg;
  8. va_list list;
  9. va_start(list, request);
  10. arg = va_arg(list, void *);
  11. va_end(list);
  12. return __syscall_ioctl(fd, request, arg);
  13. }