From 8c7b1aa7bb6fc4425248849cc02b532e04c7c610 Mon Sep 17 00:00:00 2001 From: Steve Muir Date: Tue, 29 Nov 2005 22:42:40 +0000 Subject: [PATCH] Reincorporate forgotten patch for modifying vserver file flags using ioctl --- fs/ioctl.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/fs/ioctl.c b/fs/ioctl.c index 1b18d7414..1f95769c3 100644 --- a/fs/ioctl.c +++ b/fs/ioctl.c @@ -197,6 +197,22 @@ int vfs_ioctl(struct file *filp, unsigned int fd, unsigned int cmd, unsigned lon error = vx_proc_ioctl(filp->f_dentry->d_inode, filp, cmd, arg); break; #endif + /* + * These cmds needed for PLK - don't lose them! + */ + case FIOC_SETIATTR: + case FIOC_GETIATTR: + /* + * Verify that this filp is a file object, + * not (say) a socket. + */ + error = -ENOTTY; + if (S_ISREG(filp->f_dentry->d_inode->i_mode) || + S_ISDIR(filp->f_dentry->d_inode->i_mode)) + error = vc_iattr_ioctl(filp->f_dentry, + cmd, arg); + break; + default: if (S_ISREG(filp->f_dentry->d_inode->i_mode)) error = file_ioctl(filp, cmd, arg); -- 2.47.0