OpenCores
URL https://opencores.org/ocsvn/or1k_old/or1k_old/trunk

Subversion Repositories or1k_old

[/] [or1k_old/] [trunk/] [rc203soc/] [sw/] [uClinux/] [include/] [linux/] [tty_ldisc.h] - Blame information for rev 1782

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 1633 jcastillo
#ifndef _LINUX_TTY_LDISC_H
2
#define _LINUX_TTY_LDISC_H
3
 
4
/*
5
 * Definitions for the tty line discipline
6
 */
7
 
8
#include <linux/fs.h>
9
#include <linux/wait.h>
10
 
11
struct tty_ldisc {
12
        int     magic;
13
        int     num;
14
        int     flags;
15
        /*
16
         * The following routines are called from above.
17
         */
18
        int     (*open)(struct tty_struct *);
19
        void    (*close)(struct tty_struct *);
20
        void    (*flush_buffer)(struct tty_struct *tty);
21
        int     (*chars_in_buffer)(struct tty_struct *tty);
22
        int     (*read)(struct tty_struct * tty, struct file * file,
23
                        unsigned char * buf, unsigned int nr);
24
        int     (*write)(struct tty_struct * tty, struct file * file,
25
                         const unsigned char * buf, unsigned int nr);
26
        int     (*ioctl)(struct tty_struct * tty, struct file * file,
27
                         unsigned int cmd, unsigned long arg);
28
        void    (*set_termios)(struct tty_struct *tty, struct termios * old);
29
        int     (*select)(struct tty_struct * tty, struct inode * inode,
30
                          struct file * file, int sel_type,
31
                          struct select_table_struct *wait);
32
 
33
        /*
34
         * The following routines are called from below.
35
         */
36
        void    (*receive_buf)(struct tty_struct *, const unsigned char *cp,
37
                               char *fp, int count);
38
        int     (*receive_room)(struct tty_struct *);
39
        void    (*write_wakeup)(struct tty_struct *);
40
};
41
 
42
#define TTY_LDISC_MAGIC 0x5403
43
 
44
#define LDISC_FLAG_DEFINED      0x00000001
45
 
46
#endif /* _LINUX_TTY_LDISC_H */

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.