tty: Document required behavior of tty driver close()
authorPeter Hurley <peter@hurleysoftware.com>
Wed, 30 Jan 2013 17:43:51 +0000 (12:43 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 4 Feb 2013 23:40:28 +0000 (15:40 -0800)
If the tty driver open() fails, the tty driver close() is still
called during the resultant tty release.

Signed-off-by: Peter Hurley <peter@hurleysoftware.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
include/linux/tty_driver.h

index dd976cf..756a609 100644 (file)
@@ -40,6 +40,7 @@
  * void (*close)(struct tty_struct * tty, struct file * filp);
  *
  *     This routine is called when a particular tty device is closed.
+ *     Note: called even if the corresponding open() failed.
  *
  *     Required method.
  *