[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CA+CK2bA05Bh+H4qsP7ZM6ZcnBXu64frEfpCDYZuLOQ4UxJC4EA@mail.gmail.com>
Date: Wed, 29 Nov 2023 15:44:21 -0500
From: Pasha Tatashin <pasha.tatashin@...een.com>
To: Jason Gunthorpe <jgg@...pe.ca>
Cc: Robin Murphy <robin.murphy@....com>, akpm@...ux-foundation.org,
alex.williamson@...hat.com, alim.akhtar@...sung.com, alyssa@...enzweig.io,
asahi@...ts.linux.dev, baolu.lu@...ux.intel.com, bhelgaas@...gle.com,
cgroups@...r.kernel.org, corbet@....net, david@...hat.com,
dwmw2@...radead.org, hannes@...xchg.org, heiko@...ech.de,
iommu@...ts.linux.dev, jasowang@...hat.com, jernej.skrabec@...il.com,
jonathanh@...dia.com, joro@...tes.org, kevin.tian@...el.com,
krzysztof.kozlowski@...aro.org, kvm@...r.kernel.org,
linux-arm-kernel@...ts.infradead.org, linux-doc@...r.kernel.org,
linux-fsdevel@...r.kernel.org, linux-kernel@...r.kernel.org,
linux-mm@...ck.org, linux-rockchip@...ts.infradead.org,
linux-samsung-soc@...r.kernel.org, linux-sunxi@...ts.linux.dev,
linux-tegra@...r.kernel.org, lizefan.x@...edance.com, marcan@...can.st,
mhiramat@...nel.org, mst@...hat.com, m.szyprowski@...sung.com,
netdev@...r.kernel.org, paulmck@...nel.org, rdunlap@...radead.org,
samuel@...lland.org, suravee.suthikulpanit@....com, sven@...npeter.dev,
thierry.reding@...il.com, tj@...nel.org, tomas.mudrunka@...il.com,
vdumpa@...dia.com, virtualization@...ts.linux.dev, wens@...e.org,
will@...nel.org, yu-cheng.yu@...el.com
Subject: Re: [PATCH 08/16] iommu/fsl: use page allocation function provided by iommu-pages.h
On Wed, Nov 29, 2023 at 3:03 PM Jason Gunthorpe <jgg@...pe.ca> wrote:
>
> On Wed, Nov 29, 2023 at 02:45:03PM -0500, Pasha Tatashin wrote:
>
> > > same kind of big systems where IOMMU pagetables would be of any concern.
> > > I believe some of the some of the "serious" NICs can easily run up
> > > hundreds of megabytes if not gigabytes worth of queues, SKB pools, etc.
> > > - would you propose accounting those too?
> >
> > Yes. Any kind of kernel memory that is proportional to the workload
> > should be accountable. Someone is using those resources compared to
> > the idling system, and that someone should be charged.
>
> There is a difference between charged and accounted
>
> You should be running around adding GFP_KERNEL_ACCOUNT, yes. I already
> did a bunch of that work. Split that out from this series and send it
> to the right maintainers.
I will do that.
>
> Adding a counter for allocations and showing in procfs is a very
> different question. IMHO that should not be done in micro, the
> threshold to add a new counter should be high.
I agree, /proc/meminfo, should not include everything, however overall
network consumption that includes memory allocated by network driver
would be useful to have, may be it should be exported by device
drivers and added to the protocol memory. We already have network
protocol memory consumption in procfs:
# awk '{printf "%-10s %s\n", $1, $4}' /proc/net/protocols | grep -v '\-1'
protocol memory
UDPv6 22673
TCPv6 16961
> There is definately room for a generic debugging feature to break down
> GFP_KERNEL_ACCOUNT by owernship somehow. Maybe it can already be done
> with BPF. IDK
Powered by blists - more mailing lists