Hi Robin, > -----Original Message----- > From: Robin Murphy <robin.mur...@arm.com> > Sent: Friday, February 28, 2020 8:32 PM > > [ +Laurentiu ] > > Hi Russell, > > Thanks for sharing a log, now I properly understand what's up... further > comments at the end (for context). > > On 28/02/2020 10:06 am, Russell King - ARM Linux admin wrote: > > On Fri, Feb 28, 2020 at 09:33:40AM +0000, John Garry wrote: > >> On 28/02/2020 02:16, Lu Baolu wrote: > >>> Hi, > >>> > >>> On 2020/2/27 19:57, Russell King wrote: > >>>> On the LX2160A, there are lots (about 160) of IOMMU messages produced > >>>> during boot; this is excessive. Reduce the severity of these > messages > >>>> to debug level. > >>>> > >>>> Signed-off-by: Russell King <rmk+ker...@armlinux.org.uk> > >>>> --- > >>>> drivers/iommu/iommu.c | 4 ++-- > >>>> 1 file changed, 2 insertions(+), 2 deletions(-) > >>>> > >>>> diff --git a/drivers/iommu/iommu.c b/drivers/iommu/iommu.c > >>>> index 3ead597e1c57..304281ec623b 100644 > >>>> --- a/drivers/iommu/iommu.c > >>>> +++ b/drivers/iommu/iommu.c > >>>> @@ -741,7 +741,7 @@ int iommu_group_add_device(struct iommu_group > >>>> *group, struct device *dev) > >>>> trace_add_device_to_group(group->id, dev); > >>>> - dev_info(dev, "Adding to iommu group %d\n", group->id); > >>>> + dev_dbg(dev, "Adding to iommu group %d\n", group->id); > >>> > >>> I'm not strongly against this. But to me this message seems to be a > good > >>> indicator that a device was probed successfully by the iommu subsystem. > >>> Keeping it in the default kernel message always helps to the kernel > >>> debugging. > >>> > >> > >> I would tend to agree. > >
[snip] > > > > # dmesg |grep 'Adding to iommu' | wc -l > > 164 > > # dmesg |grep -v 'Adding to iommu' | wc -l > > 551 > > > > So, 23% of the kernel messages on this platform are "Adding to iommu", > > which is excessive. > > Indeed, however I would note that on most platforms bringing up a > network interface involves hot-adding 0 devices, so hot-adding 19 > devices as full-blown DMA masters is arguably the root of "excessive" > already. Per the concern I initially raised, each of those messages > represents a whole bunch of internal allocation and bookkeeping going > on, which if it isn't necessary would be far better avoided altogether, > than simply done more quietly. > > Laurentiu, I guess at the moment the nature of the of_dma_configure() > integration means we end up treating all DPAA2 objects identically, but > do you think we have scope to be a bit cleverer in that regard? > Presumably not every type of object that shows up on the fsl_mc bus is > really an independent DMA master, so if we could skip doing the full > DMA/IOMMU/MSI setup for the ones that don't need it, it would work out > nicer all round. In fact your .dma_configure proposal (which I'll try to > take a proper look at next week) couldn't have come at a better time for > that argument :) Thanks! That's a very good point - I'll check on which devices we actually use dma apis and filter the rest out. Will keep in mind for the next spin of the patches. --- Best Regards, Laurentiu _______________________________________________ iommu mailing list iommu@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/iommu