Thu, 10 Apr 2014 19:38:00 +0200
* download http://vserver.13thfloor.at/Experimental/patch-3.4.83-vs2.3.3.9.diff
* patch < 01-patch-{patch-3.4.83-vs2.3.3.9.diff}-to-3.4.86.diff
* apply this patched patch to the kernel source
The change inside the kernel code making this one necessary
affects the filesystem attribute settings in fs/ext4/inode.c .
I hope I got the right idea what went on there...
The usual warnings regarding wearing hard hats etc. apply.
also available on
deb http://ftp.lihas.de/lihas-kernel/ stable main
Outlook:
next week I hope I'll get the numerous change requests on
(missing) configuration options straight.
As some 8000 kernel config options are quite a handful I had
to implement some interface to the build process and
some tools to track and apply changes.
--
LiHAS - Adrian Reyer - Hessenwiesenstraße 10 - D-70565 Stuttgart
Fon: +49 (7 11) 78 28 50 90 - Fax: +49 (7 11) 78 28 50 91
Mail: lihas@lihas.de - Web: http://lihas.de
Linux, Netzwerke, Consulting & Support - USt-ID: DE 227 816 626 Stuttgart
--- patch-3.4.83-vs2.3.3.9.diff 2014-03-12 11:24:15.000000000 +0100
+++ patch-3.4.86-vs2.3.3.9.diff 2014-04-09 17:02:52.952743229 +0200
@@ -3102,47 +3102,37 @@ diff -NurpP --minimal linux-3.4.83/fs/ex
} else
inode_init_owner(inode, dir, mode);
-diff -NurpP --minimal linux-3.4.83/fs/ext4/inode.c linux-3.4.83-vs2.3.3.9/fs/ext4/inode.c
---- linux-3.4.83/fs/ext4/inode.c 2014-03-12 09:48:13.000000000 +0000
-+++ linux-3.4.83-vs2.3.3.9/fs/ext4/inode.c 2014-03-12 09:55:28.000000000 +0000
-@@ -37,6 +37,7 @@
- #include <linux/printk.h>
+diff -NurpP --minimal linux-3.4.83/fs/ext4/inode.c linux-3.4.86-vs2.3.3.9/fs/ext4/inode.c
+--- linux-3.4.86/fs/ext4/inode.c 2014-04-03 20:59:21.000000000 +0200
++++ linux-3.4.83-vs2.3.3.9/fs/ext4/inode.c 2014-04-09 16:10:37.579153127 +0200
+@@ -38,6 +38,7 @@
#include <linux/slab.h>
#include <linux/ratelimit.h>
+ #include <linux/bitops.h>
+#include <linux/vs_tag.h>
#include "ext4_jbd2.h"
#include "xattr.h"
-@@ -3581,41 +3582,64 @@ void ext4_set_inode_flags(struct inode *
- {
- unsigned int flags = EXT4_I(inode)->i_flags;
-
-- inode->i_flags &= ~(S_SYNC|S_APPEND|S_IMMUTABLE|S_NOATIME|S_DIRSYNC);
-+ inode->i_flags &= ~(S_IMMUTABLE | S_IXUNLINK |
-+ S_SYNC | S_APPEND | S_NOATIME | S_DIRSYNC);
-+
-+ if (flags & EXT4_IMMUTABLE_FL)
-+ inode->i_flags |= S_IMMUTABLE;
+@@ -3589,36 +3590,56 @@ void ext4_set_inode_flags(struct inode *
+ new_fl |= S_APPEND;
+ if (flags & EXT4_IMMUTABLE_FL)
+ new_fl |= S_IMMUTABLE;
+ if (flags & EXT4_IXUNLINK_FL)
-+ inode->i_flags |= S_IXUNLINK;
-+
- if (flags & EXT4_SYNC_FL)
- inode->i_flags |= S_SYNC;
- if (flags & EXT4_APPEND_FL)
- inode->i_flags |= S_APPEND;
-- if (flags & EXT4_IMMUTABLE_FL)
-- inode->i_flags |= S_IMMUTABLE;
++ new_fl |= S_IXUNLINK;
if (flags & EXT4_NOATIME_FL)
- inode->i_flags |= S_NOATIME;
+ new_fl |= S_NOATIME;
if (flags & EXT4_DIRSYNC_FL)
- inode->i_flags |= S_DIRSYNC;
+ new_fl |= S_DIRSYNC;
+ set_mask_bits(&inode->i_flags,
+- S_SYNC|S_APPEND|S_IMMUTABLE|S_NOATIME|S_DIRSYNC, new_fl);
++ S_SYNC|S_APPEND|S_IMMUTABLE|S_IXUNLINK|S_NOATIME|S_DIRSYNC, new_fl);
+
+ inode->i_vflags &= ~(V_BARRIER | V_COW);
-+
++
+ if (flags & EXT4_BARRIER_FL)
-+ inode->i_vflags |= V_BARRIER;
++ inode->i_vflags |= V_BARRIER;
+ if (flags & EXT4_COW_FL)
-+ inode->i_vflags |= V_COW;
++ inode->i_vflags |= V_COW;
}
/* Propagate flags from i_flags to EXT4_I(inode)->i_flags */
@@ -3185,7 +3175,7 @@ diff -NurpP --minimal linux-3.4.83/fs/ex
} while (cmpxchg(&ei->i_flags, old_fl, new_fl) != old_fl);
}
-@@ -3651,6 +3675,8 @@ struct inode *ext4_iget(struct super_blo
+@@ -3654,6 +3675,8 @@ struct inode *ext4_iget(struct super_blo
journal_t *journal = EXT4_SB(sb)->s_journal;
long ret;
int block;
@@ -3194,7 +3184,7 @@ diff -NurpP --minimal linux-3.4.83/fs/ex
inode = iget_locked(sb, ino);
if (!inode)
-@@ -3666,12 +3692,16 @@ struct inode *ext4_iget(struct super_blo
+@@ -3669,12 +3692,16 @@ struct inode *ext4_iget(struct super_blo
goto bad_inode;
raw_inode = ext4_raw_inode(&iloc);
inode->i_mode = le16_to_cpu(raw_inode->i_mode);
@@ -3215,7 +3205,7 @@ diff -NurpP --minimal linux-3.4.83/fs/ex
set_nlink(inode, le16_to_cpu(raw_inode->i_links_count));
ext4_clear_state_flags(ei); /* Only relevant on 32-bit archs */
-@@ -3890,6 +3920,8 @@ static int ext4_do_update_inode(handle_t
+@@ -3893,6 +3920,8 @@ static int ext4_do_update_inode(handle_t
struct ext4_inode *raw_inode = ext4_raw_inode(iloc);
struct ext4_inode_info *ei = EXT4_I(inode);
struct buffer_head *bh = iloc->bh;
@@ -3224,7 +3214,7 @@ diff -NurpP --minimal linux-3.4.83/fs/ex
int err = 0, rc, block;
int need_datasync = 0;
-@@ -3901,29 +3933,32 @@ static int ext4_do_update_inode(handle_t
+@@ -3904,29 +3933,32 @@ static int ext4_do_update_inode(handle_t
ext4_get_inode_flags(ei);
raw_inode->i_mode = cpu_to_le16(inode->i_mode);
if (!(test_opt(inode->i_sb, NO_UID32))) {
@@ -3263,7 +3253,7 @@ diff -NurpP --minimal linux-3.4.83/fs/ex
raw_inode->i_links_count = cpu_to_le16(inode->i_nlink);
EXT4_INODE_SET_XTIME(i_ctime, inode, raw_inode);
-@@ -4110,7 +4145,8 @@ int ext4_setattr(struct dentry *dentry,
+@@ -4113,7 +4145,8 @@ int ext4_setattr(struct dentry *dentry,
if (is_quota_modification(inode, attr))
dquot_initialize(inode);
if ((ia_valid & ATTR_UID && attr->ia_uid != inode->i_uid) ||
@@ -3273,7 +3263,7 @@ diff -NurpP --minimal linux-3.4.83/fs/ex
handle_t *handle;
/* (user+group)*(old+new) structure, inode write (sb,
-@@ -4132,6 +4168,8 @@ int ext4_setattr(struct dentry *dentry,
+@@ -4135,6 +4168,8 @@ int ext4_setattr(struct dentry *dentry,
inode->i_uid = attr->ia_uid;
if (attr->ia_valid & ATTR_GID)
inode->i_gid = attr->ia_gid;