All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] drm/amdgpu: amend amdgpu_gfx_parse_disable_cu() declaration
@ 2016-09-18 13:37 Baoyou Xie
  2016-09-19 10:00 ` Christian König
  2016-09-20  4:25 ` Alex Deucher
  0 siblings, 2 replies; 3+ messages in thread
From: Baoyou Xie @ 2016-09-18 13:37 UTC (permalink / raw)
  To: alexander.deucher, christian.koenig, airlied, nicolai.haehnle
  Cc: dri-devel, linux-kernel, arnd, baoyou.xie, xie.baoyou

In amdgpu_gfx.h, the declaration of amdgpu_gfx_parse_disable_cu()
is incorrect.

Signed-off-by: Baoyou Xie <baoyou.xie@linaro.org>
---
 drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c | 4 +++-
 drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.h | 5 ++++-
 2 files changed, 7 insertions(+), 2 deletions(-)

diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c
index 01a42b6..8575039 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c
@@ -82,7 +82,9 @@ void amdgpu_gfx_scratch_free(struct amdgpu_device *adev, uint32_t reg)
  * The bitmask of CUs to be disabled in the shader array determined by se and
  * sh is stored in mask[se * max_sh + sh].
  */
-void amdgpu_gfx_parse_disable_cu(unsigned *mask, unsigned max_se, unsigned max_sh)
+void amdgpu_gfx_parse_disable_cu(unsigned int *mask,
+				unsigned int max_se,
+				unsigned int max_sh)
 {
 	unsigned se, sh, cu;
 	const char *p;
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.h b/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.h
index 51321e1..0b9ad4f 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.h
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.h
@@ -27,6 +27,9 @@
 int amdgpu_gfx_scratch_get(struct amdgpu_device *adev, uint32_t *reg);
 void amdgpu_gfx_scratch_free(struct amdgpu_device *adev, uint32_t reg);
 
-unsigned amdgpu_gfx_parse_disable_cu(unsigned *mask, unsigned max_se, unsigned max_sh);
+void
+amdgpu_gfx_parse_disable_cu(unsigned int *mask,
+			   unsigned int max_se,
+			   unsigned int max_sh);
 
 #endif
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] drm/amdgpu: amend amdgpu_gfx_parse_disable_cu() declaration
  2016-09-18 13:37 [PATCH] drm/amdgpu: amend amdgpu_gfx_parse_disable_cu() declaration Baoyou Xie
@ 2016-09-19 10:00 ` Christian König
  2016-09-20  4:25 ` Alex Deucher
  1 sibling, 0 replies; 3+ messages in thread
From: Christian König @ 2016-09-19 10:00 UTC (permalink / raw)
  To: Baoyou Xie, Deucher, Alexander, airlied, Haehnle, Nicolai
  Cc: dri-devel, linux-kernel, arnd, xie.baoyou

Am 18.09.2016 um 15:37 schrieb Baoyou Xie:
> In amdgpu_gfx.h, the declaration of amdgpu_gfx_parse_disable_cu()
> is incorrect.
>
> Signed-off-by: Baoyou Xie <baoyou.xie@linaro.org>

Ups, nice catch.

Patch is Reviewed-by: Christian König <christian.koenig@amd.com>.

Regards,
Christian.

> ---
>   drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c | 4 +++-
>   drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.h | 5 ++++-
>   2 files changed, 7 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c
> index 01a42b6..8575039 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c
> @@ -82,7 +82,9 @@ void amdgpu_gfx_scratch_free(struct amdgpu_device *adev, uint32_t reg)
>    * The bitmask of CUs to be disabled in the shader array determined by se and
>    * sh is stored in mask[se * max_sh + sh].
>    */
> -void amdgpu_gfx_parse_disable_cu(unsigned *mask, unsigned max_se, unsigned max_sh)
> +void amdgpu_gfx_parse_disable_cu(unsigned int *mask,
> +				unsigned int max_se,
> +				unsigned int max_sh)
>   {
>   	unsigned se, sh, cu;
>   	const char *p;
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.h b/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.h
> index 51321e1..0b9ad4f 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.h
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.h
> @@ -27,6 +27,9 @@
>   int amdgpu_gfx_scratch_get(struct amdgpu_device *adev, uint32_t *reg);
>   void amdgpu_gfx_scratch_free(struct amdgpu_device *adev, uint32_t reg);
>   
> -unsigned amdgpu_gfx_parse_disable_cu(unsigned *mask, unsigned max_se, unsigned max_sh);
> +void
> +amdgpu_gfx_parse_disable_cu(unsigned int *mask,
> +			   unsigned int max_se,
> +			   unsigned int max_sh);
>   
>   #endif

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] drm/amdgpu: amend amdgpu_gfx_parse_disable_cu() declaration
  2016-09-18 13:37 [PATCH] drm/amdgpu: amend amdgpu_gfx_parse_disable_cu() declaration Baoyou Xie
  2016-09-19 10:00 ` Christian König
@ 2016-09-20  4:25 ` Alex Deucher
  1 sibling, 0 replies; 3+ messages in thread
From: Alex Deucher @ 2016-09-20  4:25 UTC (permalink / raw)
  To: Baoyou Xie
  Cc: Deucher, Alexander, Christian Koenig, Dave Airlie,
	Nicolai Hähnle, xie.baoyou, Arnd Bergmann, LKML,
	Maling list - DRI developers

On Sun, Sep 18, 2016 at 9:37 AM, Baoyou Xie <baoyou.xie@linaro.org> wrote:
> In amdgpu_gfx.h, the declaration of amdgpu_gfx_parse_disable_cu()
> is incorrect.
>
> Signed-off-by: Baoyou Xie <baoyou.xie@linaro.org>
> ---
>  drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c | 4 +++-
>  drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.h | 5 ++++-
>  2 files changed, 7 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c
> index 01a42b6..8575039 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c
> @@ -82,7 +82,9 @@ void amdgpu_gfx_scratch_free(struct amdgpu_device *adev, uint32_t reg)
>   * The bitmask of CUs to be disabled in the shader array determined by se and
>   * sh is stored in mask[se * max_sh + sh].
>   */
> -void amdgpu_gfx_parse_disable_cu(unsigned *mask, unsigned max_se, unsigned max_sh)
> +void amdgpu_gfx_parse_disable_cu(unsigned int *mask,
> +                               unsigned int max_se,
> +                               unsigned int max_sh)

For consistency with the rest of the driver can you keep the other
parameters as just unsigned?

Alex

>  {
>         unsigned se, sh, cu;
>         const char *p;
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.h b/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.h
> index 51321e1..0b9ad4f 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.h
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.h
> @@ -27,6 +27,9 @@
>  int amdgpu_gfx_scratch_get(struct amdgpu_device *adev, uint32_t *reg);
>  void amdgpu_gfx_scratch_free(struct amdgpu_device *adev, uint32_t reg);
>
> -unsigned amdgpu_gfx_parse_disable_cu(unsigned *mask, unsigned max_se, unsigned max_sh);
> +void
> +amdgpu_gfx_parse_disable_cu(unsigned int *mask,
> +                          unsigned int max_se,
> +                          unsigned int max_sh);
>
>  #endif
> --
> 2.7.4
>
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2016-09-20  4:25 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-09-18 13:37 [PATCH] drm/amdgpu: amend amdgpu_gfx_parse_disable_cu() declaration Baoyou Xie
2016-09-19 10:00 ` Christian König
2016-09-20  4:25 ` Alex Deucher

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.