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: Roland Dreier <rdreier@xxxxxxxxx>
Subject: Re: [Xen-devel] Question regarding SLAB corruption
From: Keir Fraser <keir@xxxxxxxxxxxxx>
Date: Mon, 09 Jul 2007 22:33:15 +0100
Cc: Lukas Hejtmanek <xhejtman@xxxxxxxxxxx>, xen-devel@xxxxxxxxxxxxxxxxxxx
Delivery-date: Mon, 09 Jul 2007 14:28:04 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <adad4z1xo8a.fsf@xxxxxxxxx>
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: AcfCcMH8AKEDPy5kEdynZwAWy6hiGQ==
Thread-topic: [Xen-devel] Question regarding SLAB corruption
User-agent: Microsoft-Entourage/11.3.3.061214
On 9/7/07 22:26, "Roland Dreier" <rdreier@xxxxxxxxx> wrote:

>> Oh! I take it then that the infiniband driver will call sync_single() on
>> subsections of a mapped region? I haven't seen that behaviour before and it
>> will kill lib/swiotlb.c (the generic Linux swiotlb implementation) just as
>> surely as it does the Xen-specific swiotlb!
> 
>> We could make the swiotlb robust to this treatment, I guess. It will involve
>> initialising all covered io_tlb_orig_addr[] slots rather than just the
>> first.
> 
> Does this mean that lib/swiotlb.c's swiotlb_sync_single_range_for_cpu()
> and swiotlb_sync_single_range_for_device() are broken?  Given that (as
> you say) io_tlb_orig_addr[] only gets one slot filled in at the end of
> map_single(), I don't see any way it could work if more than one page
> is mapped.

Yeah, see the email I posted just one second ago. :-)

So my workaround patches are quite applicable to lib/swiotlb.c as a genuine
bug fix!

 -- Keir


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