move ioctl to generic syscalls