1. 23 10月, 2012 5 次提交
  2. 27 9月, 2012 2 次提交
    • A
      make get_file() return its argument · cb0942b8
      Al Viro 提交于
      simplifies a bunch of callers...
      Signed-off-by: NAl Viro <viro@zeniv.linux.org.uk>
      cb0942b8
    • A
      new helper: iterate_fd() · c3c073f8
      Al Viro 提交于
      iterates through the opened files in given descriptor table,
      calling a supplied function; we stop once non-zero is returned.
      Callback gets struct file *, descriptor number and const void *
      argument passed to iterator.  It is called with files->file_lock
      held, so it is not allowed to block.
      
      tty_io, netprio_cgroup and selinux flush_unauthorized_files()
      converted to its use.
      Signed-off-by: NAl Viro <viro@zeniv.linux.org.uk>
      c3c073f8
  3. 07 9月, 2012 2 次提交
  4. 06 9月, 2012 1 次提交
  5. 17 8月, 2012 1 次提交
  6. 14 8月, 2012 3 次提交
  7. 11 8月, 2012 4 次提交
  8. 28 7月, 2012 1 次提交
    • A
      tty: Fix race in tty release · d155255a
      Alan Cox 提交于
      Ian Abbott found that the tty layer would explode with the right set of
      parallel open and close operations. This is because we race in the
      handling of tty->drivers->termios[].
      
      Correct this by
      	Making tty_ldisc_release behave like nromal code (takes the lock,
      			does stuff, drops the lock)
      	Drop the tty lock earlier in tty_ldisc_release
      	Taking the tty mutex around the driver->termios update in all cases
      	Adding a WARN_ON to catch future screwups.
      
      I also forgot to clean up the pty resources properly. With a pty pair we
      need to pull both halves out of the tables.
      Signed-off-by: NAlan Cox <alan@linux.intel.com>
      Tested-by: NIan Abbott <abbotti@mev.co.uk>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      d155255a
  9. 18 7月, 2012 1 次提交
  10. 17 7月, 2012 2 次提交
  11. 07 7月, 2012 1 次提交
    • A
      tty: localise the lock · f5e3bcc5
      Alan Cox 提交于
      The termios and other changes mean the other protections needed on the driver
      tty arrays should be adequate. Turn it all back on.
      
      This contains pieces folded in from the fixes made to the original patches
      
      | From: Geert Uytterhoeven <geert@linux-m68k.org>	(fix m68k)
      | From: Paul Gortmaker <paul.gortmaker@windriver.com>	(fix cris)
      | From: Jiri Kosina <jkosina@suze.cz>			(lockdep)
      | From: Eric Dumazet <eric.dumazet@gmail.com>		(lockdep)
      Signed-off-by: NAlan Cox <alan@linux.intel.com>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      f5e3bcc5
  12. 14 6月, 2012 2 次提交
  13. 03 6月, 2012 1 次提交
    • L
      tty: Revert the tty locking series, it needs more work · f309532b
      Linus Torvalds 提交于
      This reverts the tty layer change to use per-tty locking, because it's
      not correct yet, and fixing it will require some more deep surgery.
      
      The main revert is d29f3ef3 ("tty_lock: Localise the lock"), but
      there are several smaller commits that built upon it, they also get
      reverted here. The list of reverted commits is:
      
        fde86d31 - tty: add lockdep annotations
        8f6576ad - tty: fix ldisc lock inversion trace
        d3ca8b64 - pty: Fix lock inversion
        b1d679af - tty: drop the pty lock during hangup
        abcefe5f - tty/amiserial: Add missing argument for tty_unlock()
        fd11b42e - cris: fix missing tty arg in wait_event_interruptible_tty call
        d29f3ef3 - tty_lock: Localise the lock
      
      The revert had a trivial conflict in the 68360serial.c staging driver
      that got removed in the meantime.
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      f309532b
  14. 05 5月, 2012 2 次提交
  15. 29 3月, 2012 1 次提交
  16. 09 3月, 2012 4 次提交
  17. 25 2月, 2012 1 次提交
  18. 03 2月, 2012 2 次提交
  19. 25 1月, 2012 1 次提交
    • K
      tty: cleanup prohibition of direct opening for unix98 pty master · 593a27c4
      Konstantin Khlebnikov 提交于
      cleanup hack added in v2.6.27-3203-g15582d36
      
      comment from that patch:
      
      : pty: If the administrator creates a device for a ptmx slave we should not error
      :
      : The open path for ptmx slaves is via the ptmx device. Opening them any
      : other way is not allowed. Vegard Nossum found that previously this was not
      : the case and mknod foo c 128 42; cat foo would produce nasty diagnostics
      :
      : Signed-off-by: Alan Cox <alan@redhat.com>
      : Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
      
      devpts_get_tty() returns non-null only for inodes on devpts, but there is no
      inodes for master-devices, /dev/ptmx (/dev/pts/ptmx) is the only way to open them.
      Thus we can completely forbid lookup for master-devices and eliminate that hack in
      tty_init_dev() because tty_open() will get EIO from tty_driver_lookup_tty().
      Signed-off-by: NKonstantin Khlebnikov <khlebnikov@openvz.org>
      Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
      593a27c4
  20. 04 1月, 2012 1 次提交
  21. 16 11月, 2011 2 次提交