Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1485799 > unrolled thread

[PATCH] drm/amdgpu: amend amdgpu_gfx_parse_disable_cu() declaration

Started byBaoyou Xie <baoyou.xie@linaro.org>
First post2016-09-18 15:40 +0200
Last post2016-09-20 06:30 +0200
Articles 2 — 2 participants

Back to article view | Back to linux.kernel


Contents

  [PATCH] drm/amdgpu: amend amdgpu_gfx_parse_disable_cu() declaration Baoyou Xie <baoyou.xie@linaro.org> - 2016-09-18 15:40 +0200
    Re: [PATCH] drm/amdgpu: amend amdgpu_gfx_parse_disable_cu() declaration Alex Deucher <alexdeucher@gmail.com> - 2016-09-20 06:30 +0200

#1485799 — [PATCH] drm/amdgpu: amend amdgpu_gfx_parse_disable_cu() declaration

FromBaoyou Xie <baoyou.xie@linaro.org>
Date2016-09-18 15:40 +0200
Subject[PATCH] drm/amdgpu: amend amdgpu_gfx_parse_disable_cu() declaration
Message-ID<siKu5-f7-7@gated-at.bofh.it>
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

[toc] | [next] | [standalone]


#1487047

FromAlex Deucher <alexdeucher@gmail.com>
Date2016-09-20 06:30 +0200
Message-ID<sjkQV-6EF-5@gated-at.bofh.it>
In reply to#1485799
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

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web