* [PATCH] drm/amdkfd: Remove unnecessary condition in kfd_topology_add_device()
@ 2022-11-25 7:39 Dan Carpenter
2022-11-25 16:42 ` Felix Kuehling
0 siblings, 1 reply; 2+ messages in thread
From: Dan Carpenter @ 2022-11-25 7:39 UTC (permalink / raw)
To: Felix Kuehling
Cc: Pan, Xinhui, kernel-janitors, amd-gfx, Daniel Vetter,
Alex Deucher, David Airlie, Christian König
We re-arranged this code recently so "ret" is always zero at this point.
Signed-off-by: Dan Carpenter <error27@gmail.com>
---
drivers/gpu/drm/amd/amdkfd/kfd_topology.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_topology.c b/drivers/gpu/drm/amd/amdkfd/kfd_topology.c
index 6f01ebc8557b..bceb1a5b2518 100644
--- a/drivers/gpu/drm/amd/amdkfd/kfd_topology.c
+++ b/drivers/gpu/drm/amd/amdkfd/kfd_topology.c
@@ -2012,10 +2012,9 @@ int kfd_topology_add_device(struct kfd_dev *gpu)
kfd_debug_print_topology();
- if (!res)
- kfd_notify_gpu_change(gpu_id, 1);
+ kfd_notify_gpu_change(gpu_id, 1);
- return res;
+ return 0;
}
/**
--
2.35.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] drm/amdkfd: Remove unnecessary condition in kfd_topology_add_device()
2022-11-25 7:39 [PATCH] drm/amdkfd: Remove unnecessary condition in kfd_topology_add_device() Dan Carpenter
@ 2022-11-25 16:42 ` Felix Kuehling
0 siblings, 0 replies; 2+ messages in thread
From: Felix Kuehling @ 2022-11-25 16:42 UTC (permalink / raw)
To: Dan Carpenter
Cc: Pan, Xinhui, kernel-janitors, amd-gfx, Daniel Vetter,
Alex Deucher, David Airlie, Christian König
On 2022-11-25 02:39, Dan Carpenter wrote:
> We re-arranged this code recently so "ret" is always zero at this point.
>
> Signed-off-by: Dan Carpenter <error27@gmail.com>
Reviewed-by: Felix Kuehling <Felix.Kuehling@amd.com>
I'm applying your patch to amd-staging-drm-next. Thank you!
Felix
> ---
> drivers/gpu/drm/amd/amdkfd/kfd_topology.c | 5 ++---
> 1 file changed, 2 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_topology.c b/drivers/gpu/drm/amd/amdkfd/kfd_topology.c
> index 6f01ebc8557b..bceb1a5b2518 100644
> --- a/drivers/gpu/drm/amd/amdkfd/kfd_topology.c
> +++ b/drivers/gpu/drm/amd/amdkfd/kfd_topology.c
> @@ -2012,10 +2012,9 @@ int kfd_topology_add_device(struct kfd_dev *gpu)
>
> kfd_debug_print_topology();
>
> - if (!res)
> - kfd_notify_gpu_change(gpu_id, 1);
> + kfd_notify_gpu_change(gpu_id, 1);
>
> - return res;
> + return 0;
> }
>
> /**
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2022-11-25 16:42 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-11-25 7:39 [PATCH] drm/amdkfd: Remove unnecessary condition in kfd_topology_add_device() Dan Carpenter
2022-11-25 16:42 ` Felix Kuehling
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox