public inbox for linux-serial@vger.kernel.org
 help / color / mirror / Atom feed
From: Arnd Bergmann <arnd@arndb.de>
To: Alan Cox <alan@lxorguk.ukuu.org.uk>
Cc: linux-kernel@vger.kernel.org, linux-serial@vger.kernel.org
Subject: Re: [PATCH 2/6] vt: push down the tty lock so we can see what is left to tackle
Date: Thu, 1 Mar 2012 21:51:20 +0000	[thread overview]
Message-ID: <201203012151.20940.arnd@arndb.de> (raw)
In-Reply-To: <20120301195005.11322.78572.stgit@bob.linux.org.uk>

On Thursday 01 March 2012, Alan Cox wrote:
> @@ -1407,6 +1425,7 @@ int vt_move_to_console(unsigned int vt, int alloc)
>                 return -EIO;
>         }
>         console_unlock();
> +       /* Review: I don't see why we need tty_lock here FIXME */
>         tty_lock();
>         if (vt_waitactive(vt + 1)) {
>                 pr_debug("Suspend: Can't switch VCs.");

I'm pretty sure I only added this in be1bc288 "tty: introduce
wait_event_interruptible_tty" so I could release the mutex again in
vt_event_wait.

All other callers of that function hold it, so it needs to be released
in vt_event_wait and that can only be done if it's known to be held first.

	Arnd

  parent reply	other threads:[~2012-03-01 21:51 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-03-01 19:49 [PATCH 0/6] Remove tty_lock from the console drivers Alan Cox
2012-03-01 19:49 ` [PATCH 1/6] vt: sort out locking for font handling Alan Cox
2012-03-01 19:50 ` [PATCH 2/6] vt: push down the tty lock so we can see what is left to tackle Alan Cox
2012-03-01 20:31   ` Jiri Slaby
2012-03-01 21:51   ` Arnd Bergmann [this message]
2012-03-01 19:51 ` [PATCH 3/6] vt: push down tioclinux cases Alan Cox
2012-03-01 19:51 ` [PATCH 4/6] vt: waitevent is self locked so drop the tty_lock Alan Cox
2012-03-01 19:52 ` [PATCH 5/6] vt: tackle the main part of the selection logic Alan Cox
2012-03-01 19:52 ` [PATCH 6/6] vt: push the tty_lock down into the map handling Alan Cox
2012-03-01 22:10 ` [PATCH 0/6] Remove tty_lock from the console drivers Arnd Bergmann
  -- strict thread matches above, loose matches on Subject: below --
2012-03-02 14:58 [PATCH 0/6] Series short description Alan Cox
2012-03-02 14:59 ` [PATCH 2/6] vt: push down the tty lock so we can see what is left to tackle Alan Cox

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=201203012151.20940.arnd@arndb.de \
    --to=arnd@arndb.de \
    --cc=alan@lxorguk.ukuu.org.uk \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-serial@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox