lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <Z/QSuMzJVGOcTx60@nvidia.com>
Date: Mon, 7 Apr 2025 11:00:24 -0700
From: Nicolin Chen <nicolinc@...dia.com>
To: Zhangfei Gao <zhangfei.gao@...aro.org>
CC: <jgg@...dia.com>, <kevin.tian@...el.com>, <corbet@....net>,
	<will@...nel.org>, <joro@...tes.org>, <suravee.suthikulpanit@....com>,
	<robin.murphy@....com>, <dwmw2@...radead.org>, <baolu.lu@...ux.intel.com>,
	<linux-kernel@...r.kernel.org>, <iommu@...ts.linux.dev>,
	<linux-arm-kernel@...ts.infradead.org>, <linux-kselftest@...r.kernel.org>,
	<linux-doc@...r.kernel.org>, <eric.auger@...hat.com>,
	<jean-philippe@...aro.org>, <mdf@...nel.org>, <mshavit@...gle.com>,
	<shameerali.kolothum.thodi@...wei.com>, <smostafa@...gle.com>,
	<ddutile@...hat.com>, <yi.l.liu@...el.com>, <praan@...gle.com>,
	<patches@...ts.linux.dev>
Subject: Re: [PATCH v8 12/14] iommu/arm-smmu-v3: Introduce struct
 arm_smmu_vmaster

On Mon, Apr 07, 2025 at 08:08:57PM +0800, Zhangfei Gao wrote:
> Hi, Nico
> 
> On Wed, 26 Feb 2025 at 01:35, Nicolin Chen <nicolinc@...dia.com> wrote:
> >
> > Use it to store all vSMMU-related data. The vsid (Virtual Stream ID) will
> > be the first use case. Since the vsid reader will be the eventq handler
> > that already holds a streams_mutex, reuse that to fenche the vmaster too.
> >
> > Also add a pair of arm_smmu_attach_prepare/commit_vmaster helpers to set
> > or unset the master->vmaster point. Put these helpers inside the existing
> > arm_smmu_attach_prepare/commit().
> >
> > For identity/blocked ops that don't call arm_smmu_attach_prepare/commit(),
> > add a simpler arm_smmu_master_clear_vmaster helper to unset the vmaster.
> >
> > Reviewed-by: Jason Gunthorpe <jgg@...dia.com>
> > Reviewed-by: Pranjal Shrivastavat <praan@...gle.com>
> > Signed-off-by: Nicolin Chen <nicolinc@...dia.com>
> > ---
> 
> >
> > +int arm_smmu_attach_prepare_vmaster(struct arm_smmu_attach_state *state,
> > +                                   struct arm_smmu_nested_domain *nested_domain)
> > +{
> > +       struct arm_smmu_vmaster *vmaster;
> > +       unsigned long vsid;
> > +       int ret;
> > +
> > +       iommu_group_mutex_assert(state->master->dev);
> > +
> > +       /* Skip invalid vSTE */
> > +       if (!(nested_domain->ste[0] & cpu_to_le64(STRTAB_STE_0_V)))
> > +               return 0;
> 
> Why this is removed in v9 and 6.15-rc1?
> 
> I tested 6.15-rc1 the qemu failed to boot with qemu branch:
> for_iommufd_veventq-v8
> "failed to attach the bypass pagetable"

Here is the problem: v9 isn't compatible with v8 :)

Would you please try for-v9 version?
https://github.com/nicolinc/qemu/commits/wip/for_iommufd_veventq-v9

I also asked Shameer to integrate this change to his QEMU series:
https://lore.kernel.org/qemu-devel/8fbdb07be20a43bf8281143720a0c10e@huawei.com/

Thanks
Nicolin

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ