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] pvops dom0: no sound after boot; possibly causedby swiot

To: <konrad.wilk@xxxxxxxxxx>
Subject: Re: [Xen-devel] pvops dom0: no sound after boot; possibly causedby swiotlb
From: Ronny.Hegewald@xxxxxxxxx
Date: Thu, 04 Feb 2010 01:55:40 +0100
Cc: xen-devel@xxxxxxxxxxxxxxxxxxx
Delivery-date: Wed, 03 Feb 2010 16:56:00 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
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/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
> I am curious - if you dom0 is 64-bit, does the sound card work? 

Yes with 64-bit pvops-dom0 the sound works fine without any patches.

>> 
>> Ooooh. I completly failed to notice that your dom0 was 32-bit.
>> 
>> But having that there would make the mask always be below
>> 4GB, irregardless if the dom0 is 32 or 64-bit. Which is 
>> exactly what it does on bare-metal. 
><sigh> That is actually incorrect. Looking at the
>dma_alloc_coherent_mask I missed the '!' and thought it would set it
>irregardless of what the previous value was. That is not the case.

No, your first statement was correct. It would always return the same mask for 
32-bit and 64-bit, because of the 32-bitness of the return-variable 'dma_mask'.

So the following patch maybe would be more appropriate?

--- arch/x86/xen/pci-swiotlb.c-org      2010-02-01 23:04:42.000000000 +0100
+++ arch/x86/xen/pci-swiotlb.c  2010-02-04 02:47:17.000000000 +0100
@@ -602,7 +602,11 @@ xen_swiotlb_alloc_coherent(struct device
        ret = (void *)vstart;

        if (hwdev != NULL && hwdev->coherent_dma_mask)
+#ifdef CONFIG_X86_32
+               mask = dma_alloc_coherent_mask(hwdev, flags);
+#else
                mask = hwdev->coherent_dma_mask;
+#endif

        else
                mask = DMA_BIT_MASK(32);

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

<Prev in Thread] Current Thread [Next in Thread>