diff options
Diffstat (limited to 'target/linux/generic/patches-4.0/550-ubifs-symlink-xattr-support.patch')
-rw-r--r-- | target/linux/generic/patches-4.0/550-ubifs-symlink-xattr-support.patch | 28 |
1 files changed, 1 insertions, 27 deletions
diff --git a/target/linux/generic/patches-4.0/550-ubifs-symlink-xattr-support.patch b/target/linux/generic/patches-4.0/550-ubifs-symlink-xattr-support.patch index d3f2ccca36..0790003147 100644 --- a/target/linux/generic/patches-4.0/550-ubifs-symlink-xattr-support.patch +++ b/target/linux/generic/patches-4.0/550-ubifs-symlink-xattr-support.patch @@ -1,6 +1,6 @@ --- a/fs/ubifs/file.c +++ b/fs/ubifs/file.c -@@ -1573,6 +1573,10 @@ const struct inode_operations ubifs_syml +@@ -1574,6 +1574,10 @@ const struct inode_operations ubifs_syml .follow_link = ubifs_follow_link, .setattr = ubifs_setattr, .getattr = ubifs_getattr, @@ -11,32 +11,6 @@ }; const struct file_operations ubifs_file_operations = { ---- a/fs/ubifs/journal.c -+++ b/fs/ubifs/journal.c -@@ -572,6 +572,13 @@ int ubifs_jnl_update(struct ubifs_info * - aligned_dlen = ALIGN(dlen, 8); - aligned_ilen = ALIGN(ilen, 8); - len = aligned_dlen + aligned_ilen + UBIFS_INO_NODE_SZ; -+ if (xent) { -+ /* -+ * Make sure to account for host_ui->data_len in -+ * length calculation in case there is extended attribute. -+ */ -+ len += host_ui->data_len; -+ } - dent = kmalloc(len, GFP_NOFS); - if (!dent) - return -ENOMEM; -@@ -648,7 +655,8 @@ int ubifs_jnl_update(struct ubifs_info * - - ino_key_init(c, &ino_key, dir->i_ino); - ino_offs += aligned_ilen; -- err = ubifs_tnc_add(c, &ino_key, lnum, ino_offs, UBIFS_INO_NODE_SZ); -+ err = ubifs_tnc_add(c, &ino_key, lnum, ino_offs, -+ UBIFS_INO_NODE_SZ + host_ui->data_len); - if (err) - goto out_ro; - --- a/fs/ubifs/xattr.c +++ b/fs/ubifs/xattr.c @@ -209,12 +209,12 @@ static int change_xattr(struct ubifs_inf |