r1795 - in trunk/kernel/source/kernel-source-2.6.8-2.6.8/debian: . patches patches/series

Dann Frazier dannf@haydn.debian.org
Fri, 05 Nov 2004 15:01:18 -0700


Author: dannf
Date: 2004-11-05 15:00:58 -0700 (Fri, 05 Nov 2004)
New Revision: 1795

Added:
   trunk/kernel/source/kernel-source-2.6.8-2.6.8/debian/patches/ia64-hp-sba_iommu-fix.dpatch
Modified:
   trunk/kernel/source/kernel-source-2.6.8-2.6.8/debian/changelog
   trunk/kernel/source/kernel-source-2.6.8-2.6.8/debian/patches/series/2.6.8-8
Log:
add the ia64-hp-sba_iommu-fix patch


Modified: trunk/kernel/source/kernel-source-2.6.8-2.6.8/debian/changelog
===================================================================
--- trunk/kernel/source/kernel-source-2.6.8-2.6.8/debian/changelog	2004-11-05 21:41:08 UTC (rev 1794)
+++ trunk/kernel/source/kernel-source-2.6.8-2.6.8/debian/changelog	2004-11-05 22:00:58 UTC (rev 1795)
@@ -54,8 +54,11 @@
   * Via Velocity Driver update from 2.6.9
     (Possible fix for: Bug#278508) (Simon Horman)
 
- -- Simon Horman <horms@debian.org>  Fri,  5 Nov 2004 17:27:51 +0900
+  * [ia64] fix a bug that causes HP systems to run out of DMA mapping resources
+    under heavy load (dann frazier)
 
+ -- dann frazier <dannf@debian.org>  Fri, 05 Nov 2004 14:50:21 -0700
+
 kernel-source-2.6.8 (2.6.8-7) unstable; urgency=medium
 
   * Fix VGA console on PReP systems (closes: #271852) (Jens Schmalzing).

Added: trunk/kernel/source/kernel-source-2.6.8-2.6.8/debian/patches/ia64-hp-sba_iommu-fix.dpatch
===================================================================
--- trunk/kernel/source/kernel-source-2.6.8-2.6.8/debian/patches/ia64-hp-sba_iommu-fix.dpatch	2004-11-05 21:41:08 UTC (rev 1794)
+++ trunk/kernel/source/kernel-source-2.6.8-2.6.8/debian/patches/ia64-hp-sba_iommu-fix.dpatch	2004-11-05 22:00:58 UTC (rev 1795)
@@ -0,0 +1,53 @@
+#! /bin/sh -e 
+## <PATCHNAME>.dpatch by <PATCH_AUTHOR@EMAI>
+##
+## All lines beginning with `## DP:' are a description of the patch.
+## DP: Description: Fix a DMA mapping resource issue on HP ia64 systems
+## DP: Patch author: Nigel Croxon <nigel.croxon@hp.com>
+## DP: Upstream status: backport
+
+. $(dirname $0)/DPATCH
+
+@DPATCH@
+# This is a BitKeeper generated diff -Nru style patch.
+#
+# ChangeSet
+#   2004/11/03 14:46:01-08:00 nigel.croxon@hp.com 
+#   [IA64-HP] Fix for bits_wanted in sba_iommu.c
+#   
+#   bits_wanted is expanded to bytes using the wrong shift value
+#   (when iovp_shift != PAGE_SHIFT), resulting in an explosion of
+#   used iommu resources.
+#   
+#   This potentially results in mistakenly running out of DMA mapping
+#   resources when the system is under *heavy* i/o load.
+#   
+#   Signed-off-by: Nigel Croxon <nigel.croxon@hp.com>
+#   Signed-off by: Alex Williamson <alex.williamson@hp.com>
+#   Signed-off-by: Tony Luck <tony.luck@intel.com>
+# 
+# arch/ia64/hp/common/sba_iommu.c
+#   2004/11/03 14:43:08-08:00 nigel.croxon@hp.com +2 -2
+#   Fix for bits_wanted in sba_iommu.c
+# 
+diff -Nru a/arch/ia64/hp/common/sba_iommu.c b/arch/ia64/hp/common/sba_iommu.c
+--- a/arch/ia64/hp/common/sba_iommu.c	2004-11-04 18:28:50 -08:00
++++ b/arch/ia64/hp/common/sba_iommu.c	2004-11-04 18:28:50 -08:00
+@@ -479,7 +479,7 @@
+ 	 * purges IOTLB entries in power-of-two sizes, so we also
+ 	 * allocate IOVA space in power-of-two sizes.
+ 	 */
+-	bits_wanted = 1UL << get_iovp_order(bits_wanted << PAGE_SHIFT);
++	bits_wanted = 1UL << get_iovp_order(bits_wanted << iovp_shift);
+ 
+ 	if (likely(bits_wanted == 1)) {
+ 		unsigned int bitshiftcnt;
+@@ -688,7 +688,7 @@
+ 	unsigned long m;
+ 
+ 	/* Round up to power-of-two size: see AR2305 note above */
+-	bits_not_wanted = 1UL << get_iovp_order(bits_not_wanted << PAGE_SHIFT);
++	bits_not_wanted = 1UL << get_iovp_order(bits_not_wanted << iovp_shift);
+ 	for (; bits_not_wanted > 0 ; res_ptr++) {
+ 		
+ 		if (unlikely(bits_not_wanted > BITS_PER_LONG)) {

Modified: trunk/kernel/source/kernel-source-2.6.8-2.6.8/debian/patches/series/2.6.8-8
===================================================================
--- trunk/kernel/source/kernel-source-2.6.8-2.6.8/debian/patches/series/2.6.8-8	2004-11-05 21:41:08 UTC (rev 1794)
+++ trunk/kernel/source/kernel-source-2.6.8-2.6.8/debian/patches/series/2.6.8-8	2004-11-05 22:00:58 UTC (rev 1795)
@@ -38,4 +38,4 @@
 + via-velocity-update-11.dpatch
 + via-velocity-update-12.dpatch
 + via-velocity-update-13.dpatch
-
++ ia64-hp-sba_iommu-fix.dpatch