This commit was manufactured by cvs2svn to create branch 'vserver'.
[linux-2.6.git] / include / linux / tty_driver.h
index bbf6a38..58c961c 100644 (file)
@@ -17,7 +17,7 @@
  *
  *     This routine is called when a particular tty device is closed.
  *
- * int (*write)(struct tty_struct * tty, int from_user,
+ * int (*write)(struct tty_struct * tty,
  *              const unsigned char *buf, int count);
  *
  *     This routine is called by the kernel to write a series of
@@ -124,7 +124,7 @@ struct tty_struct;
 struct tty_operations {
        int  (*open)(struct tty_struct * tty, struct file * filp);
        void (*close)(struct tty_struct * tty, struct file * filp);
-       int  (*write)(struct tty_struct * tty, int from_user,
+       int  (*write)(struct tty_struct * tty,
                      const unsigned char *buf, int count);
        void (*put_char)(struct tty_struct *tty, unsigned char ch);
        void (*flush_chars)(struct tty_struct *tty);
@@ -157,7 +157,6 @@ struct tty_driver {
        struct cdev cdev;
        struct module   *owner;
        const char      *driver_name;
-       const char      *devfs_name;
        const char      *name;
        int     name_base;      /* offset of printed name */
        int     major;          /* major device number */
@@ -186,7 +185,7 @@ struct tty_driver {
         */
        int  (*open)(struct tty_struct * tty, struct file * filp);
        void (*close)(struct tty_struct * tty, struct file * filp);
-       int  (*write)(struct tty_struct * tty, int from_user,
+       int  (*write)(struct tty_struct * tty,
                      const unsigned char *buf, int count);
        void (*put_char)(struct tty_struct *tty, unsigned char ch);
        void (*flush_chars)(struct tty_struct *tty);
@@ -242,8 +241,15 @@ void tty_set_operations(struct tty_driver *driver, struct tty_operations *op);
  *     is also a promise, if the above case is true, not to signal
  *     overruns, either.)
  *
- * TTY_DRIVER_NO_DEVFS --- if set, do not create devfs entries. This
- *     is only used by tty_register_driver().
+ * TTY_DRIVER_DYNAMIC_DEV --- if set, the individual tty devices need
+ *     to be registered with a call to tty_register_driver() when the
+ *     device is found in the system and unregistered with a call to
+ *     tty_unregister_device() so the devices will be show up
+ *     properly in sysfs.  If not set, driver->num entries will be
+ *     created by the tty core in sysfs when tty_register_driver() is
+ *     called.  This is to be used by drivers that have tty devices
+ *     that can appear and disappear while the main tty driver is
+ *     registered with the tty core.
  *
  * TTY_DRIVER_DEVPTS_MEM -- don't use the standard arrays, instead
  *     use dynamic memory keyed through the devpts filesystem.  This
@@ -252,7 +258,7 @@ void tty_set_operations(struct tty_driver *driver, struct tty_operations *op);
 #define TTY_DRIVER_INSTALLED           0x0001
 #define TTY_DRIVER_RESET_TERMIOS       0x0002
 #define TTY_DRIVER_REAL_RAW            0x0004
-#define TTY_DRIVER_NO_DEVFS            0x0008
+#define TTY_DRIVER_DYNAMIC_DEV         0x0008
 #define TTY_DRIVER_DEVPTS_MEM          0x0010
 
 /* tty driver types */