From: Linus Walleij <linus.walleij@linaro.org>
To: Dave Martin <Dave.Martin@arm.com>
Cc: "Theodore Ts'o" <tytso@mit.edu>,
Andreas Dilger <adilger.kernel@dilger.ca>,
Ext4 Developers List <linux-ext4@vger.kernel.org>,
linux-fsdevel <linux-fsdevel@vger.kernel.org>,
Linux API <linux-api@vger.kernel.org>,
QEMU Developers <qemu-devel@nongnu.org>,
Florian Weimer <fw@deneb.enyo.de>,
Peter Maydell <peter.maydell@linaro.org>,
Andy Lutomirski <luto@kernel.org>
Subject: Re: [PATCH v3 RESEND] fcntl: Add 32bit filesystem mode
Date: Wed, 18 Nov 2020 00:38:41 +0100 [thread overview]
Message-ID: <CACRpkdZoMoUQX+CPd31qwjXSKJvaZ6=jcFvUrK_3hkxaUWJNJg@mail.gmail.com> (raw)
In-Reply-To: <20201013092240.GI32292@arm.com>
On Tue, Oct 13, 2020 at 11:22 AM Dave Martin <Dave.Martin@arm.com> wrote:
> > case F_SETFD:
> > err = 0;
> > set_close_on_exec(fd, arg & FD_CLOEXEC);
> > + if (arg & FD_32BIT_MODE)
> > + filp->f_mode |= FMODE_32BITHASH;
> > + else
> > + filp->f_mode &= ~FMODE_32BITHASH;
>
> This seems inconsistent? F_SETFD is for setting flags on a file
> descriptor. Won't setting a flag on filp here instead cause the
> behaviour to change for all file descriptors across the system that are
> open on this struct file? Compare set_close_on_exec().
>
> I don't see any discussion on whether this should be an F_SETFL or an
> F_SETFD, though I see F_SETFD was Ted's suggestion originally.
I cannot honestly say I know the semantic difference.
I would ask the QEMU people how a user program would expect
the flag to behave.
Yours,
Linus Walleij
next prev parent reply other threads:[~2020-11-17 23:39 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-10-12 22:06 [PATCH v3 RESEND] fcntl: Add 32bit filesystem mode Linus Walleij
2020-10-13 0:08 ` Eric Blake
2020-10-13 9:22 ` Dave Martin
2020-11-17 23:38 ` Linus Walleij [this message]
2020-11-18 9:00 ` Arnd Bergmann
2021-11-15 10:56 ` Peter Maydell
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='CACRpkdZoMoUQX+CPd31qwjXSKJvaZ6=jcFvUrK_3hkxaUWJNJg@mail.gmail.com' \
--to=linus.walleij@linaro.org \
--cc=Dave.Martin@arm.com \
--cc=adilger.kernel@dilger.ca \
--cc=fw@deneb.enyo.de \
--cc=linux-api@vger.kernel.org \
--cc=linux-ext4@vger.kernel.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=luto@kernel.org \
--cc=peter.maydell@linaro.org \
--cc=qemu-devel@nongnu.org \
--cc=tytso@mit.edu \
/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;
as well as URLs for NNTP newsgroup(s).