* [PATCH] drm/amdkfd: remove unused sq_int_priv variable
@ 2023-03-30 15:20 Tom Rix
2023-03-30 15:39 ` Felix Kuehling
0 siblings, 1 reply; 4+ messages in thread
From: Tom Rix @ 2023-03-30 15:20 UTC (permalink / raw)
To: Felix.Kuehling, alexander.deucher, christian.koenig, Xinhui.Pan,
airlied, daniel, nathan, ndesaulniers
Cc: amd-gfx, dri-devel, linux-kernel, llvm, Tom Rix
clang with W=1 reports
drivers/gpu/drm/amd/amdgpu/../amdkfd/kfd_int_process_v11.c:282:38: error: variable
'sq_int_priv' set but not used [-Werror,-Wunused-but-set-variable]
uint8_t sq_int_enc, sq_int_errtype, sq_int_priv;
^
This variable is not used so remove it.
Signed-off-by: Tom Rix <trix@redhat.com>
---
drivers/gpu/drm/amd/amdkfd/kfd_int_process_v11.c | 9 +--------
1 file changed, 1 insertion(+), 8 deletions(-)
diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_int_process_v11.c b/drivers/gpu/drm/amd/amdkfd/kfd_int_process_v11.c
index 0d53f6067422..bbd646c0dee7 100644
--- a/drivers/gpu/drm/amd/amdkfd/kfd_int_process_v11.c
+++ b/drivers/gpu/drm/amd/amdkfd/kfd_int_process_v11.c
@@ -279,7 +279,7 @@ static void event_interrupt_wq_v11(struct kfd_dev *dev,
{
uint16_t source_id, client_id, ring_id, pasid, vmid;
uint32_t context_id0, context_id1;
- uint8_t sq_int_enc, sq_int_errtype, sq_int_priv;
+ uint8_t sq_int_enc, sq_int_errtype;
struct kfd_vm_fault_info info = {0};
struct kfd_hsa_memory_exception_data exception_data;
@@ -348,13 +348,6 @@ static void event_interrupt_wq_v11(struct kfd_dev *dev,
break;
case SQ_INTERRUPT_WORD_ENCODING_INST:
print_sq_intr_info_inst(context_id0, context_id1);
- sq_int_priv = REG_GET_FIELD(context_id0,
- SQ_INTERRUPT_WORD_WAVE_CTXID0, PRIV);
- /*if (sq_int_priv && (kfd_set_dbg_ev_from_interrupt(dev, pasid,
- KFD_CTXID0_DOORBELL_ID(context_id0),
- KFD_CTXID0_TRAP_CODE(context_id0),
- NULL, 0)))
- return;*/
break;
case SQ_INTERRUPT_WORD_ENCODING_ERROR:
print_sq_intr_info_error(context_id0, context_id1);
--
2.27.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] drm/amdkfd: remove unused sq_int_priv variable
2023-03-30 15:20 [PATCH] drm/amdkfd: remove unused sq_int_priv variable Tom Rix
@ 2023-03-30 15:39 ` Felix Kuehling
2023-03-30 16:04 ` Kim, Jonathan
0 siblings, 1 reply; 4+ messages in thread
From: Felix Kuehling @ 2023-03-30 15:39 UTC (permalink / raw)
To: Tom Rix, alexander.deucher, christian.koenig, Xinhui.Pan, airlied,
daniel, nathan, ndesaulniers, Kim, Jonathan
Cc: amd-gfx, dri-devel, linux-kernel, llvm
Am 2023-03-30 um 11:20 schrieb Tom Rix:
> clang with W=1 reports
> drivers/gpu/drm/amd/amdgpu/../amdkfd/kfd_int_process_v11.c:282:38: error: variable
> 'sq_int_priv' set but not used [-Werror,-Wunused-but-set-variable]
> uint8_t sq_int_enc, sq_int_errtype, sq_int_priv;
> ^
> This variable is not used so remove it.
Hi Jon,
I think your debugger patches are going to start using this. Can you
comment?
I'd prefer not to apply this patch now, as Jon's patches are expected to
land soon, once Alex is done upstreaming GFX 9.4.3 support.
Regards,
Felix
>
> Signed-off-by: Tom Rix <trix@redhat.com>
> ---
> drivers/gpu/drm/amd/amdkfd/kfd_int_process_v11.c | 9 +--------
> 1 file changed, 1 insertion(+), 8 deletions(-)
>
> diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_int_process_v11.c b/drivers/gpu/drm/amd/amdkfd/kfd_int_process_v11.c
> index 0d53f6067422..bbd646c0dee7 100644
> --- a/drivers/gpu/drm/amd/amdkfd/kfd_int_process_v11.c
> +++ b/drivers/gpu/drm/amd/amdkfd/kfd_int_process_v11.c
> @@ -279,7 +279,7 @@ static void event_interrupt_wq_v11(struct kfd_dev *dev,
> {
> uint16_t source_id, client_id, ring_id, pasid, vmid;
> uint32_t context_id0, context_id1;
> - uint8_t sq_int_enc, sq_int_errtype, sq_int_priv;
> + uint8_t sq_int_enc, sq_int_errtype;
> struct kfd_vm_fault_info info = {0};
> struct kfd_hsa_memory_exception_data exception_data;
>
> @@ -348,13 +348,6 @@ static void event_interrupt_wq_v11(struct kfd_dev *dev,
> break;
> case SQ_INTERRUPT_WORD_ENCODING_INST:
> print_sq_intr_info_inst(context_id0, context_id1);
> - sq_int_priv = REG_GET_FIELD(context_id0,
> - SQ_INTERRUPT_WORD_WAVE_CTXID0, PRIV);
> - /*if (sq_int_priv && (kfd_set_dbg_ev_from_interrupt(dev, pasid,
> - KFD_CTXID0_DOORBELL_ID(context_id0),
> - KFD_CTXID0_TRAP_CODE(context_id0),
> - NULL, 0)))
> - return;*/
> break;
> case SQ_INTERRUPT_WORD_ENCODING_ERROR:
> print_sq_intr_info_error(context_id0, context_id1);
^ permalink raw reply [flat|nested] 4+ messages in thread
* RE: [PATCH] drm/amdkfd: remove unused sq_int_priv variable
2023-03-30 15:39 ` Felix Kuehling
@ 2023-03-30 16:04 ` Kim, Jonathan
2023-05-31 18:16 ` Alex Deucher
0 siblings, 1 reply; 4+ messages in thread
From: Kim, Jonathan @ 2023-03-30 16:04 UTC (permalink / raw)
To: Kuehling, Felix, Tom Rix, Deucher, Alexander, Koenig, Christian,
Pan, Xinhui, airlied@gmail.com, daniel@ffwll.ch,
nathan@kernel.org, ndesaulniers@google.com
Cc: amd-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org,
linux-kernel@vger.kernel.org, llvm@lists.linux.dev
[Public]
Hi Felix,
That is correct. The debugger will need sq_int_priv to work.
Thanks,
Jon
> -----Original Message-----
> From: Kuehling, Felix <Felix.Kuehling@amd.com>
> Sent: Thursday, March 30, 2023 11:39 AM
> To: Tom Rix <trix@redhat.com>; Deucher, Alexander
> <Alexander.Deucher@amd.com>; Koenig, Christian
> <Christian.Koenig@amd.com>; Pan, Xinhui <Xinhui.Pan@amd.com>;
> airlied@gmail.com; daniel@ffwll.ch; nathan@kernel.org;
> ndesaulniers@google.com; Kim, Jonathan <Jonathan.Kim@amd.com>
> Cc: amd-gfx@lists.freedesktop.org; dri-devel@lists.freedesktop.org; linux-
> kernel@vger.kernel.org; llvm@lists.linux.dev
> Subject: Re: [PATCH] drm/amdkfd: remove unused sq_int_priv variable
>
> Am 2023-03-30 um 11:20 schrieb Tom Rix:
> > clang with W=1 reports
> > drivers/gpu/drm/amd/amdgpu/../amdkfd/kfd_int_process_v11.c:282:38:
> error: variable
> > 'sq_int_priv' set but not used [-Werror,-Wunused-but-set-variable]
> > uint8_t sq_int_enc, sq_int_errtype, sq_int_priv;
> > ^
> > This variable is not used so remove it.
>
> Hi Jon,
>
> I think your debugger patches are going to start using this. Can you
> comment?
>
> I'd prefer not to apply this patch now, as Jon's patches are expected to
> land soon, once Alex is done upstreaming GFX 9.4.3 support.
>
> Regards,
> Felix
>
>
> >
> > Signed-off-by: Tom Rix <trix@redhat.com>
> > ---
> > drivers/gpu/drm/amd/amdkfd/kfd_int_process_v11.c | 9 +--------
> > 1 file changed, 1 insertion(+), 8 deletions(-)
> >
> > diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_int_process_v11.c
> b/drivers/gpu/drm/amd/amdkfd/kfd_int_process_v11.c
> > index 0d53f6067422..bbd646c0dee7 100644
> > --- a/drivers/gpu/drm/amd/amdkfd/kfd_int_process_v11.c
> > +++ b/drivers/gpu/drm/amd/amdkfd/kfd_int_process_v11.c
> > @@ -279,7 +279,7 @@ static void event_interrupt_wq_v11(struct kfd_dev
> *dev,
> > {
> > uint16_t source_id, client_id, ring_id, pasid, vmid;
> > uint32_t context_id0, context_id1;
> > - uint8_t sq_int_enc, sq_int_errtype, sq_int_priv;
> > + uint8_t sq_int_enc, sq_int_errtype;
> > struct kfd_vm_fault_info info = {0};
> > struct kfd_hsa_memory_exception_data exception_data;
> >
> > @@ -348,13 +348,6 @@ static void event_interrupt_wq_v11(struct kfd_dev
> *dev,
> > break;
> > case SQ_INTERRUPT_WORD_ENCODING_INST:
> > print_sq_intr_info_inst(context_id0,
> context_id1);
> > - sq_int_priv = REG_GET_FIELD(context_id0,
> > -
> SQ_INTERRUPT_WORD_WAVE_CTXID0, PRIV);
> > - /*if (sq_int_priv &&
> (kfd_set_dbg_ev_from_interrupt(dev, pasid,
> > -
> KFD_CTXID0_DOORBELL_ID(context_id0),
> > -
> KFD_CTXID0_TRAP_CODE(context_id0),
> > - NULL, 0)))
> > - return;*/
> > break;
> > case SQ_INTERRUPT_WORD_ENCODING_ERROR:
> > print_sq_intr_info_error(context_id0,
> context_id1);
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] drm/amdkfd: remove unused sq_int_priv variable
2023-03-30 16:04 ` Kim, Jonathan
@ 2023-05-31 18:16 ` Alex Deucher
0 siblings, 0 replies; 4+ messages in thread
From: Alex Deucher @ 2023-05-31 18:16 UTC (permalink / raw)
To: Kim, Jonathan
Cc: Kuehling, Felix, Tom Rix, Deucher, Alexander, Koenig, Christian,
Pan, Xinhui, airlied@gmail.com, daniel@ffwll.ch,
nathan@kernel.org, ndesaulniers@google.com, llvm@lists.linux.dev,
dri-devel@lists.freedesktop.org, amd-gfx@lists.freedesktop.org,
linux-kernel@vger.kernel.org
On Thu, Mar 30, 2023 at 12:04 PM Kim, Jonathan <Jonathan.Kim@amd.com> wrote:
>
> [Public]
>
> Hi Felix,
>
> That is correct. The debugger will need sq_int_priv to work.
I'll just apply this for now. We can squash the revert into the
debugger changes once those land.
Alex
>
> Thanks,
>
> Jon
>
> > -----Original Message-----
> > From: Kuehling, Felix <Felix.Kuehling@amd.com>
> > Sent: Thursday, March 30, 2023 11:39 AM
> > To: Tom Rix <trix@redhat.com>; Deucher, Alexander
> > <Alexander.Deucher@amd.com>; Koenig, Christian
> > <Christian.Koenig@amd.com>; Pan, Xinhui <Xinhui.Pan@amd.com>;
> > airlied@gmail.com; daniel@ffwll.ch; nathan@kernel.org;
> > ndesaulniers@google.com; Kim, Jonathan <Jonathan.Kim@amd.com>
> > Cc: amd-gfx@lists.freedesktop.org; dri-devel@lists.freedesktop.org; linux-
> > kernel@vger.kernel.org; llvm@lists.linux.dev
> > Subject: Re: [PATCH] drm/amdkfd: remove unused sq_int_priv variable
> >
> > Am 2023-03-30 um 11:20 schrieb Tom Rix:
> > > clang with W=1 reports
> > > drivers/gpu/drm/amd/amdgpu/../amdkfd/kfd_int_process_v11.c:282:38:
> > error: variable
> > > 'sq_int_priv' set but not used [-Werror,-Wunused-but-set-variable]
> > > uint8_t sq_int_enc, sq_int_errtype, sq_int_priv;
> > > ^
> > > This variable is not used so remove it.
> >
> > Hi Jon,
> >
> > I think your debugger patches are going to start using this. Can you
> > comment?
> >
> > I'd prefer not to apply this patch now, as Jon's patches are expected to
> > land soon, once Alex is done upstreaming GFX 9.4.3 support.
> >
> > Regards,
> > Felix
> >
> >
> > >
> > > Signed-off-by: Tom Rix <trix@redhat.com>
> > > ---
> > > drivers/gpu/drm/amd/amdkfd/kfd_int_process_v11.c | 9 +--------
> > > 1 file changed, 1 insertion(+), 8 deletions(-)
> > >
> > > diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_int_process_v11.c
> > b/drivers/gpu/drm/amd/amdkfd/kfd_int_process_v11.c
> > > index 0d53f6067422..bbd646c0dee7 100644
> > > --- a/drivers/gpu/drm/amd/amdkfd/kfd_int_process_v11.c
> > > +++ b/drivers/gpu/drm/amd/amdkfd/kfd_int_process_v11.c
> > > @@ -279,7 +279,7 @@ static void event_interrupt_wq_v11(struct kfd_dev
> > *dev,
> > > {
> > > uint16_t source_id, client_id, ring_id, pasid, vmid;
> > > uint32_t context_id0, context_id1;
> > > - uint8_t sq_int_enc, sq_int_errtype, sq_int_priv;
> > > + uint8_t sq_int_enc, sq_int_errtype;
> > > struct kfd_vm_fault_info info = {0};
> > > struct kfd_hsa_memory_exception_data exception_data;
> > >
> > > @@ -348,13 +348,6 @@ static void event_interrupt_wq_v11(struct kfd_dev
> > *dev,
> > > break;
> > > case SQ_INTERRUPT_WORD_ENCODING_INST:
> > > print_sq_intr_info_inst(context_id0,
> > context_id1);
> > > - sq_int_priv = REG_GET_FIELD(context_id0,
> > > -
> > SQ_INTERRUPT_WORD_WAVE_CTXID0, PRIV);
> > > - /*if (sq_int_priv &&
> > (kfd_set_dbg_ev_from_interrupt(dev, pasid,
> > > -
> > KFD_CTXID0_DOORBELL_ID(context_id0),
> > > -
> > KFD_CTXID0_TRAP_CODE(context_id0),
> > > - NULL, 0)))
> > > - return;*/
> > > break;
> > > case SQ_INTERRUPT_WORD_ENCODING_ERROR:
> > > print_sq_intr_info_error(context_id0,
> > context_id1);
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2023-05-31 18:17 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-03-30 15:20 [PATCH] drm/amdkfd: remove unused sq_int_priv variable Tom Rix
2023-03-30 15:39 ` Felix Kuehling
2023-03-30 16:04 ` Kim, Jonathan
2023-05-31 18:16 ` Alex Deucher
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox