All of lore.kernel.org
 help / color / mirror / Atom feed
From: Alex Deucher <alexdeucher-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
To: Oak Zeng <zengshanjun-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
Cc: Oak Zeng <Oak.Zeng-5C7GfCeVMHo@public.gmane.org>,
	amd-gfx list
	<amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org>
Subject: Re: [PATCH] drm/amdgpu: Move IH clientid defs to separate file
Date: Thu, 8 Mar 2018 23:40:22 -0500	[thread overview]
Message-ID: <CADnq5_M8njnYh2uRSAuFq1xpqY4fv0c9Ju0_umAwoH197yUjuA@mail.gmail.com> (raw)
In-Reply-To: <CADnq5_N8Q3GUY-qFtbUzpU+cX_PmdbF7R0pBKby0jq1cw1Jong-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>

On Thu, Mar 8, 2018 at 11:26 PM, Alex Deucher <alexdeucher@gmail.com> wrote:
> On Thu, Mar 8, 2018 at 6:24 PM, Oak Zeng <zengshanjun@gmail.com> wrote:
>> This is preparation for sharing client ID definitions
>> between amdgpu and amdkfd
>>
>> Change-Id: Ie0b7b14c9c2366fd896745a51b74a9ba97ee3224
>> Signed-off-by: Oak Zeng <Oak.Zeng@amd.com>
>> ---
>>  drivers/gpu/drm/amd/amdgpu/amdgpu_ih.h          | 44 +--------------
>>  drivers/gpu/drm/amd/include/soc15_ih_clientid.h | 72 +++++++++++++++++++++++++
>>  2 files changed, 73 insertions(+), 43 deletions(-)
>>  create mode 100644 drivers/gpu/drm/amd/include/soc15_ih_clientid.h
>>
>> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_ih.h b/drivers/gpu/drm/amd/amdgpu/amdgpu_ih.h
>> index b8a7dba..62a9869 100644
>> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_ih.h
>> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_ih.h
>> @@ -25,51 +25,9 @@
>>  #define __AMDGPU_IH_H__
>>
>>  #include <linux/chash.h>
>> +#include "soc15_ih_clientid.h"
>>
>>  struct amdgpu_device;
>> - /*
>> -  * vega10+ IH clients
>> - */
>> -enum amdgpu_ih_clientid
>> -{
>> -    AMDGPU_IH_CLIENTID_IH          = 0x00,
>> -    AMDGPU_IH_CLIENTID_ACP         = 0x01,
>> -    AMDGPU_IH_CLIENTID_ATHUB       = 0x02,
>> -    AMDGPU_IH_CLIENTID_BIF         = 0x03,
>> -    AMDGPU_IH_CLIENTID_DCE         = 0x04,
>> -    AMDGPU_IH_CLIENTID_ISP         = 0x05,
>> -    AMDGPU_IH_CLIENTID_PCIE0       = 0x06,
>> -    AMDGPU_IH_CLIENTID_RLC         = 0x07,
>> -    AMDGPU_IH_CLIENTID_SDMA0       = 0x08,
>> -    AMDGPU_IH_CLIENTID_SDMA1       = 0x09,
>> -    AMDGPU_IH_CLIENTID_SE0SH       = 0x0a,
>> -    AMDGPU_IH_CLIENTID_SE1SH       = 0x0b,
>> -    AMDGPU_IH_CLIENTID_SE2SH       = 0x0c,
>> -    AMDGPU_IH_CLIENTID_SE3SH       = 0x0d,
>> -    AMDGPU_IH_CLIENTID_SYSHUB      = 0x0e,
>> -    AMDGPU_IH_CLIENTID_THM         = 0x0f,
>> -    AMDGPU_IH_CLIENTID_UVD         = 0x10,
>> -    AMDGPU_IH_CLIENTID_VCE0        = 0x11,
>> -    AMDGPU_IH_CLIENTID_VMC         = 0x12,
>> -    AMDGPU_IH_CLIENTID_XDMA        = 0x13,
>> -    AMDGPU_IH_CLIENTID_GRBM_CP     = 0x14,
>> -    AMDGPU_IH_CLIENTID_ATS         = 0x15,
>> -    AMDGPU_IH_CLIENTID_ROM_SMUIO    = 0x16,
>> -    AMDGPU_IH_CLIENTID_DF          = 0x17,
>> -    AMDGPU_IH_CLIENTID_VCE1        = 0x18,
>> -    AMDGPU_IH_CLIENTID_PWR         = 0x19,
>> -    AMDGPU_IH_CLIENTID_UTCL2       = 0x1b,
>> -    AMDGPU_IH_CLIENTID_EA          = 0x1c,
>> -    AMDGPU_IH_CLIENTID_UTCL2LOG            = 0x1d,
>> -    AMDGPU_IH_CLIENTID_MP0         = 0x1e,
>> -    AMDGPU_IH_CLIENTID_MP1         = 0x1f,
>> -
>> -    AMDGPU_IH_CLIENTID_MAX,
>> -
>> -    AMDGPU_IH_CLIENTID_VCN         = AMDGPU_IH_CLIENTID_UVD
>> -};
>> -
>> -#define AMDGPU_IH_CLIENTID_LEGACY 0
>
> You may want to leave the LEGACY define in this header since it's only
> used for pre-soc15 asics.

Although, if you will use it with kfd as well, I suppose it makes
sense to keep in together.  Either way:
Acked-by: Alex Deucher <alexander.deucher@amd.com>

>
> Alex
>
>
>>
>>  #define AMDGPU_PAGEFAULT_HASH_BITS 8
>>  struct amdgpu_retryfault_hashtable {
>> diff --git a/drivers/gpu/drm/amd/include/soc15_ih_clientid.h b/drivers/gpu/drm/amd/include/soc15_ih_clientid.h
>> new file mode 100644
>> index 0000000..e2e8c63
>> --- /dev/null
>> +++ b/drivers/gpu/drm/amd/include/soc15_ih_clientid.h
>> @@ -0,0 +1,72 @@
>> +/*
>> + * Copyright 2018 Advanced Micro Devices, Inc.
>> + *
>> + * Permission is hereby granted, free of charge, to any person obtaining a
>> + * copy of this software and associated documentation files (the "Software"),
>> + * to deal in the Software without restriction, including without limitation
>> + * the rights to use, copy, modify, merge, publish, distribute, sublicense,
>> + * and/or sell copies of the Software, and to permit persons to whom the
>> + * Software is furnished to do so, subject to the following conditions:
>> + *
>> + * The above copyright notice and this permission notice shall be included in
>> + * all copies or substantial portions of the Software.
>> + *
>> + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
>> + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
>> + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
>> + * THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR
>> + * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
>> + * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
>> + * OTHER DEALINGS IN THE SOFTWARE.
>> + *
>> + */
>> +
>> +#ifndef __SOC15_IH_CLIENTID_H__
>> +#define __SOC15_IH_CLIENTID_H__
>> +
>> + /*
>> +  * vega10+ IH clients
>> + */
>> +enum amdgpu_ih_clientid {
>> +       AMDGPU_IH_CLIENTID_IH           = 0x00,
>> +       AMDGPU_IH_CLIENTID_ACP          = 0x01,
>> +       AMDGPU_IH_CLIENTID_ATHUB        = 0x02,
>> +       AMDGPU_IH_CLIENTID_BIF          = 0x03,
>> +       AMDGPU_IH_CLIENTID_DCE          = 0x04,
>> +       AMDGPU_IH_CLIENTID_ISP          = 0x05,
>> +       AMDGPU_IH_CLIENTID_PCIE0        = 0x06,
>> +       AMDGPU_IH_CLIENTID_RLC          = 0x07,
>> +       AMDGPU_IH_CLIENTID_SDMA0        = 0x08,
>> +       AMDGPU_IH_CLIENTID_SDMA1        = 0x09,
>> +       AMDGPU_IH_CLIENTID_SE0SH        = 0x0a,
>> +       AMDGPU_IH_CLIENTID_SE1SH        = 0x0b,
>> +       AMDGPU_IH_CLIENTID_SE2SH        = 0x0c,
>> +       AMDGPU_IH_CLIENTID_SE3SH        = 0x0d,
>> +       AMDGPU_IH_CLIENTID_SYSHUB       = 0x0e,
>> +       AMDGPU_IH_CLIENTID_THM          = 0x0f,
>> +       AMDGPU_IH_CLIENTID_UVD          = 0x10,
>> +       AMDGPU_IH_CLIENTID_VCE0         = 0x11,
>> +       AMDGPU_IH_CLIENTID_VMC          = 0x12,
>> +       AMDGPU_IH_CLIENTID_XDMA         = 0x13,
>> +       AMDGPU_IH_CLIENTID_GRBM_CP      = 0x14,
>> +       AMDGPU_IH_CLIENTID_ATS          = 0x15,
>> +       AMDGPU_IH_CLIENTID_ROM_SMUIO    = 0x16,
>> +       AMDGPU_IH_CLIENTID_DF           = 0x17,
>> +       AMDGPU_IH_CLIENTID_VCE1         = 0x18,
>> +       AMDGPU_IH_CLIENTID_PWR          = 0x19,
>> +       AMDGPU_IH_CLIENTID_UTCL2        = 0x1b,
>> +       AMDGPU_IH_CLIENTID_EA           = 0x1c,
>> +       AMDGPU_IH_CLIENTID_UTCL2LOG     = 0x1d,
>> +       AMDGPU_IH_CLIENTID_MP0          = 0x1e,
>> +       AMDGPU_IH_CLIENTID_MP1          = 0x1f,
>> +
>> +       AMDGPU_IH_CLIENTID_MAX,
>> +
>> +       AMDGPU_IH_CLIENTID_VCN          = AMDGPU_IH_CLIENTID_UVD
>> +};
>> +
>> +#define AMDGPU_IH_CLIENTID_LEGACY 0
>> +
>> +#endif
>> +
>> +
>> --
>> 2.7.4
>>
>> _______________________________________________
>> amd-gfx mailing list
>> amd-gfx@lists.freedesktop.org
>> https://lists.freedesktop.org/mailman/listinfo/amd-gfx
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

  parent reply	other threads:[~2018-03-09  4:40 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-03-08 23:24 [PATCH] drm/amdgpu: Move IH clientid defs to separate file Oak Zeng
     [not found] ` <1520551491-29948-1-git-send-email-Oak.Zeng-5C7GfCeVMHo@public.gmane.org>
2018-03-09  4:26   ` Alex Deucher
     [not found]     ` <CADnq5_N8Q3GUY-qFtbUzpU+cX_PmdbF7R0pBKby0jq1cw1Jong-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2018-03-09  4:40       ` Alex Deucher [this message]
2018-03-09  5:17   ` zhoucm1
2018-03-09  7:48   ` Christian König
     [not found]     ` <4107d6b6-d969-478f-6b25-b9cf693292b2-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2018-03-09 14:52       ` Zeng, Oak
     [not found]         ` <BN6PR12MB16513DCEDF0969EEBBE0A0CB80DE0-/b2+HYfkarRSqX7PDniLCgdYzm3356FpvxpqHgZTriW3zl9H0oFU5g@public.gmane.org>
2018-03-09 17:41           ` Deucher, Alexander
2018-03-09 23:23 Oak Zeng
     [not found] ` <1520637814-13988-1-git-send-email-Oak.Zeng-5C7GfCeVMHo@public.gmane.org>
2018-03-12  2:55   ` zhoucm1

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=CADnq5_M8njnYh2uRSAuFq1xpqY4fv0c9Ju0_umAwoH197yUjuA@mail.gmail.com \
    --to=alexdeucher-re5jqeeqqe8avxtiumwx3w@public.gmane.org \
    --cc=Oak.Zeng-5C7GfCeVMHo@public.gmane.org \
    --cc=amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org \
    --cc=zengshanjun-Re5JQEeQqe8AvxtiuMwx3w@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.