From mboxrd@z Thu Jan 1 00:00:00 1970 From: Alex Williamson Subject: Re: Seeing DMAR errors after multiple load/unload with SR-IOV Date: Tue, 07 Jun 2011 09:40:29 -0600 Message-ID: <1307461231.5901.20.camel@x201> References: <1307398661.5901.14.camel@x201> <20110606223451.GW23047@sequoia.sous-sol.org> <20110607133804.GX23047@sequoia.sous-sol.org> <1307454415.24181.46.camel@i7.infradead.org> <20110607151032.GZ23047@sequoia.sous-sol.org> <1307460801.24181.51.camel@i7.infradead.org> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit Cc: Chris Wright , padmanabh ratnakar , iommu , linux-kernel@vger.kernel.org, kvm@vger.kernel.org To: David Woodhouse Return-path: In-Reply-To: <1307460801.24181.51.camel@i7.infradead.org> Sender: linux-kernel-owner@vger.kernel.org List-Id: kvm.vger.kernel.org On Tue, 2011-06-07 at 16:33 +0100, David Woodhouse wrote: > On Tue, 2011-06-07 at 08:10 -0700, Chris Wright wrote: > > * David Woodhouse (dwmw2@infradead.org) wrote: > > > On Tue, 2011-06-07 at 06:38 -0700, Chris Wright wrote: > > > > I think we still leak the list entry though. Bottom line is that we > > > > need to handle hotplug ADD_DEVICE and DEL_DEVICE notifications. We > > > > happen to pick up ADD_DEVICE by accident, but it's all pretty sloppy. > > > > > > Yeah, keeping a list of possible stale 'pci_dev' pointers is stupid. We > > > should figure out the matching DMAR unit directly from the ACPI table at > > > ADD_DEVICE time, and store it in pdev->archdata.iommu. > > > > > > I saw patches which were going in that direction... > > > > Cool, where are they? I'm working on something similar, and missed them. > > [PATCH] pci, dmar: Update dmar units devices list during hotplug > > Alex was working on it. Nope, I had a wip patch that did an on-the-fly lookup, that I handed off to Yinghai, but it didn't actually work. That's when the suggestion was made to do it at hotplug, but I'm not pursuing that right now, maybe Yinghai is? Thanks, Alex Alex