]> Git Repo - J-linux.git/blobdiff - drivers/gpu/drm/amd/amdgpu/amdgpu_object.c
Merge tag 'x86_bugs_pbrsb' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
[J-linux.git] / drivers / gpu / drm / amd / amdgpu / amdgpu_object.c
index 2c82b1d5a0d79f29f133d82cbdee1d22e2054c70..4570ad4493905869ccd04f9fb639d9214d5e87a3 100644 (file)
@@ -882,6 +882,10 @@ int amdgpu_bo_pin_restricted(struct amdgpu_bo *bo, u32 domain,
        if (WARN_ON_ONCE(min_offset > max_offset))
                return -EINVAL;
 
+       /* Check domain to be pinned to against preferred domains */
+       if (bo->preferred_domains & domain)
+               domain = bo->preferred_domains & domain;
+
        /* A shared bo cannot be migrated to VRAM */
        if (bo->tbo.base.import_attach) {
                if (domain & AMDGPU_GEM_DOMAIN_GTT)
This page took 0.029769 seconds and 4 git commands to generate.