[PATCH 1/8] drm: atmel-hlcdc: Fix off-by-one in vertical back porch setting
Manikandan Muralidharan
manikandan.m at microchip.com
Tue May 19 02:01:28 PDT 2026
The vertical back porch field in ATMEL_HLCDC_CFG(2) was programmed
without subtracting 1, unlike the other timing parameters which follow
the controllerâs (value - 1) encoding requirement.
This results in an off-by-one error in the vertical back porch timing.
Signed-off-by: Manikandan Muralidharan <manikandan.m at microchip.com>
---
drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_crtc.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_crtc.c b/drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_crtc.c
index 9dbac2def333..7932d666e9ec 100644
--- a/drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_crtc.c
+++ b/drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_crtc.c
@@ -115,7 +115,7 @@ static void atmel_hlcdc_crtc_mode_set_nofb(struct drm_crtc *c)
(vm.hsync_len - 1) | ((vm.vsync_len - 1) << 16));
regmap_write(regmap, ATMEL_HLCDC_CFG(2),
- (vm.vfront_porch - 1) | (vm.vback_porch << 16));
+ (vm.vfront_porch - 1) | ((vm.vback_porch - 1) << 16));
regmap_write(regmap, ATMEL_HLCDC_CFG(3),
(vm.hfront_porch - 1) | ((vm.hback_porch - 1) << 16));
--
2.25.1
More information about the linux-arm-kernel
mailing list