search for: need_swiotlb

Displaying 10 results from an estimated 10 matches for "need_swiotlb".

2023 May 18
1
[PATCH 3/4] drm/nouveau: stop using is_swiotlb_active
...e <drm/drm_cache.h> #include "nouveau_drv.h" #include "nouveau_gem.h" @@ -265,7 +265,6 @@ nouveau_ttm_init(struct nouveau_drm *drm) struct nvkm_pci *pci = device->pci; struct nvif_mmu *mmu = &drm->client.mmu; struct drm_device *dev = drm->dev; - bool need_swiotlb = false; int typei, ret; ret = nouveau_ttm_init_host(drm, 0); @@ -300,13 +299,10 @@ nouveau_ttm_init(struct nouveau_drm *drm) drm->agp.cma = pci->agp.cma; } -#if IS_ENABLED(CONFIG_SWIOTLB) && IS_ENABLED(CONFIG_X86) - need_swiotlb = is_swiotlb_active(dev->dev); -#endif...
2023 May 18
4
unexport swiotlb_active
Hi all, this little series removes the last swiotlb API exposed to modules. Diffstat: arch/x86/include/asm/xen/swiotlb-xen.h | 6 ------ arch/x86/kernel/pci-dma.c | 28 ++++------------------------ drivers/gpu/drm/nouveau/nouveau_ttm.c | 10 +++------- drivers/pci/xen-pcifront.c | 6 ------ kernel/dma/swiotlb.c | 1 - 5 files changed, 7
2024 Oct 04
1
[PATCH v2 1/2] drm/ttm: Change ttm_device_init to use a struct instead of multiple bools
...vice_init(&adev->mman.bdev, &amdgpu_bo_driver, > > > adev->dev, > > > ?? ?????? adev_to_drm(adev)->anon_inode- > > > > i_mapping, > > > ?? ?????? adev_to_drm(adev)- > > > > vma_offset_manager, > > > - ?????? adev->need_swiotlb, > > > - ?????? dma_addressing_limited(adev- > > > >dev)); > > > + ?????? (struct ttm_device_init_flags){ > > > + ?????? .use_dma_alloc = adev- > > > > need_swiotlb, > > > + ?????? .use_dma32 = > > > dma_addressing_limit...
2024 Oct 05
1
[PATCH v2 1/2] drm/ttm: Change ttm_device_init to use a struct instead of multiple bools
...dev, &amdgpu_bo_driver, > > > > adev->dev, > > > > ?? ?????? adev_to_drm(adev)->anon_inode- > > > > > i_mapping, > > > > ?? ?????? adev_to_drm(adev)- > > > > > vma_offset_manager, > > > > - ?????? adev->need_swiotlb, > > > > - ?????? dma_addressing_limited(adev- > > > > >dev)); > > > > + ?????? (struct ttm_device_init_flags){ > > > > + ?????? .use_dma_alloc = adev- > > > > > need_swiotlb, > > > > + ?????? .use_dma32 = >...
2024 Oct 02
2
[PATCH v2 0/2] drm/ttm: Add an option to report graphics memory OOM
Some graphics APIs differentiate between out-of-graphics-memory and out-of-host-memory (system memory). Add a device init flag to have -ENOSPC propagated from the resource managers instead of being converted to -ENOMEM, to aid driver stacks in determining what error code to return or whether corrective action can be taken at the driver level. The first patch deals with a ttm_device_init()
2020 May 12
1
[PATCH 1/3] drm/radeon: remove AGP support
...m_tt_populate(struct ttm_tt *ttm, > } > > rdev = radeon_get_rdev(ttm->bdev); > -#if IS_ENABLED(CONFIG_AGP) > - if (rdev->flags & RADEON_IS_AGP) { > - return ttm_agp_tt_populate(ttm, ctx); > - } > -#endif > > #ifdef CONFIG_SWIOTLB > if (rdev->need_swiotlb && swiotlb_nr_tbl()) { > @@ -714,12 +681,6 @@ static void radeon_ttm_tt_unpopulate(struct ttm_tt *ttm) > return; > > rdev = radeon_get_rdev(ttm->bdev); > -#if IS_ENABLED(CONFIG_AGP) > - if (rdev->flags & RADEON_IS_AGP) { > - ttm_agp_tt_unpopulate(ttm);...
2020 May 11
0
[PATCH 1/3] drm/radeon: remove AGP support
...tt == NULL) { @@ -683,11 +655,6 @@ static int radeon_ttm_tt_populate(struct ttm_tt *ttm, } rdev = radeon_get_rdev(ttm->bdev); -#if IS_ENABLED(CONFIG_AGP) - if (rdev->flags & RADEON_IS_AGP) { - return ttm_agp_tt_populate(ttm, ctx); - } -#endif #ifdef CONFIG_SWIOTLB if (rdev->need_swiotlb && swiotlb_nr_tbl()) { @@ -714,12 +681,6 @@ static void radeon_ttm_tt_unpopulate(struct ttm_tt *ttm) return; rdev = radeon_get_rdev(ttm->bdev); -#if IS_ENABLED(CONFIG_AGP) - if (rdev->flags & RADEON_IS_AGP) { - ttm_agp_tt_unpopulate(ttm); - return; - } -#endif #ifdef C...
2020 May 11
2
[PATCH 1/3] drm/radeon: remove AGP support
...} > > rdev = radeon_get_rdev(ttm->bdev); > -#if IS_ENABLED(CONFIG_AGP) > - if (rdev->flags & RADEON_IS_AGP) { > - return ttm_agp_tt_populate(ttm, ctx); > - } > -#endif > > #ifdef CONFIG_SWIOTLB > if (rdev->need_swiotlb && swiotlb_nr_tbl()) { > @@ -714,12 +681,6 @@ static void radeon_ttm_tt_unpopulate(struct ttm_tt *ttm) > return; > > rdev = radeon_get_rdev(ttm->bdev); > -#if IS_ENABLED(CONFIG_AGP) > - if (rdev->flags & RADEON_IS_AGP) { > -...
2020 May 11
10
[RFC] Remove AGP support from Radeon/Nouveau/TTM
Hi guys, Well let's face it AGP is a total headache to maintain and dead for at least 10+ years. We have a lot of x86 specific stuff in the architecture independent graphics memory management to get the caching right, abusing the DMA API on multiple occasions, need to distinct between AGP and driver specific page tables etc etc... So the idea here is to just go ahead and remove the support
2020 Nov 06
4
[PATCH 0/3] drm/nouveau: extend the lifetime of nouveau_drm
Hi folks, Currently, when the device is removed (or the driver is unbound) the nouveau_drm structure de-allocated. However, it's still accessible from and used by some DRM layer callbacks. For example, file handles can be closed after the device has been removed (physically or otherwise). This series converts the Nouveau device structure to be allocated and de-allocated with the