Exemplo n.º 1
0
Arquivo: pty.c Projeto: Lyude/linux
static long pty_bsd_compat_ioctl(struct tty_struct *tty,
				 unsigned int cmd, unsigned long arg)
{
	/*
	 * PTY ioctls don't require any special translation between 32-bit and
	 * 64-bit userspace, they are already compatible.
	 */
	return pty_bsd_ioctl(tty, cmd, arg);
}
Exemplo n.º 2
0
static int pty_unix98_ioctl(struct tty_struct *tty, struct file *file,
			    unsigned int cmd, unsigned long arg)
{
	if (!tty) {
		printk("pty_unix98_ioctl called with NULL tty!\n");
		return -EIO;
	}
	switch(cmd) {
	case TIOCGPTN: /* Get PT Number */
		return pty_get_device_number(tty, (unsigned int *)arg);
	}

	return pty_bsd_ioctl(tty,file,cmd,arg);
}