All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v2 0/2] arm64: DC {ZVA,GVA,GZVA} shouldn't be used when DCZID_EL0.DZP == 1
@ 2021-11-08  7:11 Reiji Watanabe
  2021-11-08  7:11 ` [PATCH v2 1/2] arm64: clear_page() shouldn't use DC ZVA " Reiji Watanabe
  2021-11-08  7:11 ` [PATCH v2 2/2] arm64: mte: DC {GVA,GZVA} shouldn't be used " Reiji Watanabe
  0 siblings, 2 replies; 9+ messages in thread
From: Reiji Watanabe @ 2021-11-08  7:11 UTC (permalink / raw)
  To: Catalin Marinas, Will Deacon
  Cc: Marc Zyngier, Robin Murphy, Mark Rutland, Peter Collingbourne,
	Evgenii Stepanov, linux-arm-kernel, Peter Shier, Ricardo Koller,
	Oliver Upton, Jing Zhang, Raghavendra Rao Anata, Reiji Watanabe

DCZID_EL0.DZP indicates whether or not use of DC {ZVA,GVA,GZVA} is
prohibited. However, clear_page(), mte_set_mem_tag_range(), and
mte_zero_clear_page_tags() use those instructions without checking it.

Fix those functions not to use DC {ZVA,GVA,GZVA} when DCZID_EL0.DZP == 1.

v2:
 - Fix mte_set_mem_tag_range() and mte_zero_clear_page_tags() not to use
   DC {GVA,GZVA} when DCZID_EL0.DZP == 1. [Mark]
 - Fix a typo of the comment in clear_page() [Mark]
 - Fix a loop of for stp in clear_page() for more consistency with
   the existing loop  [Mark]

v1: https://lore.kernel.org/all/20211026034844.1393437-1-reijiw@google.com/

Reiji Watanabe (2):
  arm64: clear_page() shouldn't use DC ZVA when DCZID_EL0.DZP == 1
  arm64: mte: DC {GVA,GZVA} shouldn't be used when DCZID_EL0.DZP == 1

 arch/arm64/include/asm/mte-kasan.h |  8 +++++---
 arch/arm64/lib/clear_page.S        | 10 ++++++++++
 arch/arm64/lib/mte.S               |  8 +++++++-
 3 files changed, 22 insertions(+), 4 deletions(-)

-- 
2.34.0.rc0.344.g81b53c2807-goog


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2021-12-04  8:05 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-11-08  7:11 [PATCH v2 0/2] arm64: DC {ZVA,GVA,GZVA} shouldn't be used when DCZID_EL0.DZP == 1 Reiji Watanabe
2021-11-08  7:11 ` [PATCH v2 1/2] arm64: clear_page() shouldn't use DC ZVA " Reiji Watanabe
2021-11-16 23:00   ` Robin Murphy
2021-11-18  8:18     ` Reiji Watanabe
2021-11-18 11:42       ` Robin Murphy
2021-11-08  7:11 ` [PATCH v2 2/2] arm64: mte: DC {GVA,GZVA} shouldn't be used " Reiji Watanabe
2021-12-03 18:29   ` Catalin Marinas
2021-12-03 18:51     ` Catalin Marinas
2021-12-04  8:03       ` Reiji Watanabe

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.