[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v4 03/12] target/arm: Fix mte_checkN
From: |
Peter Maydell |
Subject: |
Re: [PATCH v4 03/12] target/arm: Fix mte_checkN |
Date: |
Thu, 8 Apr 2021 08:50:36 +0000 |
On Wed, 7 Apr 2021 at 19:54, Alex Bennée <alex.bennee@linaro.org> wrote:
>
>
> Richard Henderson <richard.henderson@linaro.org> writes:
>
> > We were incorrectly assuming that only the first byte of an MTE access
> > is checked against the tags. But per the ARM, unaligned accesses are
> > pre-decomposed into single-byte accesses. So by the time we reach the
> > actual MTE check in the ARM pseudocode, all accesses are aligned.
> >
> > Therefore, the first failure is always either the first byte of the
> > access, or the first byte of the granule.
> >
> > In addition, some of the arithmetic is off for last-first -> count.
> > This does not become directly visible until a later patch that passes
> > single bytes into this function, so ptr == ptr_last.
> >
> > Buglink: https://bugs.launchpad.net/bugs/1921948
>
> Minor note: you can Cc: Bug 1921948 <1921948@bugs.launchpad.net> to
> automatically copy patches to the appropriate bugs which is useful if
> you don't have the Cc for the reporter.
I'm not sure cc'ing bugs on patches is very useful, though (and especially
not for big series). I usually prefer to just add a note to the bug with
the URL of the series in patchew afterwards.
-- PMM
- [PATCH v4 01/12] accel/tcg: Preserve PAGE_ANON when changing page permissions, (continued)
[PATCH v4 05/12] target/arm: Fix unaligned checks for mte_check1, mte_probe1, Richard Henderson, 2021/04/06
[PATCH v4 07/12] target/arm: Replace MTEDESC ESIZE+TSIZE with SIZEM1, Richard Henderson, 2021/04/06
[PATCH v4 06/12] test/tcg/aarch64: Add mte-5, Richard Henderson, 2021/04/06
[PATCH v4 08/12] target/arm: Merge mte_check1, mte_checkN, Richard Henderson, 2021/04/06
[PATCH v4 09/12] target/arm: Rename mte_probe1 to mte_probe, Richard Henderson, 2021/04/06