diff options
| author | Greg Kroah-Hartman <[email protected]> | 2025-05-13 06:19:37 +0000 |
|---|---|---|
| committer | Greg Kroah-Hartman <[email protected]> | 2025-05-13 06:19:37 +0000 |
| commit | 991919e969043a4422dfebbcadf600a5d28b94e4 (patch) | |
| tree | 4776f9f162c665a9735198fafc466d3e49a14253 /drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c | |
| parent | comedi: drivers: adl_pci9118.c: Edit file so that checkpatch.pl has 0 typo er... (diff) | |
| parent | Linux 6.15-rc6 (diff) | |
| download | kernel-991919e969043a4422dfebbcadf600a5d28b94e4.tar.gz kernel-991919e969043a4422dfebbcadf600a5d28b94e4.zip | |
Merge 6.15-rc6 into char-misc-next
We need the iio/hyperv fixes in here as well.
Signed-off-by: Greg Kroah-Hartman <[email protected]>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c')
| -rw-r--r-- | drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c index e6913fcf2c7b..44e120f9f764 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c @@ -199,6 +199,11 @@ static struct sg_table *amdgpu_dma_buf_map(struct dma_buf_attachment *attach, break; case TTM_PL_VRAM: + /* XGMI-accessible memory should never be DMA-mapped */ + if (WARN_ON(amdgpu_dmabuf_is_xgmi_accessible( + dma_buf_attach_adev(attach), bo))) + return ERR_PTR(-EINVAL); + r = amdgpu_vram_mgr_alloc_sgt(adev, bo->tbo.resource, 0, bo->tbo.base.size, attach->dev, dir, &sgt); |
