# HG changeset patch
# User kaf24@xxxxxxxxxxxxxxxxxxxx
# Node ID 4f0bc574455751ed0493f083c13911d8e01b92f0
# Parent 7fba181c853186d90cf703816e30bf610c61a81d
[LINUX] Network buffers do not need to be multi-page contiguous
for unprivileged domains (in any case, can fall back to swiotlb).
On non-privileged domain of Xen/IA64, this caused some trouble.
Signed-off-by: Isaku Yamahata <yamahata@xxxxxxxxxxxxx>
---
linux-2.6-xen-sparse/drivers/xen/core/skbuff.c | 11 +++++++++--
1 files changed, 9 insertions(+), 2 deletions(-)
diff -r 7fba181c8531 -r 4f0bc5744557
linux-2.6-xen-sparse/drivers/xen/core/skbuff.c
--- a/linux-2.6-xen-sparse/drivers/xen/core/skbuff.c Thu Jun 15 13:11:31
2006 +0100
+++ b/linux-2.6-xen-sparse/drivers/xen/core/skbuff.c Thu Jun 15 13:19:04
2006 +0100
@@ -121,8 +121,15 @@ static int __init skbuff_init(void)
for (order = 0; order <= MAX_SKBUFF_ORDER; order++) {
size = PAGE_SIZE << order;
sprintf(name[order], "xen-skb-%lu", size);
- skbuff_order_cachep[order] = kmem_cache_create(
- name[order], size, size, 0, skbuff_ctor, skbuff_dtor);
+ if (is_running_on_xen() &&
+ (xen_start_info->flags & SIF_PRIVILEGED))
+ skbuff_order_cachep[order] = kmem_cache_create(
+ name[order], size, size, 0,
+ skbuff_ctor, skbuff_dtor);
+ else
+ skbuff_order_cachep[order] = kmem_cache_create(
+ name[order], size, size, 0, NULL, NULL);
+
}
skbuff_cachep = skbuff_order_cachep[0];
_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog
|