WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [Xen-devel] Question regarding SLAB corruption

To: Lukas Hejtmanek <xhejtman@xxxxxxxxxxx>
Subject: Re: [Xen-devel] Question regarding SLAB corruption
From: Keir Fraser <keir@xxxxxxxxxxxxx>
Date: Mon, 09 Jul 2007 13:47:34 +0100
Cc: xen-devel@xxxxxxxxxxxxxxxxxxx
Delivery-date: Mon, 09 Jul 2007 05:45:35 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <20070709120734.GH3885@xxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Thread-index: AcfCJ1IVkF4ZNS4aEdyVxQAX8io7RQ==
Thread-topic: [Xen-devel] Question regarding SLAB corruption
User-agent: Microsoft-Entourage/11.3.3.061214
On 9/7/07 13:07, "Lukas Hejtmanek" <xhejtman@xxxxxxxxxxx> wrote:

> According to IB developers, it uses alloc_pages and then pci_map_sg which they
> state that is DMA API. So, is it correct approach?

Well, we currently assume that segments of a scatterlist (as passed to
pci_map_sg) do not cross page boundaries. It looks like this assumption is
broken (certainly for the infiniband driver!).

I've just checked in the attached patch to fix this issue. Please give it a
try in your dom0 tree.

> I did debug like this - so it prints physical and virtual addresses and they
> seems to be perfectly contiguous. Are the physical addresses real physical
> addresses or virtualized by Xen hypervisor?

You want to use virt_to_machine(). As you say, the addresses returned by
virt_to_phys() are virtual-physical, which is not what you want.

 -- Keir

Attachment: map_sg.patch
Description: Binary data

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