[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ZcJTkQFcVhcGC52Z@smile.fi.intel.com>
Date: Tue, 6 Feb 2024 17:43:13 +0200
From: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
To: Howard Yen <howardyen@...gle.com>
Cc: hch@....de, m.szyprowski@...sung.com, robin.murphy@....com,
gregkh@...uxfoundation.org, rafael@...nel.org, broonie@...nel.org,
james@...iv.tech, james.clark@....com, masahiroy@...nel.org,
linux-kernel@...r.kernel.org, iommu@...ts.linux.dev
Subject: Re: [PATCH v2] dma-coherent: add support for multi coherent rmems
per dev
On Mon, Feb 05, 2024 at 02:08:00PM +0200, Andy Shevchenko wrote:
> On Mon, Feb 05, 2024 at 07:23:00AM +0000, Howard Yen wrote:
..
> > @@ -18,15 +18,9 @@ struct dma_coherent_mem {
> > unsigned long *bitmap;
> > spinlock_t spinlock;
> > bool use_dev_dma_pfn_offset;
> > + struct list_head node;
>
> Have you run `pahole`? Here I see wasted bytes for nothing.
On top of that one may make container_of() to be no-op, by placing this member
to be the first one. But, double check this with bloat-o-meter (that it indeed
does better code generation) and on the other hand check if the current first
member is not performance critical and having additional pointer arithmetics is
okay.
> > };
--
With Best Regards,
Andy Shevchenko
Powered by blists - more mailing lists