summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@suse.de>2011-03-25 12:13:53 -0700
committerGreg Kroah-Hartman <gregkh@suse.de>2011-03-25 12:13:53 -0700
commit2d80e20f3ea939829e87e0fd3743063a9a73042d (patch)
treedcd5685bfa8022628cb5ec2f091ab7976ce57d1d
parent04eacd739735007ee44f12009e33ef3331c1fcbf (diff)
downloadlongterm-queue-2.6.33-2d80e20f3ea939829e87e0fd3743063a9a73042d.tar.gz
.33 patches
-rw-r--r--queue-2.6.33/dcdbas-force-smi-to-happen-when-expected.patch39
-rw-r--r--queue-2.6.33/fs-call-security_d_instantiate-in-d_obtain_alias-v2.patch55
-rw-r--r--queue-2.6.33/series3
-rw-r--r--queue-2.6.33/sunrpc-never-reuse-the-socket-port-after-an-xs_close.patch31
4 files changed, 128 insertions, 0 deletions
diff --git a/queue-2.6.33/dcdbas-force-smi-to-happen-when-expected.patch b/queue-2.6.33/dcdbas-force-smi-to-happen-when-expected.patch
new file mode 100644
index 0000000..35daf71
--- /dev/null
+++ b/queue-2.6.33/dcdbas-force-smi-to-happen-when-expected.patch
@@ -0,0 +1,39 @@
+From dd65c736d1b5312c80c88a64bf521db4959eded5 Mon Sep 17 00:00:00 2001
+From: Stuart Hayes <stuart_hayes@yahoo.com>
+Date: Wed, 2 Mar 2011 13:42:05 +0100
+Subject: dcdbas: force SMI to happen when expected
+
+From: Stuart Hayes <stuart_hayes@yahoo.com>
+
+commit dd65c736d1b5312c80c88a64bf521db4959eded5 upstream.
+
+The dcdbas driver can do an I/O write to cause a SMI to occur. The SMI handler
+looks at certain registers and memory locations, so the SMI needs to happen
+immediately. On some systems I/O writes are posted, though, causing the SMI to
+happen well after the "outb" occurred, which causes random failures. Following
+the "outb" with an "inb" forces the write to go through even if it is posted.
+
+Signed-off-by: Stuart Hayes <stuart_hayes@yahoo.com>
+Acked-by: Doug Warzecha <douglas_warzecha@dell.com>
+Cc: Chuck Ebbert <cebbert@redhat.com>
+Signed-off-by: Jiri Kosina <jkosina@suse.cz>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/firmware/dcdbas.c | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+--- a/drivers/firmware/dcdbas.c
++++ b/drivers/firmware/dcdbas.c
+@@ -267,8 +267,10 @@ int dcdbas_smi_request(struct smi_cmd *s
+ }
+
+ /* generate SMI */
++ /* inb to force posted write through and make SMI happen now */
+ asm volatile (
+- "outb %b0,%w1"
++ "outb %b0,%w1\n"
++ "inb %w1"
+ : /* no output args */
+ : "a" (smi_cmd->command_code),
+ "d" (smi_cmd->command_address),
diff --git a/queue-2.6.33/fs-call-security_d_instantiate-in-d_obtain_alias-v2.patch b/queue-2.6.33/fs-call-security_d_instantiate-in-d_obtain_alias-v2.patch
new file mode 100644
index 0000000..8395606
--- /dev/null
+++ b/queue-2.6.33/fs-call-security_d_instantiate-in-d_obtain_alias-v2.patch
@@ -0,0 +1,55 @@
+From 24ff6663ccfdaf088dfa7acae489cb11ed4f43c4 Mon Sep 17 00:00:00 2001
+From: Josef Bacik <josef@redhat.com>
+Date: Thu, 18 Nov 2010 20:52:55 -0500
+Subject: fs: call security_d_instantiate in d_obtain_alias V2
+
+From: Josef Bacik <josef@redhat.com>
+
+commit 24ff6663ccfdaf088dfa7acae489cb11ed4f43c4 upstream.
+
+While trying to track down some NFS problems with BTRFS, I kept noticing I was
+getting -EACCESS for no apparent reason. Eric Paris and printk() helped me
+figure out that it was SELinux that was giving me grief, with the following
+denial
+
+type=AVC msg=audit(1290013638.413:95): avc: denied { 0x800000 } for pid=1772
+comm="nfsd" name="" dev=sda1 ino=256 scontext=system_u:system_r:kernel_t:s0
+tcontext=system_u:object_r:unlabeled_t:s0 tclass=file
+
+Turns out this is because in d_obtain_alias if we can't find an alias we create
+one and do all the normal instantiation stuff, but we don't do the
+security_d_instantiate.
+
+Usually we are protected from getting a hashed dentry that hasn't yet run
+security_d_instantiate() by the parent's i_mutex, but obviously this isn't an
+option there, so in order to deal with the case that a second thread comes in
+and finds our new dentry before we get to run security_d_instantiate(), we go
+ahead and call it if we find a dentry already. Eric assures me that this is ok
+as the code checks to see if the dentry has been initialized already so calling
+security_d_instantiate() against the same dentry multiple times is ok. With
+this patch I'm no longer getting errant -EACCESS values.
+
+Signed-off-by: Josef Bacik <josef@redhat.com>
+Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
+Cc: Chuck Ebbert <cebbert@redhat.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ fs/dcache.c | 3 +++
+ 1 file changed, 3 insertions(+)
+
+--- a/fs/dcache.c
++++ b/fs/dcache.c
+@@ -1176,9 +1176,12 @@ struct dentry *d_obtain_alias(struct ino
+ spin_unlock(&tmp->d_lock);
+
+ spin_unlock(&dcache_lock);
++ security_d_instantiate(tmp, inode);
+ return tmp;
+
+ out_iput:
++ if (res && !IS_ERR(res))
++ security_d_instantiate(res, inode);
+ iput(inode);
+ return res;
+ }
diff --git a/queue-2.6.33/series b/queue-2.6.33/series
index d0f2bd3..16ddb4c 100644
--- a/queue-2.6.33/series
+++ b/queue-2.6.33/series
@@ -30,3 +30,6 @@ usb-cdc-acm-fix-potential-null-pointer-dereference.patch
usb-cdc-acm-fix-potential-null-pointer-dereference-on-disconnect.patch
input-xen-kbdfront-advertise-either-absolute-or-relative-coordinates.patch
x86-cleanup-highmap-after-brk-is-concluded.patch
+sunrpc-never-reuse-the-socket-port-after-an-xs_close.patch
+fs-call-security_d_instantiate-in-d_obtain_alias-v2.patch
+dcdbas-force-smi-to-happen-when-expected.patch
diff --git a/queue-2.6.33/sunrpc-never-reuse-the-socket-port-after-an-xs_close.patch b/queue-2.6.33/sunrpc-never-reuse-the-socket-port-after-an-xs_close.patch
new file mode 100644
index 0000000..3296cc2
--- /dev/null
+++ b/queue-2.6.33/sunrpc-never-reuse-the-socket-port-after-an-xs_close.patch
@@ -0,0 +1,31 @@
+From 246408dcd5dfeef2df437ccb0ef4d6ee87805f58 Mon Sep 17 00:00:00 2001
+From: Trond Myklebust <Trond.Myklebust@netapp.com>
+Date: Tue, 22 Mar 2011 18:40:10 -0400
+Subject: SUNRPC: Never reuse the socket port after an xs_close()
+
+From: Trond Myklebust <Trond.Myklebust@netapp.com>
+
+commit 246408dcd5dfeef2df437ccb0ef4d6ee87805f58 upstream.
+
+If we call xs_close(), we're in one of two situations:
+ - Autoclose, which means we don't expect to resend a request
+ - bind+connect failed, which probably means the port is in use
+
+Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ net/sunrpc/xprtsock.c | 2 ++
+ 1 file changed, 2 insertions(+)
+
+--- a/net/sunrpc/xprtsock.c
++++ b/net/sunrpc/xprtsock.c
+@@ -729,6 +729,8 @@ static void xs_reset_transport(struct so
+ if (sk == NULL)
+ return;
+
++ transport->srcport = 0;
++
+ write_lock_bh(&sk->sk_callback_lock);
+ transport->inet = NULL;
+ transport->sock = NULL;