Skip to content

Commit 819362e

Browse files
Ran Sunalexdeucher
authored andcommitted
drm/radeon: Move assignment outside if condition
Fixes the following checkpatch errors: ERROR: do not use assignment in if condition Signed-off-by: Ran Sun <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
1 parent a645529 commit 819362e

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

drivers/gpu/drm/radeon/radeon_legacy_tv.c

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -724,12 +724,14 @@ void radeon_legacy_tv_mode_set(struct drm_encoder *encoder,
724724
}
725725

726726
for (i = 0; i < MAX_H_CODE_TIMING_LEN; i++) {
727-
if ((tv_dac->tv.h_code_timing[i] = hor_timing[i]) == 0)
727+
tv_dac->tv.h_code_timing[i] = hor_timing[i];
728+
if (tv_dac->tv.h_code_timing[i] == 0)
728729
break;
729730
}
730731

731732
for (i = 0; i < MAX_V_CODE_TIMING_LEN; i++) {
732-
if ((tv_dac->tv.v_code_timing[i] = vert_timing[i]) == 0)
733+
tv_dac->tv.v_code_timing[i] = vert_timing[i];
734+
if (tv_dac->tv.v_code_timing[i] == 0)
733735
break;
734736
}
735737

0 commit comments

Comments
 (0)