Linux filesystem development
 help / color / mirror / Atom feed
From: Al Viro <viro@zeniv.linux.org.uk>
To: Dawid Osuchowski <linux@osuchow.ski>
Cc: linux-fsdevel@vger.kernel.org, brauner@kernel.org, jack@suse.cz
Subject: Re: [PATCH v2] fs: Create anon_inode_getfile_fmode()
Date: Thu, 25 Apr 2024 23:31:38 +0100	[thread overview]
Message-ID: <20240425223138.GO2118490@ZenIV> (raw)
In-Reply-To: <022a152f-11c8-404c-8d7f-f7f788f17471@osuchow.ski>

On Fri, Apr 26, 2024 at 12:15:52AM +0200, Dawid Osuchowski wrote:
> On 4/26/24 00:03, Al Viro wrote:
> > On Thu, Apr 25, 2024 at 11:58:03PM +0200, Dawid Osuchowski wrote:
> > > +struct file *anon_inode_getfile_fmode(const char *name,
> > > +				const struct file_operations *fops,
> > > +				void *priv, int flags, fmode_t f_mode)
> > 						       ^^^^^^^
> > > +struct file *anon_inode_getfile_fmode(const char *name,
> > > +				const struct file_operations *fops,
> > > +				void *priv, int flags, unsigned int f_mode);
> > 						       ^^^^^^^^^^^^
> > 
> > They ought to match (and fmode_t is the right type here).
> 
> Should I include the <linux/fs.h> header (or a different one) into
> anon_inodes.h to get the fmode_t type or can I copy the typedef directly as
> a sort of "forward declare" instead?
> 
> The latter would mean something like this:
> 
> 	struct inode;
> +	typedef unsigned int fmode_t;

linux/types.h, if anything.

  reply	other threads:[~2024-04-25 22:31 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-04-25 21:58 [PATCH v2] fs: Create anon_inode_getfile_fmode() Dawid Osuchowski
2024-04-25 22:03 ` Al Viro
2024-04-25 22:15   ` Dawid Osuchowski
2024-04-25 22:31     ` Al Viro [this message]
2024-04-26  7:55       ` Dawid Osuchowski

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=20240425223138.GO2118490@ZenIV \
    --to=viro@zeniv.linux.org.uk \
    --cc=brauner@kernel.org \
    --cc=jack@suse.cz \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux@osuchow.ski \
    /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