aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd/amdgpu/amdgpu.h
diff options
context:
space:
mode:
authorHawking Zhang <[email protected]>2025-06-16 09:17:30 +0000
committerAlex Deucher <[email protected]>2025-06-24 14:04:13 +0000
commitb9c58f4e325c01ec8838da2e86befe4b1b91c2cc (patch)
treedc854adbab774c5db18433a71261cfddbaad463e /drivers/gpu/drm/amd/amdgpu/amdgpu.h
parentdrm/amdgpu: Convert query_memory_partition into common helpers (diff)
downloadkernel-b9c58f4e325c01ec8838da2e86befe4b1b91c2cc.tar.gz
kernel-b9c58f4e325c01ec8838da2e86befe4b1b91c2cc.zip
drm/amdgpu: Generalize is_multi_chiplet with a common helper v2
It is not necessary to be ip generation specific v2: rename the helper to is_multi_aid (Lijo) Signed-off-by: Hawking Zhang <[email protected]> Reviewed-by: Lijo Lazar <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu.h')
-rw-r--r--drivers/gpu/drm/amd/amdgpu/amdgpu.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu.h b/drivers/gpu/drm/amd/amdgpu/amdgpu.h
index 76ce77f43d4f..3f0b1fa590c6 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu.h
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu.h
@@ -1334,6 +1334,11 @@ static inline struct amdgpu_device *amdgpu_ttm_adev(struct ttm_device *bdev)
return container_of(bdev, struct amdgpu_device, mman.bdev);
}
+static inline bool amdgpu_is_multi_aid(struct amdgpu_device *adev)
+{
+ return !!adev->aid_mask;
+}
+
int amdgpu_device_init(struct amdgpu_device *adev,
uint32_t flags);
void amdgpu_device_fini_hw(struct amdgpu_device *adev);