From: Jason Gunthorpe <jgg@nvidia.com>
To: Robin Murphy <robin.murphy@arm.com>
Cc: joro@8bytes.org, will@kernel.org, iommu@lists.linux.dev,
linux-arm-kernel@lists.infradead.org, m.szyprowski@samsung.com,
heiko@sntech.de, jernej.skrabec@gmail.com,
thierry.reding@gmail.com, vdumpa@nvidia.com
Subject: Re: [PATCH 8/8] iommu: Improve map/unmap sanity checks
Date: Fri, 22 Sep 2023 14:28:31 -0300 [thread overview]
Message-ID: <20230922172831.GA145934@nvidia.com> (raw)
In-Reply-To: <fef0b304-5a19-b2a3-c399-7f21c05623bf@arm.com>
On Tue, Sep 19, 2023 at 01:18:31PM +0100, Robin Murphy wrote:
> > This is not a theoretical question - does any in-kernel code actually
> > do that and expect it to work? I didn't notice any..
>
> I was hoping to have to say I'd only seen it in unmerged (e.g. [1]) and
> downstream code, but then I found drivers/net/ipa/ :(
Aiiie, what is that doing? Mapping something into the dma-api owned
domain!?!
See this is why I think stronger invarients are a good idea, we can't
police the entire kernel but we can make the entry points explode if
someone is doing something WRONG.
> All that said, I don't mind if you want to propose a separate patch to turn
> certain external caller conditions into noisy warnings, but I wouldn't want
> to tie it up with any other changes which would risk getting caught in the
> crossfire if someone does then hit a newly-introduced warning and start
> arguing to revert it. And I'm not going to do so in any of my patches since
> as above I don't personally believe it's a valuable thing to do.
Ok, that make sense
Jason
next prev parent reply other threads:[~2023-09-22 17:28 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-09-12 16:18 [PATCH 0/8] iommu: Clean up map/unmap ops Robin Murphy
2023-09-12 16:18 ` [PATCH 1/8] iommu/exynos: Update to {map,unmap}_pages Robin Murphy
2023-09-12 16:18 ` [PATCH 2/8] iommu/omap: " Robin Murphy
2023-09-12 16:18 ` [PATCH 3/8] iommu/rockchip: " Robin Murphy
2023-09-12 16:18 ` [PATCH 4/8] iommu/sun50i: " Robin Murphy
2023-09-12 16:18 ` [PATCH 5/8] iommu/tegra-gart: " Robin Murphy
2023-09-12 16:18 ` [PATCH 6/8] iommu/tegra-smmu: " Robin Murphy
2023-09-12 16:18 ` [PATCH 7/8] iommu: Retire map/unmap ops Robin Murphy
2023-09-13 14:40 ` Jason Gunthorpe
2023-09-12 16:18 ` [PATCH 8/8] iommu: Improve map/unmap sanity checks Robin Murphy
2023-09-13 14:39 ` Jason Gunthorpe
2023-09-13 18:46 ` Robin Murphy
2023-09-14 12:48 ` Jason Gunthorpe
2023-09-14 14:23 ` Robin Murphy
2023-09-14 16:48 ` Jason Gunthorpe
2023-09-19 12:18 ` Robin Murphy
2023-09-22 17:28 ` Jason Gunthorpe [this message]
2023-09-25 10:05 ` [PATCH 0/8] iommu: Clean up map/unmap ops Joerg Roedel
2023-09-25 15:33 ` Jernej Škrabec
2023-09-26 9:23 ` Joerg Roedel
2023-09-26 12:01 ` Robin Murphy
2023-09-26 14:57 ` Joerg Roedel
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20230922172831.GA145934@nvidia.com \
--to=jgg@nvidia.com \
--cc=heiko@sntech.de \
--cc=iommu@lists.linux.dev \
--cc=jernej.skrabec@gmail.com \
--cc=joro@8bytes.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=m.szyprowski@samsung.com \
--cc=robin.murphy@arm.com \
--cc=thierry.reding@gmail.com \
--cc=vdumpa@nvidia.com \
--cc=will@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox