> -----Original Message----- > From: [email protected] [mailto:iommu- > [email protected]] On Behalf Of Will Deacon > Sent: Wednesday, March 12, 2014 9:53 PM > To: Sethi Varun-B16395 > Cc: [email protected] > Subject: Re: [RFC][PATCH] iommu/arm: Add hotplugged devices support for > arm-smmu. > > Hi Varun, > > On Sat, Mar 08, 2014 at 07:05:40PM +0000, Varun Sethi wrote: > > Currently the ARM SMMU driver only considers the bus master devices in > > the device tree. The master device and stream ID information is > > maintained per SMMU. Currently there is no mechanism for representing > > this information in case of PCI or hot plugged devices. > > > > This RFC patch proposes a mechanism for representing this information > > for hot plugged/PCI devices. > > > > Patch doesn't contain the add_device callback modification for hot plug > devices. > > This would be bus specific and would be responsible for populating the > > hot plug devices masters list for the SMMU. > > > > Signed-off-by: Varun Sethi <[email protected]> > > --- > > drivers/iommu/arm-smmu.c | 93 > ++++++++++++++++++++++++++++++++++++++++++++-- > > 1 file changed, 90 insertions(+), 3 deletions(-) > > > > diff --git a/drivers/iommu/arm-smmu.c b/drivers/iommu/arm-smmu.c index > > 1d9ab39..6c10df4 100644 > > --- a/drivers/iommu/arm-smmu.c > > +++ b/drivers/iommu/arm-smmu.c > > @@ -327,6 +327,9 @@ struct arm_smmu_master { > > * SMMU chain. > > */ > > struct rb_node node; > > + /* Following fields correspond to the hot plug masters */ > > + struct list_head hotplug_masters_node; > > + struct device *dev; > > I'd much rather have one list for all masters. Distinguishing between > masters and `hotplug masters' is unnecessary. > > > +static int is_device_hotplug(struct device *dev) { > > + return (dev->bus != &platform_bus_type) && > > + (dev->bus != &amba_bustype); > > +} > > I'm not fond of this. Why not rework what we currently have so that it > can work for other (hotpluggable) buses? > Ok, I will modify the code to use a list of masters per smmu.
-Varun _______________________________________________ iommu mailing list [email protected] https://lists.linuxfoundation.org/mailman/listinfo/iommu
