Re: [PATCH 11/12] swiotlb: merge swiotlb-xen initialization into swiotlb
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
- To: Boris Ostrovsky <boris.ostrovsky@xxxxxxxxxx>
- Subject: Re: [PATCH 11/12] swiotlb: merge swiotlb-xen initialization into swiotlb
- From: Christoph Hellwig <hch@xxxxxx>
- Date: Fri, 4 Mar 2022 18:43:08 +0100
- Cc: Christoph Hellwig <hch@xxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, iommu@xxxxxxxxxxxxxxxxxxxxxxxxxx, x86@xxxxxxxxxx, Anshuman Khandual <anshuman.khandual@xxxxxxx>, Tom Lendacky <thomas.lendacky@xxxxxxx>, Konrad Rzeszutek Wilk <konrad.wilk@xxxxxxxxxx>, Juergen Gross <jgross@xxxxxxxx>, Joerg Roedel <joro@xxxxxxxxxx>, David Woodhouse <dwmw2@xxxxxxxxxxxxx>, Lu Baolu <baolu.lu@xxxxxxxxxxxxxxx>, Robin Murphy <robin.murphy@xxxxxxx>, linux-arm-kernel@xxxxxxxxxxxxxxxxxxx, xen-devel@xxxxxxxxxxxxxxxxxxxx, linux-ia64@xxxxxxxxxxxxxxx, linux-mips@xxxxxxxxxxxxxxx, linuxppc-dev@xxxxxxxxxxxxxxxx, linux-riscv@xxxxxxxxxxxxxxxxxxx, linux-s390@xxxxxxxxxxxxxxx, linux-hyperv@xxxxxxxxxxxxxxx, tboot-devel@xxxxxxxxxxxxxxxxxxxxx, linux-pci@xxxxxxxxxxxxxxx
- In-reply-to: <fc3992a8-896b-f0fc-e500-9010ec085c57@oracle.com>
- References: <20220301105311.885699-1-hch@lst.de> <20220301105311.885699-12-hch@lst.de> <alpine.DEB.2.22.394.2203011720150.3261@ubuntu-linux-20-04-desktop> <ca748512-12bb-7d75-13f1-8d5ec9703e26@oracle.com> <20220304172859.GA12860@lst.de> <fc3992a8-896b-f0fc-e500-9010ec085c57@oracle.com>
- User-agent: Mutt/1.5.17 (2007-11-01)
On Fri, Mar 04, 2022 at 12:36:17PM -0500, Boris Ostrovsky wrote:
>>> I bisected it to "x86: remove the IOMMU table infrastructure" but haven't actually looked at the code yet.
>> That looks like the swiotlb buffer did not get initialized at all, but I
>> can't really explain why.
>>
>> Can you stick in a printk and see if xen_swiotlb_init_early gets called
>> at all?
>
>
>
> Actually, that's the only thing I did do so far and yes, it does get called.
So, specifically for "x86: remove the IOMMU table infrastructure" I
think we need the one-liner below so that swiotlb_exit doesn't get called
for the Xen case. But that should have been fixed up by the next
patch already.
diff --git a/arch/x86/kernel/pci-dma.c b/arch/x86/kernel/pci-dma.c
index 2ac0ef9c2fb76..1173aa282ab27 100644
--- a/arch/x86/kernel/pci-dma.c
+++ b/arch/x86/kernel/pci-dma.c
@@ -70,7 +70,7 @@ static void __init pci_xen_swiotlb_init(void)
if (!xen_initial_domain() && !x86_swiotlb_enable &&
swiotlb_force != SWIOTLB_FORCE)
return;
- x86_swiotlb_enable = false;
+ x86_swiotlb_enable = true;
xen_swiotlb = true;
xen_swiotlb_init_early();
dma_ops = &xen_swiotlb_dma_ops;
[Index of Archives]
[Linux Kernel]
[Sparc Linux]
[DCCP]
[Linux ARM]
[Yosemite News]
[Linux SCSI]
[Linux x86_64]
[Linux for Ham Radio]