[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20190910081415.GB3247@8bytes.org>
Date: Tue, 10 Sep 2019 10:14:15 +0200
From: Joerg Roedel <joro@...tes.org>
To: Rob Clark <robdclark@...il.com>
Cc: iommu@...ts.linux-foundation.org, dri-devel@...ts.freedesktop.org,
linux-arm-msm@...r.kernel.org, Robin Murphy <robin.murphy@....com>,
Will Deacon <will@...nel.org>,
Rob Clark <robdclark@...omium.org>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
"Rafael J. Wysocki" <rafael.j.wysocki@...el.com>,
Andrew Morton <akpm@...ux-foundation.org>,
Suzuki K Poulose <suzuki.poulose@....com>,
Rasmus Villemoes <linux@...musvillemoes.dk>,
Heikki Krogerus <heikki.krogerus@...ux.intel.com>,
Bartosz Golaszewski <brgl@...ev.pl>,
Sudeep Holla <sudeep.holla@....com>,
Joe Perches <joe@...ches.com>, Arnd Bergmann <arnd@...db.de>,
open list <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH v2 1/2] iommu: add support for drivers that manage iommu
explicitly
On Fri, Sep 06, 2019 at 02:44:01PM -0700, Rob Clark wrote:
> @@ -674,7 +674,7 @@ int iommu_group_add_device(struct iommu_group *group, struct device *dev)
>
> mutex_lock(&group->mutex);
> list_add_tail(&device->list, &group->devices);
> - if (group->domain)
> + if (group->domain && !(dev->driver && dev->driver->driver_manages_iommu))
Hmm, this code usually runs at enumeration time when no driver is
attached to the device. Actually it would be pretty dangerous when this
code runs while a driver is attached to the device. How does that change
make things work for you?
Regards,
Joerg
Powered by blists - more mailing lists