lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <AM6PR08MB43769965CAF732F1DEA4A37AF75E9@AM6PR08MB4376.eurprd08.prod.outlook.com>
Date:   Fri, 30 Apr 2021 03:17:02 +0000
From:   Justin He <Justin.He@....com>
To:     Linus Torvalds <torvalds@...ux-foundation.org>,
        Rasmus Villemoes <linux@...musvillemoes.dk>
CC:     Christoph Hellwig <hch@....de>,
        "Darrick J. Wong" <djwong@...nel.org>,
        Al Viro <viro@...iv.linux.org.uk>,
        linux-fsdevel <linux-fsdevel@...r.kernel.org>,
        linux-xfs <linux-xfs@...r.kernel.org>,
        Dave Chinner <david@...morbit.com>,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
        Eric Sandeen <sandeen@...deen.net>,
        Andy Shevchenko <andy.shevchenko@...il.com>
Subject: RE: [GIT PULL] iomap: new code for 5.13-rc1

Hi

> -----Original Message-----
> From: Linus Torvalds <torvalds@...ux-foundation.org>
> Sent: Friday, April 30, 2021 12:46 AM
> To: Rasmus Villemoes <linux@...musvillemoes.dk>
> Cc: Christoph Hellwig <hch@....de>; Darrick J. Wong <djwong@...nel.org>;
> Justin He <Justin.He@....com>; Al Viro <viro@...iv.linux.org.uk>; linux-
> fsdevel <linux-fsdevel@...r.kernel.org>; linux-xfs <linux-
> xfs@...r.kernel.org>; Dave Chinner <david@...morbit.com>; Linux Kernel
> Mailing List <linux-kernel@...r.kernel.org>; Eric Sandeen
> <sandeen@...deen.net>; Andy Shevchenko <andy.shevchenko@...il.com>
> Subject: Re: [GIT PULL] iomap: new code for 5.13-rc1
>
> On Wed, Apr 28, 2021 at 11:40 PM Rasmus Villemoes
> <linux@...musvillemoes.dk> wrote:
> >
> > > That also does explain the arguably odd %pD defaults: %pd came first,
> > > and then %pD came afterwards.
> >
> > Eh? 4b6ccca701ef5977d0ffbc2c932430dea88b38b6 added them both at the same
> > time.
>
> Ahh, I looked at "git blame", and saw that file_dentry_name() was
> added later. But that turns out to have been an additional fix on top,
> not actually "later support".
>
> Looking more at that code, I am starting to think that
> "file_dentry_name()" simply shouldn't use "dentry_name()" at all.
> Despite that shared code origin, and despite that similar letter
> choice (lower-vs-upper case), a dentry and a file really are very very
> different from a name standpoint.
>
> And it's not the "a filename is the whale pathname, and a dentry has
> its own private dentry name" issue. It's really that the 'struct file'
> contains a _path_ - which is not just the dentry pointer, but the
> 'struct vfsmount' pointer too.
>
> So '%pD' really *could* get the real path right (because it has all
> the required information) in ways that '%pd' fundamentally cannot.
>
> At the same time, I really don't like printk specifiers to take any
> real locks (ie mount_lock or rename_lock), so I wouldn't want them to
> use the full  d_path() logic.

Is it a good idea to introduce a new d_path_nolock() for file_dentry_name()?
In d_path_nolock(), if it detects that there is conflicts with mount_lock
or rename_lock, then returned NULL as a name of that vfsmount?

Thanks for further suggestion.

--
Cheers,
Justin (Jia He)


IMPORTANT NOTICE: The contents of this email and any attachments are confidential and may also be privileged. If you are not the intended recipient, please notify the sender immediately and do not disclose the contents to any other person, use it for any purpose, or store or copy the information in any medium. Thank you.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ