[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-changelog] [linux-2.6.18-xen] xen: don't round up swiotlb slab count



# HG changeset patch
# User Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1220022770 -3600
# Node ID 4dc80607377dedd7d7125a1a91f606463dc81de5
# Parent  e86b8e0ac6fdc3144976c4ea0bd922532a1fe8b4
xen: don't round up swiotlb slab count

This has been unnecessary for a long time, as
xen_create_contiguous_region() is no longer called on the whole area
at once, and the rounding can (under certain circumstances) prevent
the kernel from successfully booting when a larger than the default
size is needed.

Signed-off-by: Jan Beulich <jbeulich@xxxxxxxxxx>
---
 lib/swiotlb-xen.c |    6 ------
 1 files changed, 6 deletions(-)

diff -r e86b8e0ac6fd -r 4dc80607377d lib/swiotlb-xen.c
--- a/lib/swiotlb-xen.c Thu Aug 21 10:36:07 2008 +0100
+++ b/lib/swiotlb-xen.c Fri Aug 29 16:12:50 2008 +0100
@@ -114,9 +114,6 @@ setup_io_tlb_npages(char *str)
                iotlb_nslabs = simple_strtoul(str, &str, 0) <<
                        (20 - IO_TLB_SHIFT);
                iotlb_nslabs = ALIGN(iotlb_nslabs, IO_TLB_SEGSIZE);
-               /* Round up to power of two (xen_create_contiguous_region). */
-               while (iotlb_nslabs & (iotlb_nslabs-1))
-                       iotlb_nslabs += iotlb_nslabs & ~(iotlb_nslabs-1);
        }
        if (*str == ',')
                ++str;
@@ -147,9 +144,6 @@ swiotlb_init_with_default_size (size_t d
        if (!iotlb_nslabs) {
                iotlb_nslabs = (default_size >> IO_TLB_SHIFT);
                iotlb_nslabs = ALIGN(iotlb_nslabs, IO_TLB_SEGSIZE);
-               /* Round up to power of two (xen_create_contiguous_region). */
-               while (iotlb_nslabs & (iotlb_nslabs-1))
-                       iotlb_nslabs += iotlb_nslabs & ~(iotlb_nslabs-1);
        }
 
        bytes = iotlb_nslabs * (1UL << IO_TLB_SHIFT);

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.