Skip to content

Commit

Permalink
alma 94 special build issue
Browse files Browse the repository at this point in the history
  • Loading branch information
abbbi committed May 10, 2024
1 parent 31c635b commit 6366160
Showing 1 changed file with 2 additions and 20 deletions.
22 changes: 2 additions & 20 deletions nullfs.c
Original file line number Diff line number Diff line change
Expand Up @@ -533,35 +533,17 @@ static int nullfs_create(struct inode *dir, struct dentry *dentry, umode_t mode,
#endif
}

#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 11, 0)
#if LINUX_VERSION_CODE >= KERNEL_VERSION(6, 3, 0)
static int nullfs_tmpfile(struct mnt_idmap *idmap, struct inode *dir,
struct file *file, umode_t mode)
#elif LINUX_VERSION_CODE >= KERNEL_VERSION(6, 1, 0)

static int nullfs_tmpfile(struct user_namespace *mnt_userns, struct inode *dir,
struct file *file, umode_t mode)
#elif LINUX_VERSION_CODE >= KERNEL_VERSION(5, 12, 0)
static int nullfs_tmpfile(struct user_namespace *mnt_userns, struct inode *dir, struct dentry *dentry, umode_t mode)
#else
static int nullfs_tmpfile(struct inode *dir, struct dentry *dentry, umode_t mode)
#endif
struct file *file, umode_t mode)
{
struct inode *inode;
#if LINUX_VERSION_CODE >= KERNEL_VERSION(6, 1, 0)
inode = nullfs_get_inode(dir->i_sb, dir, mode, 0, file->f_path.dentry);
#else
inode = nullfs_get_inode(dir->i_sb, dir, mode, 0, dentry);
#endif
if (!inode)
return -ENOSPC;
#if LINUX_VERSION_CODE >= KERNEL_VERSION(6, 1, 0)
d_tmpfile(file, inode);
#else
d_tmpfile(dentry, inode);
#endif
return 0;
}
#endif

static const struct inode_operations nullfs_dir_inode_operations = {
.create = nullfs_create,
Expand Down

0 comments on commit 6366160

Please sign in to comment.