Re: [PATCH v2] fs: Create anon_inode_getfile_fmode()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



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;

-- Dawid




[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [NTFS 3]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [NTFS 3]     [Samba]     [Device Mapper]     [CEPH Development]

  Powered by Linux