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] [thread-next>] [day] [month] [year] [list]
Message-ID: <20260115162919.GG961588@nvidia.com>
Date: Thu, 15 Jan 2026 12:29:19 -0400
From: Jason Gunthorpe <jgg@...dia.com>
To: Nicolin Chen <nicolinc@...dia.com>
Cc: Will Deacon <will@...nel.org>, robin.murphy@....com, joro@...tes.org,
	linux-arm-kernel@...ts.infradead.org, iommu@...ts.linux.dev,
	linux-kernel@...r.kernel.org, skolothumtho@...dia.com,
	praan@...gle.com, xueshuai@...ux.alibaba.com, smostafa@...gle.com
Subject: Re: [PATCH rc v5 1/4] iommu/arm-smmu-v3: Add update_safe bits to fix
 STE update sequence

On Thu, Jan 15, 2026 at 08:25:05AM -0800, Nicolin Chen wrote:
> On Thu, Jan 15, 2026 at 09:11:51AM -0400, Jason Gunthorpe wrote:
> > On Tue, Jan 13, 2026 at 04:51:12PM -0400, Jason Gunthorpe wrote:
> > > > -       safe_bits[1] |= cpu_to_le64(STRTAB_STE_1_EATS);
> > > > +       if (!((cur[2] | target[2]) & cpu_to_le64(STRTAB_STE_2_S2S)))
> > > > +               safe_bits[1] |= cpu_to_le64(
> > > > +                       FIELD_PREP(STRTAB_STE_1_EATS, STRTAB_STE_1_EATS_TRANS));
> > > > --------------------------------------------------------------------------
> > > > 
> > > > @will, does this look good to you? I can send a v7 with this.
> > > 
> > > That is an easy way to address Will's observation, makes sense to me.
> > 
> > Ah, but it looks like it can generate an errant view of a EATS that is
> > neither old or new. Ie value 3, reserved.
> > 
> > I think you should just check if old or new has EATS bit 1 set:
> > 
> > if (!((cur[2] | target[2]) & cpu_to_le64(STRTAB_STE_2_S2S)) &&
> >     !((cur[1] | target[1]) & cpu_to_le64(FIELD_PREP(STRTAB_STE_1_EATS, 2))))
> > 
> > Which the current driver never does..
> 
> The EATS field is completely controlled by the driver. So, we are
> safe for now, right?
> 
> Should we add this when the driver has the actual support for the
> split stage thing?

If we have figured it out now I would add it because it would be a big
leap to think the next person will remember about this detail..

But yes, this and the S2S thing don't effect the driver as it is now,
it is just doing work to help future people.

Jason

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ