All of lore.kernel.org
 help / color / mirror / Atom feed
From: Flora Cui <flora.cui-5C7GfCeVMHo@public.gmane.org>
To: "Christian König" <deathsimple-ANTagKRnAhcb1SvskN2V4Q@public.gmane.org>
Cc: dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org,
	amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org
Subject: Re: [PATCH libdrm] amdgpu: update always on cu bitmap
Date: Wed, 21 Jun 2017 10:13:54 +0800	[thread overview]
Message-ID: <20170621021353.GA6518@flora> (raw)
In-Reply-To: <75494a7b-0ee1-b8e4-9b5e-a82bfeb0d1bb-ANTagKRnAhcb1SvskN2V4Q@public.gmane.org>

each SE take 16 bit in cu_ao_mask. For ASICs with 4 SE, cu_ao_mask
has invalid value. so I change cu_ao_mask to cu_ao_bitmap[4][4] and increase
kmd driver version.

On Tue, Jun 20, 2017 at 11:49:23AM +0200, Christian König wrote:
> I'm not 100% sure what this is all about, but it clearly won't work like
> this.
> 
> >diff --git a/include/drm/amdgpu_drm.h b/include/drm/amdgpu_drm.h
> >index df250de..dcbe22c 100644
> >--- a/include/drm/amdgpu_drm.h
> >+++ b/include/drm/amdgpu_drm.h
> >@@ -832,7 +832,7 @@ struct drm_amdgpu_info_device {
> >  	__u64 max_memory_clock;
> >  	/* cu information */
> >  	__u32 cu_active_number;
> >-	__u32 cu_ao_mask;
> >+	__u32 cu_ao_bitmap[4][4];
> >  	__u32 cu_bitmap[4][4];
> >  	/** Render backend pipe mask. One render backend is CB+DB. */
> >  	__u32 enabled_rb_pipes_mask;
> That is a non-backward compatible change to the kernel interface and as such
> forbidden.
> 
> Regards,
> Christian.
> 
> Am 20.06.2017 um 11:04 schrieb Flora Cui:
> >Change-Id: Ie2a812716a6802f7a5a0bc09b1a8db824c5bf2ed
> >Signed-off-by: Flora Cui <Flora.Cui@amd.com>
> >---
> >  amdgpu/amdgpu.h          | 2 +-
> >  amdgpu/amdgpu_gpu_info.c | 2 +-
> >  include/drm/amdgpu_drm.h | 2 +-
> >  3 files changed, 3 insertions(+), 3 deletions(-)
> >
> >diff --git a/amdgpu/amdgpu.h b/amdgpu/amdgpu.h
> >index b6779f9..34ca5f1 100644
> >--- a/amdgpu/amdgpu.h
> >+++ b/amdgpu/amdgpu.h
> >@@ -486,7 +486,7 @@ struct amdgpu_gpu_info {
> >  	uint32_t pa_sc_raster_cfg1[4];
> >  	/* CU info */
> >  	uint32_t cu_active_number;
> >-	uint32_t cu_ao_mask;
> >+	uint32_t cu_ao_bitmap[4][4];
> >  	uint32_t cu_bitmap[4][4];
> >  	/* video memory type info*/
> >  	uint32_t vram_type;
> >diff --git a/amdgpu/amdgpu_gpu_info.c b/amdgpu/amdgpu_gpu_info.c
> >index 34f77be..acfd700 100644
> >--- a/amdgpu/amdgpu_gpu_info.c
> >+++ b/amdgpu/amdgpu_gpu_info.c
> >@@ -229,7 +229,7 @@ drm_private int amdgpu_query_gpu_info_init(amdgpu_device_handle dev)
> >  	}
> >  	dev->info.cu_active_number = dev->dev_info.cu_active_number;
> >-	dev->info.cu_ao_mask = dev->dev_info.cu_ao_mask;
> >+	memcpy(&dev->info.cu_ao_bitmap[0][0], &dev->dev_info.cu_ao_bitmap[0][0], sizeof(dev->info.cu_ao_bitmap));
> >  	memcpy(&dev->info.cu_bitmap[0][0], &dev->dev_info.cu_bitmap[0][0], sizeof(dev->info.cu_bitmap));
> >  	/* TODO: info->max_quad_shader_pipes is not set */
> >diff --git a/include/drm/amdgpu_drm.h b/include/drm/amdgpu_drm.h
> >index df250de..dcbe22c 100644
> >--- a/include/drm/amdgpu_drm.h
> >+++ b/include/drm/amdgpu_drm.h
> >@@ -832,7 +832,7 @@ struct drm_amdgpu_info_device {
> >  	__u64 max_memory_clock;
> >  	/* cu information */
> >  	__u32 cu_active_number;
> >-	__u32 cu_ao_mask;
> >+	__u32 cu_ao_bitmap[4][4];
> >  	__u32 cu_bitmap[4][4];
> >  	/** Render backend pipe mask. One render backend is CB+DB. */
> >  	__u32 enabled_rb_pipes_mask;
> 
> 
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

  parent reply	other threads:[~2017-06-21  2:13 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-06-20  8:15 [PATCH] drm/amdgpu: export gpu always on cu bitmap Flora Cui
     [not found] ` <1497946521-21500-1-git-send-email-Flora.Cui-5C7GfCeVMHo@public.gmane.org>
2017-06-20  9:04   ` [PATCH libdrm] amdgpu: update " Flora Cui
     [not found]     ` <1497949479-22146-1-git-send-email-Flora.Cui-5C7GfCeVMHo@public.gmane.org>
2017-06-20  9:49       ` Christian König
     [not found]         ` <75494a7b-0ee1-b8e4-9b5e-a82bfeb0d1bb-ANTagKRnAhcb1SvskN2V4Q@public.gmane.org>
2017-06-20 10:13           ` Daniel Vetter
2017-06-21  2:13           ` Flora Cui [this message]
2017-06-21  7:08             ` Daniel Vetter
2017-06-26  6:12       ` [PATCH libdrm] amdgpu: update the exported always on CU bitmap Flora Cui
2017-06-26  6:52         ` Michel Dänzer
     [not found]         ` <1498457550-27605-1-git-send-email-Flora.Cui-5C7GfCeVMHo@public.gmane.org>
2017-06-26  7:15           ` Christian König
2017-06-20 14:47   ` [PATCH] drm/amdgpu: export gpu always on cu bitmap Alex Deucher
     [not found]     ` <CADnq5_PQcrNDSHeJyWr=401vn_EKc6i7+Lk+8jUfWfC1H4_EWA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2017-06-21  7:42       ` Flora Cui
2017-06-21  8:32         ` Christian König
2017-06-21 15:36         ` Deucher, Alexander
2017-06-22  3:13   ` [PATCH v2] " Flora Cui
     [not found]     ` <1498101191-19634-1-git-send-email-Flora.Cui-5C7GfCeVMHo@public.gmane.org>
2017-06-22  7:37       ` Christian König
2017-06-22 12:33       ` Deucher, Alexander

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20170621021353.GA6518@flora \
    --to=flora.cui-5c7gfcevmho@public.gmane.org \
    --cc=amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org \
    --cc=deathsimple-ANTagKRnAhcb1SvskN2V4Q@public.gmane.org \
    --cc=dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.