Re: [PATCH] tty: remove recursive implementation of tty_ldisc_release
From: Ming Lei
Date: Fri May 25 2012 - 22:46:29 EST
On Fri, May 25, 2012 at 7:11 PM, Alan Cox <alan@xxxxxxxxxxxxxxxxxxx> wrote:
> From: Alan Cox <alan@xxxxxxxxxxxxxxx>
>
> We need to do this in one pass with the locking requirements we now
> have.
>
> Signed-off-by: Alan Cox <alan@xxxxxxxxxxxxxxx>
> ---
>
> drivers/tty/tty_ldisc.c | 40 +++++++++++++++++++++++-----------------
> 1 files changed, 23 insertions(+), 17 deletions(-)
>
>
> diff --git a/drivers/tty/tty_ldisc.c b/drivers/tty/tty_ldisc.c
> index 833e851..ecfaef5 100644
> --- a/drivers/tty/tty_ldisc.c
> +++ b/drivers/tty/tty_ldisc.c
> @@ -894,6 +894,23 @@ int tty_ldisc_setup(struct tty_struct *tty, struct tty_struct *o_tty)
> tty_ldisc_enable(tty);
> return 0;
> }
> +
> +static int tty_ldisc_kill(struct tty_struct *tty)
Maybe the return type should be defined as void to avoid compile warning.
After applying Alan's three patches for addressing tty locks and the patch
int the below link:
http://marc.info/?l=linux-kernel&m=133775308420817&w=2
Looks no lockdep warnings are triggered any more when running
'exit' in shell of ssh session.
So I will send out the formal patch in the above link.
Thanks,
--
Ming Lei
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/