* [PATCH][next] drm/amdgpu/display: remove redundant continue statement
@ 2021-03-03 13:25 Colin King
2021-03-05 19:09 ` Alex Deucher
0 siblings, 1 reply; 2+ messages in thread
From: Colin King @ 2021-03-03 13:25 UTC (permalink / raw)
To: Harry Wentland, Leo Li, Alex Deucher, Christian König,
David Airlie, Daniel Vetter, Aurabindo Pillai, amd-gfx,
dri-devel
Cc: kernel-janitors, linux-kernel
From: Colin Ian King <colin.king@canonical.com>
The continue statement in a for-loop is redudant and can be removed.
Clean up the code to address this.
Addresses-Coverity: ("Continue as no effect")
Fixes: b6f91fc183f7 ("drm/amdgpu/display: buffer INTERRUPT_LOW_IRQ_CONTEXT interrupt work")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
---
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_irq.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_irq.c b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_irq.c
index 8ce10d0973c5..d3c687d07ee6 100644
--- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_irq.c
+++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_irq.c
@@ -520,9 +520,7 @@ static void amdgpu_dm_irq_schedule_work(struct amdgpu_device *adev,
return;
list_for_each_entry (handler_data, handler_list, list) {
- if (!queue_work(system_highpri_wq, &handler_data->work)) {
- continue;
- } else {
+ if (queue_work(system_highpri_wq, &handler_data->work)) {
work_queued = true;
break;
}
--
2.30.0
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH][next] drm/amdgpu/display: remove redundant continue statement
2021-03-03 13:25 [PATCH][next] drm/amdgpu/display: remove redundant continue statement Colin King
@ 2021-03-05 19:09 ` Alex Deucher
0 siblings, 0 replies; 2+ messages in thread
From: Alex Deucher @ 2021-03-05 19:09 UTC (permalink / raw)
To: Colin King
Cc: Harry Wentland, Leo Li, Alex Deucher, Christian König,
David Airlie, Daniel Vetter, Aurabindo Pillai, amd-gfx list,
Maling list - DRI developers, kernel-janitors, LKML
Applied. thanks.
Alex
On Wed, Mar 3, 2021 at 8:25 AM Colin King <colin.king@canonical.com> wrote:
>
> From: Colin Ian King <colin.king@canonical.com>
>
> The continue statement in a for-loop is redudant and can be removed.
> Clean up the code to address this.
>
> Addresses-Coverity: ("Continue as no effect")
> Fixes: b6f91fc183f7 ("drm/amdgpu/display: buffer INTERRUPT_LOW_IRQ_CONTEXT interrupt work")
> Signed-off-by: Colin Ian King <colin.king@canonical.com>
> ---
> drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_irq.c | 4 +---
> 1 file changed, 1 insertion(+), 3 deletions(-)
>
> diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_irq.c b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_irq.c
> index 8ce10d0973c5..d3c687d07ee6 100644
> --- a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_irq.c
> +++ b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_irq.c
> @@ -520,9 +520,7 @@ static void amdgpu_dm_irq_schedule_work(struct amdgpu_device *adev,
> return;
>
> list_for_each_entry (handler_data, handler_list, list) {
> - if (!queue_work(system_highpri_wq, &handler_data->work)) {
> - continue;
> - } else {
> + if (queue_work(system_highpri_wq, &handler_data->work)) {
> work_queued = true;
> break;
> }
> --
> 2.30.0
>
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2021-03-05 19:10 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-03-03 13:25 [PATCH][next] drm/amdgpu/display: remove redundant continue statement Colin King
2021-03-05 19:09 ` Alex Deucher
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).