* [PATCH] drm/radeon: Move assignment outside if condition [not found] <20230724034415.8257-1-xujianghui@cdjrlc.com> @ 2023-07-24 3:44 ` sunran001 2023-07-24 21:44 ` Alex Deucher 0 siblings, 1 reply; 2+ messages in thread From: sunran001 @ 2023-07-24 3:44 UTC (permalink / raw) To: alexander.deucher; +Cc: amd-gfx, dri-devel, linux-kernel Fixes the following checkpatch errors: ERROR: do not use assignment in if condition Signed-off-by: Ran Sun <sunran001@208suo.com> --- drivers/gpu/drm/radeon/radeon_legacy_tv.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/radeon/radeon_legacy_tv.c b/drivers/gpu/drm/radeon/radeon_legacy_tv.c index 12e180b119ac..7883e9ec0bae 100644 --- a/drivers/gpu/drm/radeon/radeon_legacy_tv.c +++ b/drivers/gpu/drm/radeon/radeon_legacy_tv.c @@ -724,12 +724,14 @@ void radeon_legacy_tv_mode_set(struct drm_encoder *encoder, } for (i = 0; i < MAX_H_CODE_TIMING_LEN; i++) { - if ((tv_dac->tv.h_code_timing[i] = hor_timing[i]) == 0) + tv_dac->tv.h_code_timing[i] = hor_timing[i]; + if (tv_dac->tv.h_code_timing[i] == 0) break; } for (i = 0; i < MAX_V_CODE_TIMING_LEN; i++) { - if ((tv_dac->tv.v_code_timing[i] = vert_timing[i]) == 0) + tv_dac->tv.v_code_timing[i] = vert_timing[i]; + if (tv_dac->tv.v_code_timing[i] == 0) break; } ^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] drm/radeon: Move assignment outside if condition 2023-07-24 3:44 ` [PATCH] drm/radeon: Move assignment outside if condition sunran001 @ 2023-07-24 21:44 ` Alex Deucher 0 siblings, 0 replies; 2+ messages in thread From: Alex Deucher @ 2023-07-24 21:44 UTC (permalink / raw) To: sunran001; +Cc: alexander.deucher, dri-devel, amd-gfx, linux-kernel Applied. Thanks! On Sun, Jul 23, 2023 at 11:45 PM <sunran001@208suo.com> wrote: > > Fixes the following checkpatch errors: > > ERROR: do not use assignment in if condition > > Signed-off-by: Ran Sun <sunran001@208suo.com> > --- > drivers/gpu/drm/radeon/radeon_legacy_tv.c | 6 ++++-- > 1 file changed, 4 insertions(+), 2 deletions(-) > > diff --git a/drivers/gpu/drm/radeon/radeon_legacy_tv.c > b/drivers/gpu/drm/radeon/radeon_legacy_tv.c > index 12e180b119ac..7883e9ec0bae 100644 > --- a/drivers/gpu/drm/radeon/radeon_legacy_tv.c > +++ b/drivers/gpu/drm/radeon/radeon_legacy_tv.c > @@ -724,12 +724,14 @@ void radeon_legacy_tv_mode_set(struct drm_encoder > *encoder, > } > > for (i = 0; i < MAX_H_CODE_TIMING_LEN; i++) { > - if ((tv_dac->tv.h_code_timing[i] = hor_timing[i]) == 0) > + tv_dac->tv.h_code_timing[i] = hor_timing[i]; > + if (tv_dac->tv.h_code_timing[i] == 0) > break; > } > > for (i = 0; i < MAX_V_CODE_TIMING_LEN; i++) { > - if ((tv_dac->tv.v_code_timing[i] = vert_timing[i]) == 0) > + tv_dac->tv.v_code_timing[i] = vert_timing[i]; > + if (tv_dac->tv.v_code_timing[i] == 0) > break; > } ^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2023-07-24 21:44 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <20230724034415.8257-1-xujianghui@cdjrlc.com>
2023-07-24 3:44 ` [PATCH] drm/radeon: Move assignment outside if condition sunran001
2023-07-24 21:44 ` Alex Deucher
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®