summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@suse.de>2011-11-03 13:16:09 -0700
committerGreg Kroah-Hartman <gregkh@suse.de>2011-11-03 13:16:09 -0700
commitc44640794458fe4bbf988a205b4e5e30834b0249 (patch)
tree00bcf5724e55665c003da7cbb9f48181901afb3f
parentf9331113bfb38a67ae687cfadd60c9aeab5a30fc (diff)
downloadlongterm-queue-2.6.33-c44640794458fe4bbf988a205b4e5e30834b0249.tar.gz
.33 patches
-rw-r--r--queue-2.6.33/drivers-net-rionet.c-fix-ethernet-address-macros-for-le-platforms.patch37
-rw-r--r--queue-2.6.33/ext2-ext3-ext4-don-t-inherit-append_fl-or-immutable_fl-for-new-inodes.patch62
-rw-r--r--queue-2.6.33/ext4-fix-bug_on-in-ext4_ext_insert_extent.patch65
-rw-r--r--queue-2.6.33/series3
4 files changed, 167 insertions, 0 deletions
diff --git a/queue-2.6.33/drivers-net-rionet.c-fix-ethernet-address-macros-for-le-platforms.patch b/queue-2.6.33/drivers-net-rionet.c-fix-ethernet-address-macros-for-le-platforms.patch
new file mode 100644
index 0000000..20a8b9f
--- /dev/null
+++ b/queue-2.6.33/drivers-net-rionet.c-fix-ethernet-address-macros-for-le-platforms.patch
@@ -0,0 +1,37 @@
+From e0c87bd95e8dad455c23bc56513af8dcb1737e55 Mon Sep 17 00:00:00 2001
+From: Alexandre Bounine <alexandre.bounine@idt.com>
+Date: Wed, 2 Nov 2011 13:39:15 -0700
+Subject: drivers/net/rionet.c: fix ethernet address macros for LE platforms
+
+From: Alexandre Bounine <alexandre.bounine@idt.com>
+
+commit e0c87bd95e8dad455c23bc56513af8dcb1737e55 upstream.
+
+Modify Ethernet addess macros to be compatible with BE/LE platforms
+
+Signed-off-by: Alexandre Bounine <alexandre.bounine@idt.com>
+Cc: Chul Kim <chul.kim@idt.com>
+Cc: Kumar Gala <galak@kernel.crashing.org>
+Cc: Matt Porter <mporter@kernel.crashing.org>
+Cc: Li Yang <leoli@freescale.com>
+Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
+Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/net/rionet.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+--- a/drivers/net/rionet.c
++++ b/drivers/net/rionet.c
+@@ -87,8 +87,8 @@ static struct rio_dev **rionet_active;
+ #define dev_rionet_capable(dev) \
+ is_rionet_capable(dev->pef, dev->src_ops, dev->dst_ops)
+
+-#define RIONET_MAC_MATCH(x) (*(u32 *)x == 0x00010001)
+-#define RIONET_GET_DESTID(x) (*(u16 *)(x + 4))
++#define RIONET_MAC_MATCH(x) (!memcmp((x), "\00\01\00\01", 4))
++#define RIONET_GET_DESTID(x) ((*((u8 *)x + 4) << 8) | *((u8 *)x + 5))
+
+ static int rionet_rx_clean(struct net_device *ndev)
+ {
diff --git a/queue-2.6.33/ext2-ext3-ext4-don-t-inherit-append_fl-or-immutable_fl-for-new-inodes.patch b/queue-2.6.33/ext2-ext3-ext4-don-t-inherit-append_fl-or-immutable_fl-for-new-inodes.patch
new file mode 100644
index 0000000..b12ac2c
--- /dev/null
+++ b/queue-2.6.33/ext2-ext3-ext4-don-t-inherit-append_fl-or-immutable_fl-for-new-inodes.patch
@@ -0,0 +1,62 @@
+From 1cd9f0976aa4606db8d6e3dc3edd0aca8019372a Mon Sep 17 00:00:00 2001
+From: Theodore Ts'o <tytso@mit.edu>
+Date: Wed, 31 Aug 2011 11:54:51 -0400
+Subject: ext2,ext3,ext4: don't inherit APPEND_FL or IMMUTABLE_FL for new inodes
+
+From: Theodore Ts'o <tytso@mit.edu>
+
+commit 1cd9f0976aa4606db8d6e3dc3edd0aca8019372a upstream.
+
+This doesn't make much sense, and it exposes a bug in the kernel where
+attempts to create a new file in an append-only directory using
+O_CREAT will fail (but still leave a zero-length file). This was
+discovered when xfstests #79 was generalized so it could run on all
+file systems.
+
+Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ fs/ext4/ext4.h | 3 +--
+ include/linux/ext2_fs.h | 4 ++--
+ include/linux/ext3_fs.h | 4 ++--
+ 3 files changed, 5 insertions(+), 6 deletions(-)
+
+--- a/fs/ext4/ext4.h
++++ b/fs/ext4/ext4.h
+@@ -291,8 +291,7 @@ struct flex_groups {
+
+ /* Flags that should be inherited by new inodes from their parent. */
+ #define EXT4_FL_INHERITED (EXT4_SECRM_FL | EXT4_UNRM_FL | EXT4_COMPR_FL |\
+- EXT4_SYNC_FL | EXT4_IMMUTABLE_FL | EXT4_APPEND_FL |\
+- EXT4_NODUMP_FL | EXT4_NOATIME_FL |\
++ EXT4_SYNC_FL | EXT4_NODUMP_FL | EXT4_NOATIME_FL |\
+ EXT4_NOCOMPR_FL | EXT4_JOURNAL_DATA_FL |\
+ EXT4_NOTAIL_FL | EXT4_DIRSYNC_FL)
+
+--- a/include/linux/ext2_fs.h
++++ b/include/linux/ext2_fs.h
+@@ -196,8 +196,8 @@ struct ext2_group_desc
+
+ /* Flags that should be inherited by new inodes from their parent. */
+ #define EXT2_FL_INHERITED (EXT2_SECRM_FL | EXT2_UNRM_FL | EXT2_COMPR_FL |\
+- EXT2_SYNC_FL | EXT2_IMMUTABLE_FL | EXT2_APPEND_FL |\
+- EXT2_NODUMP_FL | EXT2_NOATIME_FL | EXT2_COMPRBLK_FL|\
++ EXT2_SYNC_FL | EXT2_NODUMP_FL |\
++ EXT2_NOATIME_FL | EXT2_COMPRBLK_FL |\
+ EXT2_NOCOMP_FL | EXT2_JOURNAL_DATA_FL |\
+ EXT2_NOTAIL_FL | EXT2_DIRSYNC_FL)
+
+--- a/include/linux/ext3_fs.h
++++ b/include/linux/ext3_fs.h
+@@ -180,8 +180,8 @@ struct ext3_group_desc
+
+ /* Flags that should be inherited by new inodes from their parent. */
+ #define EXT3_FL_INHERITED (EXT3_SECRM_FL | EXT3_UNRM_FL | EXT3_COMPR_FL |\
+- EXT3_SYNC_FL | EXT3_IMMUTABLE_FL | EXT3_APPEND_FL |\
+- EXT3_NODUMP_FL | EXT3_NOATIME_FL | EXT3_COMPRBLK_FL|\
++ EXT3_SYNC_FL | EXT3_NODUMP_FL |\
++ EXT3_NOATIME_FL | EXT3_COMPRBLK_FL |\
+ EXT3_NOCOMPR_FL | EXT3_JOURNAL_DATA_FL |\
+ EXT3_NOTAIL_FL | EXT3_DIRSYNC_FL)
+
diff --git a/queue-2.6.33/ext4-fix-bug_on-in-ext4_ext_insert_extent.patch b/queue-2.6.33/ext4-fix-bug_on-in-ext4_ext_insert_extent.patch
new file mode 100644
index 0000000..8c29f37
--- /dev/null
+++ b/queue-2.6.33/ext4-fix-bug_on-in-ext4_ext_insert_extent.patch
@@ -0,0 +1,65 @@
+From gnehzuil.liu@gmail.com Thu Nov 3 10:42:14 2011
+From: Zheng Liu <gnehzuil.liu@gmail.com>
+Date: Fri, 28 Oct 2011 20:34:02 +0800
+Subject: ext4: fix BUG_ON() in ext4_ext_insert_extent()
+To: Greg KH <greg@kroah.com>
+Cc: Ted Ts'o <tytso@mit.edu>, Tao Ma <tm@tao.ma>, linux-ext4@vger.kernel.org, Xiaoyun Mao <xiaoyun.maoxy@aliyun-inc.com>, Yingbin Wang <yingbin.wangyb@aliyun-inc.com>, Jia Wan <jia.wanj@aliyun-inc.com>
+Message-ID: <20111028123402.GA26003@gmail.com>
+
+
+From: Zheng Liu <wenqing.lz@taobao.com>
+
+Does not corrispond with a direct commit in Linus's tree as it was fixed
+differently in the 3.0 release.
+
+
+We will meet with a BUG_ON() if following script is run.
+
+mkfs.ext4 -b 4096 /dev/sdb1 1000000
+mount -t ext4 /dev/sdb1 /mnt/sdb1
+fallocate -l 100M /mnt/sdb1/test
+sync
+for((i=0;i<170;i++))
+do
+ dd if=/dev/zero of=/mnt/sdb1/test conv=notrunc bs=256k count=1
+seek=`expr $i \* 2`
+done
+umount /mnt/sdb1
+mount -t ext4 /dev/sdb1 /mnt/sdb1
+dd if=/dev/zero of=/mnt/sdb1/test conv=notrunc bs=256k count=1 seek=341
+umount /mnt/sdb1
+mount /dev/sdb1 /mnt/sdb1
+dd if=/dev/zero of=/mnt/sdb1/test conv=notrunc bs=256k count=1 seek=340
+sync
+
+The reason is that it forgot to mark dirty when splitting two extents in
+ext4_ext_convert_to_initialized(). Althrough ex has been updated in
+memory, it is not dirtied both in ext4_ext_convert_to_initialized() and
+ext4_ext_insert_extent(). The disk layout is corrupted. Then it will
+meet with a BUG_ON() when writting at the start of that extent again.
+
+Cc: "Theodore Ts'o" <tytso@mit.edu>
+Cc: Xiaoyun Mao <xiaoyun.maoxy@aliyun-inc.com>
+Cc: Yingbin Wang <yingbin.wangyb@aliyun-inc.com>
+Cc: Jia Wan <jia.wanj@aliyun-inc.com>
+Signed-off-by: Zheng Liu <wenqing.lz@taobao.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+--- a/fs/ext4/extents.c
++++ b/fs/ext4/extents.c
+@@ -2592,6 +2592,7 @@ static int ext4_ext_convert_to_initialized(handle_t *handle,
+ ex1 = ex;
+ ex1->ee_len = cpu_to_le16(iblock - ee_block);
+ ext4_ext_mark_uninitialized(ex1);
++ ext4_ext_dirty(handle, inode, path + depth);
+ ex2 = &newex;
+ }
+ /*
+--
+1.7.4.1
+
+> --
+> To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
+> the body of a message to majordomo@vger.kernel.org
+> More majordomo info at http://vger.kernel.org/majordomo-info.html
+
diff --git a/queue-2.6.33/series b/queue-2.6.33/series
index 6d05868..ae05983 100644
--- a/queue-2.6.33/series
+++ b/queue-2.6.33/series
@@ -98,3 +98,6 @@ vm-fix-vm_pgoff-wrap-in-upward-expansion.patch
bluetooth-prevent-buffer-overflow-in-l2cap-config-request.patch
nl80211-fix-overflow-in-ssid_len.patch
net_sched-fix-qdisc_notify.patch
+ext4-fix-bug_on-in-ext4_ext_insert_extent.patch
+drivers-net-rionet.c-fix-ethernet-address-macros-for-le-platforms.patch
+ext2-ext3-ext4-don-t-inherit-append_fl-or-immutable_fl-for-new-inodes.patch