[Devel,RHEL7,COMMIT] ve/fs/ext4: allow container's root to change immutable attribute.

Submitted by Konstantin Khorenko on June 20, 2017, 5:08 p.m.

Details

Message ID 201706201708.v5KH8h53003877@finist_cl7.x64_64.work.ct
State New
Series "fs/ext4: allow container's root to change immutable attribute."
Headers show

Commit Message

Konstantin Khorenko June 20, 2017, 5:08 p.m.
The commit is pushed to "branch-rh7-3.10.0-514.16.1.vz7.32.x-ovz" and will appear at https://src.openvz.org/scm/ovz/vzkernel.git
after rh7-3.10.0-514.16.1.vz7.32.10
------>
commit 380581e0a5f8042ebc4513812590c03e4d3bc244
Author: Andrey Ryabinin <aryabinin@virtuozzo.com>
Date:   Tue Jun 20 21:08:43 2017 +0400

    ve/fs/ext4: allow container's root to change immutable attribute.
    
    This allows container's root to change immutable and append only
    attributes on files.
    
    https://jira.sw.ru/browse/PSBM-60148
    Signed-off-by: Andrey Ryabinin <aryabinin@virtuozzo.com>
---
 fs/ext4/ioctl.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Patch hide | download patch | download mbox

diff --git a/fs/ext4/ioctl.c b/fs/ext4/ioctl.c
index 117d89d..f6908a7 100644
--- a/fs/ext4/ioctl.c
+++ b/fs/ext4/ioctl.c
@@ -303,7 +303,7 @@  long ext4_ioctl(struct file *filp, unsigned int cmd, unsigned long arg)
 		 * This test looks nicer. Thanks to Pauline Middelink
 		 */
 		if ((flags ^ oldflags) & (EXT4_APPEND_FL | EXT4_IMMUTABLE_FL)) {
-			if (!capable(CAP_LINUX_IMMUTABLE))
+			if (!ve_capable(CAP_LINUX_IMMUTABLE))
 				goto flags_out;
 		}