Thread (50 messages) flat view 50 messages, 6 authors, 2023-12-26

Re: [PATCH 00/16] IOMMU memory observability

From: Jason Gunthorpe <jgg@ziepe.ca>
Date: 2023-11-29 00:54:52
Also in: asahi, cgroups, kvm, linux-doc, linux-fsdevel, linux-iommu, linux-mm, linux-rockchip, linux-samsung-soc, linux-sunxi, linux-tegra, lkml, virtualization

On Tue, Nov 28, 2023 at 04:30:27PM -0800, Yosry Ahmed wrote:
On Tue, Nov 28, 2023 at 4:28 PM Jason Gunthorpe [off-list ref] wrote:
quoted
On Tue, Nov 28, 2023 at 04:25:03PM -0800, Yosry Ahmed wrote:
quoted
quoted
quoted
Right, but as I mention above, if userspace starts depending on this
equation, we won't be able to add any more classes of "secondary" page
tables to SecPageTables. I'd like to avoid that if possible. We can do
the subtraction in the kernel.
What Sean had suggested was that SecPageTables was always intended to
account all the non-primary mmu memory used by page tables. If this is
the case we shouldn't be trying to break it apart into finer
counters. These are big picture counters, not detailed allocation by
owner counters.
Right, I agree with that, but if SecPageTables includes page tables
from multiple sources, and it is observed to be suspiciously high, the
logical next step is to try to find the culprit, right?
You can make that case already, if it is high wouldn't you want to
find the exact VMM process that was making it high?

It is a sign of fire, not a detailed debug tool.
Fair enough. We can always add separate counters later if needed,
potentially under KVM stats to get more fine-grained details as you
mentioned.

I am only worried about users subtracting the iommu-only counter to
get a KVM counter. We should at least document that  SecPageTables may
be expanded to include other sources later to avoid that.
Well, we just broke it already, anyone thinking it was only kvm
counters is going to be sad now :) As I understand it was already
described to be more general that kvm so probably nothing to do really

Jason
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help