]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
.35 patches
authorGreg Kroah-Hartman <gregkh@suse.de>
Wed, 20 Oct 2010 20:32:03 +0000 (13:32 -0700)
committerGreg Kroah-Hartman <gregkh@suse.de>
Wed, 20 Oct 2010 20:32:03 +0000 (13:32 -0700)
queue-2.6.35/kvm-fix-irqfd-assign-deassign-race.patch [new file with mode: 0644]
queue-2.6.35/kvm-fix-reboot-on-intel-hosts.patch [new file with mode: 0644]
queue-2.6.35/kvm-i8259-fix-migration.patch [new file with mode: 0644]
queue-2.6.35/kvm-x86-fix-svm-vmcb-reset.patch [new file with mode: 0644]
queue-2.6.35/kvm-x86-move-tsc-reset-out-of-vmcb_init.patch [new file with mode: 0644]
queue-2.6.35/mmc-sdio-fix-sdio-suspend-resume-regression.patch [new file with mode: 0644]
queue-2.6.35/r8169-allocate-with-gfp_kernel-flag-when-able-to-sleep.patch [new file with mode: 0644]
queue-2.6.35/series
queue-2.6.35/skge-add-quirk-to-limit-dma.patch [new file with mode: 0644]
queue-2.6.35/v4l-dvb-dib7770-enable-the-current-mirror.patch [new file with mode: 0644]
queue-2.6.35/xfs-properly-account-for-reclaimed-inodes.patch [new file with mode: 0644]

diff --git a/queue-2.6.35/kvm-fix-irqfd-assign-deassign-race.patch b/queue-2.6.35/kvm-fix-irqfd-assign-deassign-race.patch
new file mode 100644 (file)
index 0000000..ed907ec
--- /dev/null
@@ -0,0 +1,49 @@
+From mtosatti@redhat.com  Wed Oct 20 13:30:03 2010
+From: Marcelo Tosatti <mtosatti@redhat.com>
+Date: Thu, 14 Oct 2010 13:49:58 -0300
+Subject: KVM: fix irqfd assign/deassign race
+To: greg@kroah.com
+Cc: avi@redhat.com, mtosatti@redhat.com, stable@kernel.org, "Michael S. Tsirkin" <mst@redhat.com>, Gregory Haskins <ghaskins@novell.com>
+Message-ID: <20101014165150.836979786@redhat.com>
+
+From: Marcelo Tosatti <mtosatti@redhat.com>
+
+commit 6bbfb2653177a00f70e57e53625502d43804fed0 upstream.
+
+I think I see the following (theoretical) race:
+
+During irqfd assign, we drop irqfds lock before we
+schedule inject work. Therefore, deassign running
+on another CPU could cause shutdown and flush to run
+before inject, causing user after free in inject.
+
+A simple fix it to schedule inject under the lock.
+
+Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
+Acked-by: Gregory Haskins <ghaskins@novell.com>
+Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ virt/kvm/eventfd.c |    3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+--- a/virt/kvm/eventfd.c
++++ b/virt/kvm/eventfd.c
+@@ -217,7 +217,6 @@ kvm_irqfd_assign(struct kvm *kvm, int fd
+       events = file->f_op->poll(file, &irqfd->pt);
+       list_add_tail(&irqfd->list, &kvm->irqfds.items);
+-      spin_unlock_irq(&kvm->irqfds.lock);
+       /*
+        * Check if there was an event already pending on the eventfd
+@@ -226,6 +225,8 @@ kvm_irqfd_assign(struct kvm *kvm, int fd
+       if (events & POLLIN)
+               schedule_work(&irqfd->inject);
++      spin_unlock_irq(&kvm->irqfds.lock);
++
+       /*
+        * do not drop the file until the irqfd is fully initialized, otherwise
+        * we might race against the POLLHUP
diff --git a/queue-2.6.35/kvm-fix-reboot-on-intel-hosts.patch b/queue-2.6.35/kvm-fix-reboot-on-intel-hosts.patch
new file mode 100644 (file)
index 0000000..80cacf9
--- /dev/null
@@ -0,0 +1,46 @@
+From mtosatti@redhat.com  Wed Oct 20 13:30:25 2010
+From: Marcelo Tosatti <mtosatti@redhat.com>
+Date: Thu, 14 Oct 2010 13:49:59 -0300
+Subject: KVM: Fix reboot on Intel hosts
+To: greg@kroah.com
+Cc: mtosatti@redhat.com, avi@redhat.com, stable@kernel.org
+Message-ID: <20101014165150.905289130@redhat.com>
+
+From: Marcelo Tosatti <mtosatti@redhat.com>
+
+commit ca242ac9960dc61530e25a2c190e4e13fd5f1ecb upstream.
+
+When we reboot, we disable vmx extensions or otherwise INIT gets blocked.
+If a task on another cpu hits a vmx instruction, it will fault if vmx is
+disabled.  We trap that to avoid a nasty oops and spin until the reboot
+completes.
+
+Problem is, we sleep with interrupts disabled.  This blocks smp_send_stop()
+from running, and the reboot process halts.
+
+Fix by enabling interrupts before spinning.
+
+Signed-off-by: Avi Kivity <avi@redhat.com>
+Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ virt/kvm/kvm_main.c |    4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+--- a/virt/kvm/kvm_main.c
++++ b/virt/kvm/kvm_main.c
+@@ -1942,10 +1942,12 @@ static int kvm_cpu_hotplug(struct notifi
+ asmlinkage void kvm_handle_fault_on_reboot(void)
+ {
+-      if (kvm_rebooting)
++      if (kvm_rebooting) {
+               /* spin while reset goes on */
++              local_irq_enable();
+               while (true)
+                       ;
++      }
+       /* Fault while not rebooting.  We want the trace. */
+       BUG();
+ }
diff --git a/queue-2.6.35/kvm-i8259-fix-migration.patch b/queue-2.6.35/kvm-i8259-fix-migration.patch
new file mode 100644 (file)
index 0000000..738c86a
--- /dev/null
@@ -0,0 +1,41 @@
+From mtosatti@redhat.com  Wed Oct 20 13:28:59 2010
+From: Marcelo Tosatti <mtosatti@redhat.com>
+Date: Thu, 14 Oct 2010 13:49:55 -0300
+Subject: KVM: i8259: fix migration
+To: greg@kroah.com
+Cc: mtosatti@redhat.com, avi@redhat.com, Gleb Natapov <gleb@redhat.com>, stable@kernel.org
+Message-ID: <20101014165150.641000797@redhat.com>
+
+From: Marcelo Tosatti <mtosatti@redhat.com>
+
+commit eebb5f31b8d9a2620dcf32297096f8ce1240b179 upstream.
+
+Top of kvm_kpic_state structure should have the same memory layout as
+kvm_pic_state since it is copied by memcpy.
+
+Signed-off-by: Gleb Natapov <gleb@redhat.com>
+Signed-off-by: Avi Kivity <avi@redhat.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ arch/x86/kvm/irq.h |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/arch/x86/kvm/irq.h
++++ b/arch/x86/kvm/irq.h
+@@ -45,7 +45,6 @@ struct kvm_kpic_state {
+       u8 irr;         /* interrupt request register */
+       u8 imr;         /* interrupt mask register */
+       u8 isr;         /* interrupt service register */
+-      u8 isr_ack;     /* interrupt ack detection */
+       u8 priority_add;        /* highest irq priority */
+       u8 irq_base;
+       u8 read_reg_select;
+@@ -58,6 +57,7 @@ struct kvm_kpic_state {
+       u8 init4;               /* true if 4 byte init */
+       u8 elcr;                /* PIIX edge/trigger selection */
+       u8 elcr_mask;
++      u8 isr_ack;     /* interrupt ack detection */
+       struct kvm_pic *pics_state;
+ };
diff --git a/queue-2.6.35/kvm-x86-fix-svm-vmcb-reset.patch b/queue-2.6.35/kvm-x86-fix-svm-vmcb-reset.patch
new file mode 100644 (file)
index 0000000..53ac04b
--- /dev/null
@@ -0,0 +1,34 @@
+From mtosatti@redhat.com  Wed Oct 20 13:29:22 2010
+From: Marcelo Tosatti <mtosatti@redhat.com>
+Date: Thu, 14 Oct 2010 13:49:56 -0300
+Subject: KVM: x86: Fix SVM VMCB reset
+To: greg@kroah.com
+Cc: Zachary Amsden <zamsden@redhat.com>, mtosatti@redhat.com, avi@redhat.com, stable@kernel.org
+Message-ID: <20101014165150.717991626@redhat.com>
+
+From: Marcelo Tosatti <mtosatti@redhat.com>
+
+commit 58877679fd393d3ef71aa383031ac7817561463d upstream.
+
+On reset, VMCB TSC should be set to zero.  Instead, code was setting
+tsc_offset to zero, which passes through the underlying TSC.
+
+Signed-off-by: Zachary Amsden <zamsden@redhat.com>
+Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ arch/x86/kvm/svm.c |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/arch/x86/kvm/svm.c
++++ b/arch/x86/kvm/svm.c
+@@ -766,7 +766,7 @@ static void init_vmcb(struct vcpu_svm *s
+       control->iopm_base_pa = iopm_base;
+       control->msrpm_base_pa = __pa(svm->msrpm);
+-      control->tsc_offset = 0;
++      control->tsc_offset = 0-native_read_tsc();
+       control->int_ctl = V_INTR_MASKING_MASK;
+       init_seg(&save->es);
diff --git a/queue-2.6.35/kvm-x86-move-tsc-reset-out-of-vmcb_init.patch b/queue-2.6.35/kvm-x86-move-tsc-reset-out-of-vmcb_init.patch
new file mode 100644 (file)
index 0000000..7c98194
--- /dev/null
@@ -0,0 +1,44 @@
+From mtosatti@redhat.com  Wed Oct 20 13:29:42 2010
+From: Marcelo Tosatti <mtosatti@redhat.com>
+Date: Thu, 14 Oct 2010 13:49:57 -0300
+Subject: KVM: x86: Move TSC reset out of vmcb_init
+To: greg@kroah.com
+Cc: Zachary Amsden <zamsden@redhat.com>, mtosatti@redhat.com, avi@redhat.com, stable@kernel.org
+Message-ID: <20101014165150.793250530@redhat.com>
+
+From: Marcelo Tosatti <mtosatti@redhat.com>
+
+commit 47008cd887c1836bcadda123ba73e1863de7a6c4 upstream.
+
+The VMCB is reset whenever we receive a startup IPI, so Linux is setting
+TSC back to zero happens very late in the boot process and destabilizing
+the TSC.  Instead, just set TSC to zero once at VCPU creation time.
+
+Why the separate patch?  So git-bisect is your friend.
+
+Signed-off-by: Zachary Amsden <zamsden@redhat.com>
+Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ arch/x86/kvm/svm.c |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/arch/x86/kvm/svm.c
++++ b/arch/x86/kvm/svm.c
+@@ -766,7 +766,6 @@ static void init_vmcb(struct vcpu_svm *s
+       control->iopm_base_pa = iopm_base;
+       control->msrpm_base_pa = __pa(svm->msrpm);
+-      control->tsc_offset = 0-native_read_tsc();
+       control->int_ctl = V_INTR_MASKING_MASK;
+       init_seg(&save->es);
+@@ -902,6 +901,7 @@ static struct kvm_vcpu *svm_create_vcpu(
+       svm->vmcb_pa = page_to_pfn(page) << PAGE_SHIFT;
+       svm->asid_generation = 0;
+       init_vmcb(svm);
++      svm->vmcb->control.tsc_offset = 0-native_read_tsc();
+       fx_init(&svm->vcpu);
+       svm->vcpu.arch.apic_base = 0xfee00000 | MSR_IA32_APICBASE_ENABLE;
diff --git a/queue-2.6.35/mmc-sdio-fix-sdio-suspend-resume-regression.patch b/queue-2.6.35/mmc-sdio-fix-sdio-suspend-resume-regression.patch
new file mode 100644 (file)
index 0000000..de3f37d
--- /dev/null
@@ -0,0 +1,66 @@
+From 1c8cf9c997a4a6b36e907c7ede5f048aeaab1644 Mon Sep 17 00:00:00 2001
+From: Ohad Ben-Cohen <ohad@wizery.com>
+Date: Wed, 13 Oct 2010 09:31:56 +0200
+Subject: mmc: sdio: fix SDIO suspend/resume regression
+
+From: Ohad Ben-Cohen <ohad@wizery.com>
+
+commit 1c8cf9c997a4a6b36e907c7ede5f048aeaab1644 upstream.
+
+Fix SDIO suspend/resume regression introduced by 4c2ef25fe0b "mmc: fix
+all hangs related to mmc/sd card insert/removal during suspend/resume":
+
+  PM: Syncing filesystems ... done.
+  Freezing user space processes ... (elapsed 0.01 seconds) done.
+  Freezing remaining freezable tasks ... (elapsed 0.01 seconds) done.
+  Suspending console(s) (use no_console_suspend to debug)
+  pm_op(): platform_pm_suspend+0x0/0x5c returns -38
+  PM: Device pxa2xx-mci.0 failed to suspend: error -38
+  PM: Some devices failed to suspend
+
+4c2ef25fe0b moved the card removal/insertion mechanism out of MMC's
+suspend/resume path and into pm notifiers (mmc_pm_notify), and that
+broke SDIO's expectation that mmc_suspend_host() will remove the card,
+and squash the error, in case -ENOSYS is returned from the bus suspend
+handler (mmc_sdio_suspend() in this case).
+
+mmc_sdio_suspend() is using this whenever at least one of the card's SDIO
+function drivers does not have suspend/resume handlers - in that case
+it is agreed to force removal of the entire card.
+
+This patch fixes this regression by trivially bringing back that part of
+mmc_suspend_host(), which was removed by 4c2ef25fe0b.
+
+Reported-and-tested-by: Sven Neumann <s.neumann@raumfeld.com>
+Signed-off-by: Ohad Ben-Cohen <ohad@wizery.com>
+Cc: Maxim Levitsky <maximlevitsky@gmail.com>
+Acked-by: Nicolas Pitre <nico@fluxnic.net>
+Signed-off-by: Chris Ball <cjb@laptop.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/mmc/core/core.c |   13 +++++++++++++
+ 1 file changed, 13 insertions(+)
+
+--- a/drivers/mmc/core/core.c
++++ b/drivers/mmc/core/core.c
+@@ -1277,6 +1277,19 @@ int mmc_suspend_host(struct mmc_host *ho
+       if (host->bus_ops && !host->bus_dead) {
+               if (host->bus_ops->suspend)
+                       err = host->bus_ops->suspend(host);
++              if (err == -ENOSYS || !host->bus_ops->resume) {
++                      /*
++                       * We simply "remove" the card in this case.
++                       * It will be redetected on resume.
++                       */
++                      if (host->bus_ops->remove)
++                              host->bus_ops->remove(host);
++                      mmc_claim_host(host);
++                      mmc_detach_bus(host);
++                      mmc_release_host(host);
++                      host->pm_flags = 0;
++                      err = 0;
++              }
+       }
+       mmc_bus_put(host);
diff --git a/queue-2.6.35/r8169-allocate-with-gfp_kernel-flag-when-able-to-sleep.patch b/queue-2.6.35/r8169-allocate-with-gfp_kernel-flag-when-able-to-sleep.patch
new file mode 100644 (file)
index 0000000..eee96e1
--- /dev/null
@@ -0,0 +1,81 @@
+From aeb19f6052b5e5c8a24aa444fbff73b84341beac Mon Sep 17 00:00:00 2001
+From: Stanislaw Gruszka <sgruszka@redhat.com>
+Date: Fri, 8 Oct 2010 04:25:00 +0000
+Subject: r8169: allocate with GFP_KERNEL flag when able to sleep
+
+From: Stanislaw Gruszka <sgruszka@redhat.com>
+
+commit aeb19f6052b5e5c8a24aa444fbff73b84341beac upstream.
+
+We have fedora bug report where driver fail to initialize after
+suspend/resume because of memory allocation errors:
+https://bugzilla.redhat.com/show_bug.cgi?id=629158
+
+To fix use GFP_KERNEL allocation where possible.
+
+Tested-by: Neal Becker <ndbecker2@gmail.com>
+Signed-off-by: Stanislaw Gruszka <sgruszka@redhat.com>
+Acked-by: Eric Dumazet <eric.dumazet@gmail.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/net/r8169.c |   12 ++++++------
+ 1 file changed, 6 insertions(+), 6 deletions(-)
+
+--- a/drivers/net/r8169.c
++++ b/drivers/net/r8169.c
+@@ -4008,7 +4008,7 @@ static inline void rtl8169_map_to_asic(s
+ static struct sk_buff *rtl8169_alloc_rx_skb(struct pci_dev *pdev,
+                                           struct net_device *dev,
+                                           struct RxDesc *desc, int rx_buf_sz,
+-                                          unsigned int align)
++                                          unsigned int align, gfp_t gfp)
+ {
+       struct sk_buff *skb;
+       dma_addr_t mapping;
+@@ -4016,7 +4016,7 @@ static struct sk_buff *rtl8169_alloc_rx_
+       pad = align ? align : NET_IP_ALIGN;
+-      skb = netdev_alloc_skb(dev, rx_buf_sz + pad);
++      skb = __netdev_alloc_skb(dev, rx_buf_sz + pad, gfp);
+       if (!skb)
+               goto err_out;
+@@ -4047,7 +4047,7 @@ static void rtl8169_rx_clear(struct rtl8
+ }
+ static u32 rtl8169_rx_fill(struct rtl8169_private *tp, struct net_device *dev,
+-                         u32 start, u32 end)
++                         u32 start, u32 end, gfp_t gfp)
+ {
+       u32 cur;
+@@ -4062,7 +4062,7 @@ static u32 rtl8169_rx_fill(struct rtl816
+               skb = rtl8169_alloc_rx_skb(tp->pci_dev, dev,
+                                          tp->RxDescArray + i,
+-                                         tp->rx_buf_sz, tp->align);
++                                         tp->rx_buf_sz, tp->align, gfp);
+               if (!skb)
+                       break;
+@@ -4090,7 +4090,7 @@ static int rtl8169_init_ring(struct net_
+       memset(tp->tx_skb, 0x0, NUM_TX_DESC * sizeof(struct ring_info));
+       memset(tp->Rx_skbuff, 0x0, NUM_RX_DESC * sizeof(struct sk_buff *));
+-      if (rtl8169_rx_fill(tp, dev, 0, NUM_RX_DESC) != NUM_RX_DESC)
++      if (rtl8169_rx_fill(tp, dev, 0, NUM_RX_DESC, GFP_KERNEL) != NUM_RX_DESC)
+               goto err_out;
+       rtl8169_mark_as_last_descriptor(tp->RxDescArray + NUM_RX_DESC - 1);
+@@ -4591,7 +4591,7 @@ static int rtl8169_rx_interrupt(struct n
+       count = cur_rx - tp->cur_rx;
+       tp->cur_rx = cur_rx;
+-      delta = rtl8169_rx_fill(tp, dev, tp->dirty_rx, tp->cur_rx);
++      delta = rtl8169_rx_fill(tp, dev, tp->dirty_rx, tp->cur_rx, GFP_ATOMIC);
+       if (!delta && count)
+               netif_info(tp, intr, dev, "no Rx buffer allocated\n");
+       tp->dirty_rx += delta;
index 192c7aaa3459bcb4b57be2480340c9fc40bf9acb..541d0ed95c6de9fb97db34ddba3d3f4b4845c277 100644 (file)
@@ -68,3 +68,13 @@ drm-radeon-kms-fix-possible-sigbus-in-evergreen-accel-code.patch
 drm-radeon-kms-fix-up-encoder-info-messages-for-dfp6.patch
 drm-radeon-kms-fix-potential-segfault-in-r600_ioctl_wait_idle.patch
 drm-radeon-kms-add-quirk-for-msi-k9a2gm-motherboard.patch
+mmc-sdio-fix-sdio-suspend-resume-regression.patch
+v4l-dvb-dib7770-enable-the-current-mirror.patch
+xfs-properly-account-for-reclaimed-inodes.patch
+skge-add-quirk-to-limit-dma.patch
+r8169-allocate-with-gfp_kernel-flag-when-able-to-sleep.patch
+kvm-i8259-fix-migration.patch
+kvm-x86-fix-svm-vmcb-reset.patch
+kvm-x86-move-tsc-reset-out-of-vmcb_init.patch
+kvm-fix-irqfd-assign-deassign-race.patch
+kvm-fix-reboot-on-intel-hosts.patch
diff --git a/queue-2.6.35/skge-add-quirk-to-limit-dma.patch b/queue-2.6.35/skge-add-quirk-to-limit-dma.patch
new file mode 100644 (file)
index 0000000..8da3bfc
--- /dev/null
@@ -0,0 +1,75 @@
+From 392bd0cb000d4aac9e88e4f50823db85e7220688 Mon Sep 17 00:00:00 2001
+From: Stanislaw Gruszka <sgruszka@redhat.com>
+Date: Tue, 5 Oct 2010 15:11:40 -0700
+Subject: skge: add quirk to limit DMA
+
+From: Stanislaw Gruszka <sgruszka@redhat.com>
+
+commit 392bd0cb000d4aac9e88e4f50823db85e7220688 upstream.
+
+Skge devices installed on some Gigabyte motherboards are not able to
+perform 64 dma correctly due to board PCI implementation, so limit
+DMA to 32bit if such boards are detected.
+
+Bug was reported here:
+https://bugzilla.redhat.com/show_bug.cgi?id=447489
+
+Signed-off-by: Stanislaw Gruszka <sgruszka@redhat.com>
+Tested-by: Luya Tshimbalanga <luya@fedoraproject.org>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/net/skge.c |   18 +++++++++++++++++-
+ 1 file changed, 17 insertions(+), 1 deletion(-)
+
+--- a/drivers/net/skge.c
++++ b/drivers/net/skge.c
+@@ -43,6 +43,7 @@
+ #include <linux/seq_file.h>
+ #include <linux/mii.h>
+ #include <linux/slab.h>
++#include <linux/dmi.h>
+ #include <asm/irq.h>
+ #include "skge.h"
+@@ -3868,6 +3869,8 @@ static void __devinit skge_show_addr(str
+       netif_info(skge, probe, skge->netdev, "addr %pM\n", dev->dev_addr);
+ }
++static int only_32bit_dma;
++
+ static int __devinit skge_probe(struct pci_dev *pdev,
+                               const struct pci_device_id *ent)
+ {
+@@ -3889,7 +3892,7 @@ static int __devinit skge_probe(struct p
+       pci_set_master(pdev);
+-      if (!pci_set_dma_mask(pdev, DMA_BIT_MASK(64))) {
++      if (!only_32bit_dma && !pci_set_dma_mask(pdev, DMA_BIT_MASK(64))) {
+               using_dac = 1;
+               err = pci_set_consistent_dma_mask(pdev, DMA_BIT_MASK(64));
+       } else if (!(err = pci_set_dma_mask(pdev, DMA_BIT_MASK(32)))) {
+@@ -4147,8 +4150,21 @@ static struct pci_driver skge_driver = {
+       .shutdown =     skge_shutdown,
+ };
++static struct dmi_system_id skge_32bit_dma_boards[] = {
++      {
++              .ident = "Gigabyte nForce boards",
++              .matches = {
++                      DMI_MATCH(DMI_BOARD_VENDOR, "Gigabyte Technology Co"),
++                      DMI_MATCH(DMI_BOARD_NAME, "nForce"),
++              },
++      },
++      {}
++};
++
+ static int __init skge_init_module(void)
+ {
++      if (dmi_check_system(skge_32bit_dma_boards))
++              only_32bit_dma = 1;
+       skge_debug_init();
+       return pci_register_driver(&skge_driver);
+ }
diff --git a/queue-2.6.35/v4l-dvb-dib7770-enable-the-current-mirror.patch b/queue-2.6.35/v4l-dvb-dib7770-enable-the-current-mirror.patch
new file mode 100644 (file)
index 0000000..6e51e89
--- /dev/null
@@ -0,0 +1,119 @@
+From 90e12cec707204930934acdb5efce5f94a163a5f Mon Sep 17 00:00:00 2001
+From: Olivier Grenie <olivier.grenie@dibcom.fr>
+Date: Tue, 7 Sep 2010 12:50:45 -0300
+Subject: V4L/DVB: dib7770: enable the current mirror
+
+From: Olivier Grenie <olivier.grenie@dibcom.fr>
+
+commit 90e12cec707204930934acdb5efce5f94a163a5f upstream.
+
+To improve performance on DiB7770-devices enabling the current mirror
+is needed.
+
+This patch adds an option to the dib7000p-driver to do that and it
+creates a separate device-entry in dib0700-device to use those changes
+on hardware which is using the DiB7770.
+
+Signed-off-by: Olivier Grenie <olivier.grenie@dibcom.fr>
+Signed-off-by: Patrick Boettcher <patrick.boettcher@dibcom.fr>
+Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ drivers/media/dvb/dvb-usb/dib0700_devices.c |   53 +++++++++++++++++++++++++++-
+ drivers/media/dvb/frontends/dib7000p.c      |    2 +
+ drivers/media/dvb/frontends/dib7000p.h      |    3 +
+ 3 files changed, 57 insertions(+), 1 deletion(-)
+
+--- a/drivers/media/dvb/dvb-usb/dib0700_devices.c
++++ b/drivers/media/dvb/dvb-usb/dib0700_devices.c
+@@ -1240,6 +1240,57 @@ static int stk7070p_frontend_attach(stru
+       return adap->fe == NULL ? -ENODEV : 0;
+ }
++/* STK7770P */
++static struct dib7000p_config dib7770p_dib7000p_config = {
++      .output_mpeg2_in_188_bytes = 1,
++
++      .agc_config_count = 1,
++      .agc = &dib7070_agc_config,
++      .bw  = &dib7070_bw_config_12_mhz,
++      .tuner_is_baseband = 1,
++      .spur_protect = 1,
++
++      .gpio_dir = DIB7000P_GPIO_DEFAULT_DIRECTIONS,
++      .gpio_val = DIB7000P_GPIO_DEFAULT_VALUES,
++      .gpio_pwm_pos = DIB7000P_GPIO_DEFAULT_PWM_POS,
++
++      .hostbus_diversity = 1,
++      .enable_current_mirror = 1,
++};
++
++static int stk7770p_frontend_attach(struct dvb_usb_adapter *adap)
++{
++      struct usb_device_descriptor *p = &adap->dev->udev->descriptor;
++      if (p->idVendor  == cpu_to_le16(USB_VID_PINNACLE) &&
++          p->idProduct == cpu_to_le16(USB_PID_PINNACLE_PCTV72E))
++              dib0700_set_gpio(adap->dev, GPIO6, GPIO_OUT, 0);
++      else
++              dib0700_set_gpio(adap->dev, GPIO6, GPIO_OUT, 1);
++      msleep(10);
++      dib0700_set_gpio(adap->dev, GPIO9, GPIO_OUT, 1);
++      dib0700_set_gpio(adap->dev, GPIO4, GPIO_OUT, 1);
++      dib0700_set_gpio(adap->dev, GPIO7, GPIO_OUT, 1);
++      dib0700_set_gpio(adap->dev, GPIO10, GPIO_OUT, 0);
++
++      dib0700_ctrl_clock(adap->dev, 72, 1);
++
++      msleep(10);
++      dib0700_set_gpio(adap->dev, GPIO10, GPIO_OUT, 1);
++      msleep(10);
++      dib0700_set_gpio(adap->dev, GPIO0, GPIO_OUT, 1);
++
++      if (dib7000p_i2c_enumeration(&adap->dev->i2c_adap, 1, 18,
++                                   &dib7770p_dib7000p_config) != 0) {
++              err("%s: dib7000p_i2c_enumeration failed.  Cannot continue\n",
++                  __func__);
++              return -ENODEV;
++      }
++
++      adap->fe = dvb_attach(dib7000p_attach, &adap->dev->i2c_adap, 0x80,
++              &dib7770p_dib7000p_config);
++      return adap->fe == NULL ? -ENODEV : 0;
++}
++
+ /* DIB807x generic */
+ static struct dibx000_agc_config dib807x_agc_config[2] = {
+       {
+@@ -2592,7 +2643,7 @@ struct dvb_usb_device_properties dib0700
+                               .pid_filter_count = 32,
+                               .pid_filter       = stk70x0p_pid_filter,
+                               .pid_filter_ctrl  = stk70x0p_pid_filter_ctrl,
+-                              .frontend_attach  = stk7070p_frontend_attach,
++                              .frontend_attach  = stk7770p_frontend_attach,
+                               .tuner_attach     = dib7770p_tuner_attach,
+                               DIB0700_DEFAULT_STREAMING_CONFIG(0x02),
+--- a/drivers/media/dvb/frontends/dib7000p.c
++++ b/drivers/media/dvb/frontends/dib7000p.c
+@@ -260,6 +260,8 @@ static void dib7000p_set_adc_state(struc
+ //    dprintk( "908: %x, 909: %x\n", reg_908, reg_909);
++      reg_908 |= (state->cfg.enable_current_mirror & 1) << 7;
++
+       dib7000p_write_word(state, 908, reg_908);
+       dib7000p_write_word(state, 909, reg_909);
+ }
+--- a/drivers/media/dvb/frontends/dib7000p.h
++++ b/drivers/media/dvb/frontends/dib7000p.h
+@@ -33,6 +33,9 @@ struct dib7000p_config {
+       int (*agc_control) (struct dvb_frontend *, u8 before);
+       u8 output_mode;
++
++      u8 enable_current_mirror : 1;
++
+ };
+ #define DEFAULT_DIB7000P_I2C_ADDRESS 18
diff --git a/queue-2.6.35/xfs-properly-account-for-reclaimed-inodes.patch b/queue-2.6.35/xfs-properly-account-for-reclaimed-inodes.patch
new file mode 100644 (file)
index 0000000..eca0c51
--- /dev/null
@@ -0,0 +1,101 @@
+From 081003fff467ea0e727f66d5d435b4f473a789b3 Mon Sep 17 00:00:00 2001
+From: Johannes Weiner <hannes@cmpxchg.org>
+Date: Fri, 1 Oct 2010 07:43:54 +0000
+Subject: xfs: properly account for reclaimed inodes
+
+From: Johannes Weiner <hannes@cmpxchg.org>
+
+commit 081003fff467ea0e727f66d5d435b4f473a789b3 upstream.
+
+When marking an inode reclaimable, a per-AG counter is increased, the
+inode is tagged reclaimable in its per-AG tree, and, when this is the
+first reclaimable inode in the AG, the AG entry in the per-mount tree
+is also tagged.
+
+When an inode is finally reclaimed, however, it is only deleted from
+the per-AG tree.  Neither the counter is decreased, nor is the parent
+tree's AG entry untagged properly.
+
+Since the tags in the per-mount tree are not cleared, the inode
+shrinker iterates over all AGs that have had reclaimable inodes at one
+point in time.
+
+The counters on the other hand signal an increasing amount of slab
+objects to reclaim.  Since "70e60ce xfs: convert inode shrinker to
+per-filesystem context" this is not a real issue anymore because the
+shrinker bails out after one iteration.
+
+But the problem was observable on a machine running v2.6.34, where the
+reclaimable work increased and each process going into direct reclaim
+eventually got stuck on the xfs inode shrinking path, trying to scan
+several million objects.
+
+Fix this by properly unwinding the reclaimable-state tracking of an
+inode when it is reclaimed.
+
+Signed-off-by: Johannes Weiner <hannes@cmpxchg.org>
+Reviewed-by: Dave Chinner <dchinner@redhat.com>
+Signed-off-by: Alex Elder <aelder@sgi.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ fs/xfs/linux-2.6/xfs_sync.c |   16 ++++++++++++----
+ fs/xfs/linux-2.6/xfs_sync.h |    1 +
+ fs/xfs/xfs_iget.c           |    1 +
+ 3 files changed, 14 insertions(+), 4 deletions(-)
+
+--- a/fs/xfs/linux-2.6/xfs_sync.c
++++ b/fs/xfs/linux-2.6/xfs_sync.c
+@@ -711,13 +711,10 @@ xfs_inode_set_reclaim_tag(
+ }
+ void
+-__xfs_inode_clear_reclaim_tag(
+-      xfs_mount_t     *mp,
++__xfs_inode_clear_reclaim(
+       xfs_perag_t     *pag,
+       xfs_inode_t     *ip)
+ {
+-      radix_tree_tag_clear(&pag->pag_ici_root,
+-                      XFS_INO_TO_AGINO(mp, ip->i_ino), XFS_ICI_RECLAIM_TAG);
+       pag->pag_ici_reclaimable--;
+       if (!pag->pag_ici_reclaimable) {
+               /* clear the reclaim tag from the perag radix tree */
+@@ -731,6 +728,17 @@ __xfs_inode_clear_reclaim_tag(
+       }
+ }
++void
++__xfs_inode_clear_reclaim_tag(
++      xfs_mount_t     *mp,
++      xfs_perag_t     *pag,
++      xfs_inode_t     *ip)
++{
++      radix_tree_tag_clear(&pag->pag_ici_root,
++                      XFS_INO_TO_AGINO(mp, ip->i_ino), XFS_ICI_RECLAIM_TAG);
++      __xfs_inode_clear_reclaim(pag, ip);
++}
++
+ /*
+  * Inodes in different states need to be treated differently, and the return
+  * value of xfs_iflush is not sufficient to get this right. The following table
+--- a/fs/xfs/linux-2.6/xfs_sync.h
++++ b/fs/xfs/linux-2.6/xfs_sync.h
+@@ -47,6 +47,7 @@ int xfs_reclaim_inodes(struct xfs_mount
+ void xfs_inode_set_reclaim_tag(struct xfs_inode *ip);
+ void __xfs_inode_set_reclaim_tag(struct xfs_perag *pag, struct xfs_inode *ip);
++void __xfs_inode_clear_reclaim(struct xfs_perag *pag, struct xfs_inode *ip);
+ void __xfs_inode_clear_reclaim_tag(struct xfs_mount *mp, struct xfs_perag *pag,
+                               struct xfs_inode *ip);
+--- a/fs/xfs/xfs_iget.c
++++ b/fs/xfs/xfs_iget.c
+@@ -492,6 +492,7 @@ xfs_ireclaim(
+       write_lock(&pag->pag_ici_lock);
+       if (!radix_tree_delete(&pag->pag_ici_root, agino))
+               ASSERT(0);
++      __xfs_inode_clear_reclaim(pag, ip);
+       write_unlock(&pag->pag_ici_lock);
+       xfs_perag_put(pag);