Skip to content

System Cache support for GPU and required SMMU support

Sai Prakash Ranjan dri-devel linux-arm-kernel linux-arm-msm linux-iommu lkml 10 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v10 Latest9 patches 2 repliesIn review
  2. v98 patches 4 repliesSuperseded
  3. v88 patches 14 repliesSuperseded
Earlier versions · 7
VersionPostedPatchesRepliesStatus
v77 patches10 repliesSuperseded
v66 patches2 repliesSuperseded
v56 patches6 repliesSuperseded
v4 posting 3/30 of 6 patches0 repliesSuperseded
v4 posting 2/30 of 6 patches0 repliesSuperseded
v4 posting 1/30 of 6 patches0 repliesSuperseded
v37 patches6 repliesSuperseded

Changes in v10 from the cover letter

* Fix non-strict mode domain attr handling (Will)
* Split the domain attribute patch into two (Will)

Patches in v10 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/9iommu/io-pgtable: Add a domain attribute for pagetable configurationinclude/linux/io-pgtable.h include/linux/iommu.h+5 -00 replies
2/9iommu/io-pgtable-arm: Add support to use system cachedrivers/iommu/io-pgtable-arm.c include/linux/io-pgtable.h+12 -20 replies
3/9iommu/arm-smmu: Add support for pagetable config domain attributedrivers/iommu/arm/arm-smmu/arm-smmu.c drivers/iommu/arm/arm-smmu/arm-smmu.h+21 -00 replies
4/9iommu/arm-smmu: Move non-strict mode to use io_pgtable_domain_attrdrivers/iommu/arm/arm-smmu/arm-smmu.c drivers/iommu/arm/arm-smmu/arm-smmu.h+9 -70 replies
5/9drm/msm: rearrange the gpu_rmw() functiondrivers/gpu/drm/msm/msm_drv.c drivers/gpu/drm/msm/msm_drv.h drivers/gpu/drm/msm/msm_gpu.h+10 -40 replies
6/9drm/msm/a6xx: Add support for using system cache(LLC)drivers/gpu/drm/msm/adreno/a6xx_gpu.c drivers/gpu/drm/msm/adreno/a6xx_gpu.h drivers/gpu/drm/msm/adreno/adreno_gpu.c+104 -00 replies
7/9drm/msm/a6xx: Add support for using system cache on MMU500 based targetsdrivers/gpu/drm/msm/adreno/a6xx_gpu.c drivers/gpu/drm/msm/adreno/a6xx_gpu.h+37 -100 replies
8/9iommu: arm-smmu-impl: Use table to list QCOM implementationsdrivers/iommu/arm/arm-smmu/arm-smmu-impl.c drivers/iommu/arm/arm-smmu/arm-smmu-qcom.c drivers/iommu/arm/arm-smmu/arm-smmu.h+17 -140 replies
9/9iommu: arm-smmu-impl: Add a space before open parenthesisdrivers/iommu/arm/arm-smmu/arm-smmu-impl.c+1 -10 replies

Reviews trailers per patch

3 of 9 patches have a Reviewed-by or Acked-by.

PatchJordan CrouseWill Deacon
1/9
2/9
3/9
4/9
5/9R-b
6/9
7/9
8/9A-b
9/9A-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v10 thread

Cover letter [PATCHv10 0/9] System Cache support for GPU and required SMMU support

Some hardware variants contain a system cache or the last level cache(llc). This cache is typically a large block which is shared by multiple clients on the SOC. GPU uses the system cache to cache both the GPU data buffers(like textures) as well the SMMU pagetables. This helps with improved render performance as well as lower power consumption by reducing the bus traffic to the system memory.

The system cache architecture allows the cache to be split into slices which then be used by multiple SOC clients. This patch series is an effort to enable and use two of those slices preallocated for the GPU, one for the GPU data buffers and another for the GPU SMMU hardware pagetables.

Patch 1 - Patch 7 adds system cache support in SMMU and GPU driver. Patch 8 and 9 are minor cleanups for arm-smmu impl.

Changes in v10:
* Fix non-strict mode domain attr handling (Will)
* Split the domain attribute patch into two (Will)

Changes in v9:
* Change name from domain_attr_io_pgtbl_cfg to io_pgtable_domain_attr (Will)
* Modify comment for the quirk as suggested (Will)
* Compare with IO_PGTABLE_QUIRK_NON_STRICT for non-strict mode (Will)

Changes in v8:
* Introduce a generic domain attribute for pagetable config (Will)
* Rename quirk to more generic IO_PGTABLE_QUIRK_ARM_OUTER_WBWA (Will)
* Move non-strict mode to use new struct domain_attr_io_pgtbl_config (Will)

Changes in v7:
* Squash Jordan's patch to support MMU500 targets
* Rebase on top of for-joerg/arm-smmu/updates and Jordan's short series for adreno-smmu impl

Changes in v6:
* Move table to arm-smmu-qcom (Robin)

Changes in v5:
* Drop cleanup of blank lines since it was intentional (Robin)
* Rebase again on top of msm-next-pgtables as it moves pretty fast

Changes in v4:
* Drop IOMMU_SYS_CACHE prot flag
* Rebase on top of https://gitlab.freedesktop.org/drm/msm/-/tree/msm-next-pgtables

Changes in v3:
* Fix domain attribute setting to before iommu_attach_device()
* Fix few code style and checkpatch warnings
* Rebase on top of Jordan's latest split pagetables and per-instance pagetables support

Changes in v2:
* Addressed review comments and rebased on top of Jordan's split pagetables series

Jordan Crouse (1):
drm/msm/a6xx: Add support for using system cache on MMU500 based
targets

Sai Prakash Ranjan (6):
iommu/io-pgtable: Add a domain attribute for pagetable configuration iommu/io-pgtable-arm: Add support to use system cache iommu/arm-smmu: Add support for pagetable config domain attribute iommu/arm-smmu: Move non-strict mode to use io_pgtable_domain_attr
iommu: arm-smmu-impl: Use table to list QCOM implementations
iommu: arm-smmu-impl: Add a space before open parenthesis

Sharat Masetty (2):
drm/msm: rearrange the gpu_rmw() function drm/msm/a6xx: Add support for using system cache(LLC)

 drivers/gpu/drm/msm/adreno/a6xx_gpu.c      | 109 +++++++++++++++++++++
 drivers/gpu/drm/msm/adreno/a6xx_gpu.h      |   5 +
 drivers/gpu/drm/msm/adreno/adreno_gpu.c    |  17 ++++
 drivers/gpu/drm/msm/msm_drv.c              |   8 ++
 drivers/gpu/drm/msm/msm_drv.h              |   1 +
 drivers/gpu/drm/msm/msm_gpu.h              |   5 +-
 drivers/iommu/arm/arm-smmu/arm-smmu-impl.c |  11 +--
 drivers/iommu/arm/arm-smmu/arm-smmu-qcom.c |  21 +++-
 drivers/iommu/arm/arm-smmu/arm-smmu.c      |  33 ++++++-
 drivers/iommu/arm/arm-smmu/arm-smmu.h      |   3 +-
 drivers/iommu/io-pgtable-arm.c             |  10 +-
 include/linux/io-pgtable.h                 |   8 ++
 include/linux/iommu.h                      |   1 +
 13 files changed, 205 insertions(+), 27 deletions(-)

base-commit: a29bbb0861f487a5e144dc997a9f71a36c7a2404

Signature · 2 lines
QUALCOMM INDIA, on behalf of Qualcomm Innovation Center, Inc. is a member
of Code Aurora Forum, hosted by The Linux Foundation