Skip to content

Commit d7df33d

Browse files
ChristianKoenigAMDgregkh
authored andcommitted
drm/radeon: properly document reloc priority mask
commit 701e1e7 upstream. Instead of hard coding the value properly document that this is an userspace interface. No intended functional change. Signed-off-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
1 parent 64e33ca commit d7df33d

2 files changed

Lines changed: 3 additions & 1 deletion

File tree

‎drivers/gpu/drm/radeon/radeon_cs.c‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,8 @@ static int radeon_cs_parser_relocs(struct radeon_cs_parser *p)
132132
* the buffers used for read only, which doubles the range
133133
* to 0 to 31. 32 is reserved for the kernel driver.
134134
*/
135-
priority = (r->flags & 0xf) * 2 + !!r->write_domain;
135+
priority = (r->flags & RADEON_RELOC_PRIO_MASK) * 2
136+
+ !!r->write_domain;
136137

137138
/* the first reloc of an UVD job is the msg and that must be in
138139
VRAM, also but everything into VRAM on AGP cards to avoid

‎include/uapi/drm/radeon_drm.h‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -942,6 +942,7 @@ struct drm_radeon_cs_chunk {
942942
};
943943

944944
/* drm_radeon_cs_reloc.flags */
945+
#define RADEON_RELOC_PRIO_MASK (0xf << 0)
945946

946947
struct drm_radeon_cs_reloc {
947948
uint32_t handle;

0 commit comments

Comments
 (0)