Subject: Re: [PATCH 1/2] proc: revalidate directories created with proc_net_mkdir()

From: Alexey Dobriyan <[email-masked]>
Date: Sun, 7 Jul 2019 11:03:51 +0300

On Sun, Jul 07, 2019 at 02:03:20AM +0100, Al Viro wrote:
> On Sat, Jul 06, 2019 at 07:52:02PM +0300, Alexey Dobriyan wrote:
> > +struct proc_dir_entry *_proc_mkdir(const char *name, umode_t mode,
> > +				   struct proc_dir_entry **parent, void *data)
> 
> 	Two underscores, please...

Second underscore is more typing, I never understood it.

> > +	parent->nlink++;
> > +	pde = proc_register(parent, pde);
> > +	if (!pde)
> > +		parent->nlink++;
> 
> 	Really?

And ->nlink is a separate bug.