--- /dev/null
+From 453d3131ec7aab82eaaa8401a50522a337092aa8 Mon Sep 17 00:00:00 2001
+From: Robert Hancock <hancockrwd@gmail.com>
+Date: Tue, 26 Jan 2010 22:33:23 -0600
+Subject: ahci: disable FPDMA auto-activate optimization on NVIDIA AHCI
+
+From: Robert Hancock <hancockrwd@gmail.com>
+
+commit 453d3131ec7aab82eaaa8401a50522a337092aa8 upstream.
+
+Mike Cui reported that his system with an NVIDIA MCP79 (aka MCP7A)
+chipset stopped working with 2.6.32. The problem appears to be that
+2.6.32 now enables the FPDMA auto-activate optimization in the ahci
+driver. The drive works fine with this enabled on an Intel AHCI so
+this appears to be a chipset bug. Since MCP79 is a fairly recent
+NVIDIA chipset and we don't have any info on whether any other NVIDIA
+chipsets have this issue, disable FPDMA AA optimization on all NVIDIA
+AHCI controllers for now.
+
+Should address http://bugzilla.kernel.org/show_bug.cgi?id=14922
+
+Signed-off-by: Robert Hancock <hancockrwd@gmail.com>
+While-we-investigate-issue-this-patch-looks-good-to-me-by:
+ Prajakta Gudadhe <pgudadhe@nvidia.com>
+Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/ata/ahci.c | 12 ++++++++++--
+ 1 file changed, 10 insertions(+), 2 deletions(-)
+
+--- a/drivers/ata/ahci.c
++++ b/drivers/ata/ahci.c
+@@ -3082,8 +3082,16 @@ static int ahci_init_one(struct pci_dev
+ ahci_save_initial_config(pdev, hpriv);
+
+ /* prepare host */
+- if (hpriv->cap & HOST_CAP_NCQ)
+- pi.flags |= ATA_FLAG_NCQ | ATA_FLAG_FPDMA_AA;
++ if (hpriv->cap & HOST_CAP_NCQ) {
++ pi.flags |= ATA_FLAG_NCQ;
++ /* Auto-activate optimization is supposed to be supported on
++ all AHCI controllers indicating NCQ support, but it seems
++ to be broken at least on some NVIDIA MCP79 chipsets.
++ Until we get info on which NVIDIA chipsets don't have this
++ issue, if any, disable AA on all NVIDIA AHCIs. */
++ if (pdev->vendor != PCI_VENDOR_ID_NVIDIA)
++ pi.flags |= ATA_FLAG_FPDMA_AA;
++ }
+
+ if (hpriv->cap & HOST_CAP_PMP)
+ pi.flags |= ATA_FLAG_PMP;
--- /dev/null
+From c36f74e67fa12202dbcb4ad92c5ac844f9d36b98 Mon Sep 17 00:00:00 2001
+From: Joshua Roys <joshua.roys@gtri.gatech.edu>
+Date: Wed, 24 Feb 2010 18:52:44 -0500
+Subject: netlabel: fix export of SELinux categories > 127
+
+From: Joshua Roys <joshua.roys@gtri.gatech.edu>
+
+commit c36f74e67fa12202dbcb4ad92c5ac844f9d36b98 upstream.
+
+This fixes corrupted CIPSO packets when SELinux categories greater than 127
+are used. The bug occured on the second (and later) loops through the
+while; the inner for loop through the ebitmap->maps array used the same
+index as the NetLabel catmap->bitmap array, even though the NetLabel bitmap
+is twice as long as the SELinux bitmap.
+
+Signed-off-by: Joshua Roys <joshua.roys@gtri.gatech.edu>
+Acked-by: Paul Moore <paul.moore@hp.com>
+Signed-off-by: James Morris <jmorris@namei.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ security/selinux/ss/ebitmap.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/security/selinux/ss/ebitmap.c
++++ b/security/selinux/ss/ebitmap.c
+@@ -128,7 +128,7 @@ int ebitmap_netlbl_export(struct ebitmap
+ cmap_idx = delta / NETLBL_CATMAP_MAPSIZE;
+ cmap_sft = delta % NETLBL_CATMAP_MAPSIZE;
+ c_iter->bitmap[cmap_idx]
+- |= e_iter->maps[cmap_idx] << cmap_sft;
++ |= e_iter->maps[i] << cmap_sft;
+ }
+ e_iter = e_iter->next;
+ }
--- /dev/null
+From ba02b242bbf8e4e1bc63d62e8ccec33b4e5ea132 Mon Sep 17 00:00:00 2001
+From: Andrew Morton <akpm@linux-foundation.org>
+Date: Tue, 2 Feb 2010 14:45:54 -0800
+Subject: PCI hotplug: check ioremap() return value in ibmphp_ebda.c
+
+From: Andrew Morton <akpm@linux-foundation.org>
+
+commit ba02b242bbf8e4e1bc63d62e8ccec33b4e5ea132 upstream.
+
+check ioremap() return value.
+
+Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
+Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/pci/hotplug/ibmphp_ebda.c | 2 ++
+ 1 file changed, 2 insertions(+)
+
+--- a/drivers/pci/hotplug/ibmphp_ebda.c
++++ b/drivers/pci/hotplug/ibmphp_ebda.c
+@@ -261,6 +261,8 @@ int __init ibmphp_access_ebda (void)
+ debug ("returned ebda segment: %x\n", ebda_seg);
+
+ io_mem = ioremap(ebda_seg<<4, 1);
++ if (!io_mem)
++ return -ENOMEM;
+ ebda_sz = readb(io_mem);
+ iounmap(io_mem);
+ debug("ebda size: %d(KiB)\n", ebda_sz);
--- /dev/null
+From b0fc889c4311835ae7d02f433154bc20cad9ee11 Mon Sep 17 00:00:00 2001
+From: Chandru <chandru@in.ibm.com>
+Date: Mon, 11 Jan 2010 11:49:21 +0530
+Subject: PCI hotplug: ibmphp: read the length of ebda and map entire ebda region
+
+From: Chandru <chandru@in.ibm.com>
+
+commit b0fc889c4311835ae7d02f433154bc20cad9ee11 upstream.
+
+ibmphp driver currently maps only 1KB of ebda memory area into kernel address
+space during driver initialization. This causes kernel oops when the driver is
+modprobe'd and it accesses memory beyond 1KB within ebda segment. The first
+byte of ebda segment actually stores the length of the ebda region in
+Kilobytes. Hence make use of the length parameter and map the entire ebda
+region.
+
+Signed-off-by: Chandru Siddalingappa <chandru@linux.vnet.ibm.com>
+Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/pci/hotplug/ibmphp_ebda.c | 11 +++++++++--
+ 1 file changed, 9 insertions(+), 2 deletions(-)
+
+--- a/drivers/pci/hotplug/ibmphp_ebda.c
++++ b/drivers/pci/hotplug/ibmphp_ebda.c
+@@ -245,7 +245,7 @@ static void __init print_ebda_hpc (void)
+
+ int __init ibmphp_access_ebda (void)
+ {
+- u8 format, num_ctlrs, rio_complete, hs_complete;
++ u8 format, num_ctlrs, rio_complete, hs_complete, ebda_sz;
+ u16 ebda_seg, num_entries, next_offset, offset, blk_id, sub_addr, re, rc_id, re_id, base;
+ int rc = 0;
+
+@@ -260,7 +260,14 @@ int __init ibmphp_access_ebda (void)
+ iounmap (io_mem);
+ debug ("returned ebda segment: %x\n", ebda_seg);
+
+- io_mem = ioremap(ebda_seg<<4, 1024);
++ io_mem = ioremap(ebda_seg<<4, 1);
++ ebda_sz = readb(io_mem);
++ iounmap(io_mem);
++ debug("ebda size: %d(KiB)\n", ebda_sz);
++ if (ebda_sz == 0)
++ return -ENOMEM;
++
++ io_mem = ioremap(ebda_seg<<4, (ebda_sz * 1024));
+ if (!io_mem )
+ return -ENOMEM;
+ next_offset = 0x180;
--- /dev/null
+From baac35c4155a8aa826c70acee6553368ca5243a2 Mon Sep 17 00:00:00 2001
+From: Xiaotian Feng <dfeng@redhat.com>
+Date: Wed, 24 Feb 2010 18:39:02 +0800
+Subject: security: fix error return path in ima_inode_alloc
+
+From: Xiaotian Feng <dfeng@redhat.com>
+
+commit baac35c4155a8aa826c70acee6553368ca5243a2 upstream.
+
+If radix_tree_preload is failed in ima_inode_alloc, we don't need
+radix_tree_preload_end because kernel is alread preempt enabled
+
+Signed-off-by: Xiaotian Feng <dfeng@redhat.com>
+Signed-off-by: Mimi Zohar <zohar@us.ibm.com>
+Signed-off-by: James Morris <jmorris@namei.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ security/integrity/ima/ima_iint.c | 3 +--
+ 1 file changed, 1 insertion(+), 2 deletions(-)
+
+--- a/security/integrity/ima/ima_iint.c
++++ b/security/integrity/ima/ima_iint.c
+@@ -63,12 +63,11 @@ int ima_inode_alloc(struct inode *inode)
+ spin_lock(&ima_iint_lock);
+ rc = radix_tree_insert(&ima_iint_store, (unsigned long)inode, iint);
+ spin_unlock(&ima_iint_lock);
++ radix_tree_preload_end();
+ out:
+ if (rc < 0)
+ kmem_cache_free(iint_cache, iint);
+
+- radix_tree_preload_end();
+-
+ return rc;
+ }
+
--- /dev/null
+ahci-disable-fpdma-auto-activate-optimization-on-nvidia-ahci.patch
+netlabel-fix-export-of-selinux-categories-127.patch
+pci-hotplug-ibmphp-read-the-length-of-ebda-and-map-entire-ebda-region.patch
+pci-hotplug-check-ioremap-return-value-in-ibmphp_ebda.c.patch
+security-fix-error-return-path-in-ima_inode_alloc.patch