Skip to contentSkip to conversation

amdgpu: Minor cleanups

PATCH In review Michel Dänzer 2 participants 4 messages Jun 24, 2019 1 message not in the archive

lore
Share & tools
lore
#0 lore raw

cover amdgpu: Minor cleanups

From: Michel Dänzer <[email protected]>

I stumbled over these while working on bigger changes.

Michel Dänzer (2):
amdgpu: Move union declaration to top of
amdgpu_cs_ctx_override_priority
amdgpu: Update amdgpu_bo_handle_type_kms_noimport documentation

 amdgpu/amdgpu.h    | 4 ++--
 amdgpu/amdgpu_cs.c | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)
Signature · 6 lines
2.20.1

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

A message that is not in the archive (sent off-list or not yet received): 20190624154535.8619-1-michel-otUistvHUpPR7s880joybQ@public.gmane.org

#2 lore raw

PATCH 1/2 amdgpu: Move union declaration to top of amdgpu_cs_ctx_override_priority

From: Michel Dänzer <[email protected]>

Avoids compiler warning:

../../amdgpu/amdgpu_cs.c: In function 'amdgpu_cs_ctx_override_priority':
../../amdgpu/amdgpu_cs.c:155:2: warning: ISO C90 forbids mixed declarations and code [-Wdeclaration-after-statement]
union drm_amdgpu_sched args;
^~~~~

---
 amdgpu/amdgpu_cs.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
amdgpu/amdgpu_cs.c +1 -1
index 977fa3cf..20d5aef2 100644
@@ -147,12 +147,12 @@ drm_public int amdgpu_cs_ctx_override_priority(amdgpu_device_handle dev,
                                                int master_fd,
                                                unsigned priority)
 {
+	union drm_amdgpu_sched args;
 	int r;
 
 	if (!dev || !context || master_fd < 0)
 		return -EINVAL;
 
-	union drm_amdgpu_sched args;
 	memset(&args, 0, sizeof(args));
 
 	args.in.op = AMDGPU_SCHED_OP_CONTEXT_PRIORITY_OVERRIDE;
Signature · 6 lines
2.20.1

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
#3 lore raw

PATCH 2/2 amdgpu: Update amdgpu_bo_handle_type_kms_noimport documentation

In reply to a message not in the archive

From: Michel Dänzer <[email protected]>

To reflect current reality.

---
 amdgpu/amdgpu.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
amdgpu/amdgpu.h +2 -2
index 9d9b0832..66e45f73 100644
@@ -87,8 +87,8 @@ enum amdgpu_bo_handle_type {
 	/** DMA-buf fd handle */
 	amdgpu_bo_handle_type_dma_buf_fd = 2,
 
-	/** KMS handle, but re-importing as a DMABUF handle through
-	 *  drmPrimeHandleToFD is forbidden. (Glamor does that)
+	/** Deprecated in favour of and same behaviour as
+	 * amdgpu_bo_handle_type_kms, use that instead of this
 	 */
 	amdgpu_bo_handle_type_kms_noimport = 3,
 };
Signature · 6 lines
2.20.1

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
Reviewed-by
#4 lore raw
In reply to a message not in the archive

Am 24.06.19 um 17:45 schrieb Michel Dänzer:

Quoted 4 lines

From: Michel Dänzer <[email protected]>

I stumbled over these while working on bigger changes.

Quoted 9 lines

Michel Dänzer (2):
amdgpu: Move union declaration to top of
amdgpu_cs_ctx_override_priority
amdgpu: Update amdgpu_bo_handle_type_kms_noimport documentation

  amdgpu/amdgpu.h    | 4 ++--
  amdgpu/amdgpu_cs.c | 2 +-
  2 files changed, 3 insertions(+), 3 deletions(-)

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx