Re: [PATCHv5 1/7] tty: Drop tty->count on tty_reopen() failure

From: Dmitry Safonov
Date: Tue Sep 18 2018 - 10:15:15 EST


On Tue, 2018-09-18 at 15:41 +0200, Greg Kroah-Hartman wrote:
> On Tue, Sep 18, 2018 at 12:52:52AM +0100, Dmitry Safonov wrote:
> > In case of tty_ldisc_reinit() failure, tty->count should be
> > decremented
> > back, otherwise we will never release_tty().
> > Tetsuo reported that it fixes noisy warnings on tty release like:
> > pts pts4033: tty_release: tty->count(10529) != (#fd's(7) +
> > #kopen's(0))
> >
> > Fixes: commit 892d1fa7eaae ("tty: Destroy ldisc instance on
> > hangup")
> >
>
> Minor nit, no need to have "commit" in this line, it's implied.
>
> Also, no need to put an extra line here either.
>
> I'll queue this patch up now, have some question about the rest...

Thanks, Greg, will have in mind further.

--
Dima