[PATCH 0/9] WIP: Retry page fault handling for Vega10

Kuehling, Felix Felix.Kuehling at amd.com
Mon Aug 28 13:36:30 UTC 2017


Hi Oded,

Thanks for the heads up. Enjoy your vacation. I'll rebase this on Alex's drm-next for your review.

Regards,
  Felix
________________________________________
From: Oded Gabbay <oded.gabbay at gmail.com>
Sent: Sunday, August 27, 2017 6:22:37 PM
To: Kuehling, Felix
Cc: amd-gfx list
Subject: Re: [PATCH 0/9] WIP: Retry page fault handling for Vega10

Hi Felix,
I'm currently on vacation and I will return at the end of the week, so I will not be able to review the patches until then.

Oded

On Aug 26, 2017 09:19, "Felix Kuehling" <Felix.Kuehling at amd.com<mailto:Felix.Kuehling at amd.com>> wrote:
This is based on amd-kfd-staging, because that's easier for me to test.
I'm planning to port to amd-staging-4.x for submission upstream.

With this patch series, I'm able to turn retry faults on and handle the
interrupt storm from VM faults. Only the first VM fault interrupt per
process and address gets handled the usual way. Retry interruptr are
filtered in a new prescreening stage in amdgpu_ih_process.

Pending faults are tracked in a hash table in IH to detect retry faults
and a FIFO in the VM for later processing.

Looking up the VM from the fault interrupt depends on the PASID.
Currently only KFD VMs have proper PASIDs.

TODO (need some help with these):
* Allocate PASIDs for graphics contexts
* Setup VMID-PASID mapping during graphics command submission
* Confirm that graphics page faults have the correct PASID in the IV

Once that's done, we should have a foundation to start working on HMM
and proper SVM memory management with demand paging.

Felix Kuehling (9):
  drm/amdgpu: Fix error handling in amdgpu_vm_init
  drm/amdgpu: Add PASID management
  drm/radeon: Add PASID manager for KFD
  drm/amdkfd: Separate doorbell allocation from PASID
  drm/amdkfd: Use PASID manager from KGD
  drm/amd: Set the PASID for KFD VMs
  drm/amdgpu: Add prescreening stage in IH processing
  lib: Closed hash table with low overhead
  drm/amdgpu: Track pending retry faults in IH and VM

 drivers/gpu/drm/Kconfig                           |   1 +
 drivers/gpu/drm/amd/amdgpu/amdgpu.h               |   2 +
 drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd.h        |   3 +-
 drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v7.c |   2 +
 drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v8.c |   2 +
 drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v9.c |   2 +
 drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gpuvm.c  |   6 +-
 drivers/gpu/drm/amd/amdgpu/amdgpu_ih.c            |  82 ++++
 drivers/gpu/drm/amd/amdgpu/amdgpu_ih.h            |  12 +
 drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c           |   2 +-
 drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c            |  88 +++-
 drivers/gpu/drm/amd/amdgpu/amdgpu_vm.h            |  21 +-
 drivers/gpu/drm/amd/amdgpu/cik_ih.c               |  14 +
 drivers/gpu/drm/amd/amdgpu/cz_ih.c                |  14 +
 drivers/gpu/drm/amd/amdgpu/iceland_ih.c           |  14 +
 drivers/gpu/drm/amd/amdgpu/si_ih.c                |  14 +
 drivers/gpu/drm/amd/amdgpu/tonga_ih.c             |  14 +
 drivers/gpu/drm/amd/amdgpu/vega10_ih.c            |  90 ++++
 drivers/gpu/drm/amd/amdkfd/kfd_device.c           |  18 +-
 drivers/gpu/drm/amd/amdkfd/kfd_doorbell.c         |  48 +-
 drivers/gpu/drm/amd/amdkfd/kfd_module.c           |   6 -
 drivers/gpu/drm/amd/amdkfd/kfd_pasid.c            |  84 ++--
 drivers/gpu/drm/amd/amdkfd/kfd_priv.h             |  10 +-
 drivers/gpu/drm/amd/amdkfd/kfd_process.c          |   8 +-
 drivers/gpu/drm/amd/include/kgd_kfd_interface.h   |   8 +-
 drivers/gpu/drm/radeon/radeon_kfd.c               |  36 +-
 include/linux/chash.h                             | 349 +++++++++++++++
 lib/Kconfig                                       |   8 +
 lib/Makefile                                      |   2 +
 lib/chash.c                                       | 521 ++++++++++++++++++++++
 30 files changed, 1376 insertions(+), 105 deletions(-)
 create mode 100644 include/linux/chash.h
 create mode 100644 lib/chash.c

--
2.7.4

_______________________________________________
amd-gfx mailing list
amd-gfx at lists.freedesktop.org<mailto:amd-gfx at lists.freedesktop.org>
https://lists.freedesktop.org/mailman/listinfo/amd-gfx


More information about the amd-gfx mailing list