9c399719 | 09-May-2025 |
Luca Ceresoli <luca.ceresoli@bootlin.com> |
drm: convert many bridge drivers from devm_kzalloc() to devm_drm_bridge_alloc() API
devm_drm_bridge_alloc() is the new API to be used for allocating (and partially initializing) a private driver str
drm: convert many bridge drivers from devm_kzalloc() to devm_drm_bridge_alloc() API
devm_drm_bridge_alloc() is the new API to be used for allocating (and partially initializing) a private driver struct embedding a struct drm_bridge.
For many drivers having a simple code flow in the probe function, this commit does a mass conversion automatically with the following semantic patch. The changes have been reviewed manually for correctness as well as to find any false positives.
The patch has been applied with the explicit exclusion of bridge/panel.c, handled by a separate patch.
After applying the semantic patch, manually fixed these issues:
- 4 drivers need ERR_CAST() instead of PTR_ERR() as the function calling devm_drm_bridge_alloc() returns a pointer - re-added empty lines and comments that the script had removed but that should stay
@@ type T; identifier C; identifier BR; expression DEV; expression FUNCS; @@ -T *C; +T *C; ... ( -C = devm_kzalloc(DEV, ...); -if (!C) - return -ENOMEM; +C = devm_drm_bridge_alloc(DEV, T, BR, FUNCS); +if (IS_ERR(C)) + return PTR_ERR(C); | -C = devm_kzalloc(DEV, ...); -if (!C) - return ERR_PTR(-ENOMEM); +C = devm_drm_bridge_alloc(DEV, T, BR, FUNCS); +if (IS_ERR(C)) + return PTR_ERR(C); ) ... -C->BR.funcs = FUNCS;
Reviewed-by: Manikandan Muralidharan <manikandan.m@microchip.com> # microchip-lvds.c Reviewed-by: Douglas Anderson <dianders@chromium.org> # parade-ps8640 Tested-by: Douglas Anderson <dianders@chromium.org> # parade-ps8640 Acked-by: Maxime Ripard <mripard@kernel.org> Link: https://lore.kernel.org/r/20250509-drm-bridge-convert-to-alloc-api-v3-2-b8bc1f16d7aa@bootlin.com [Luca: fixed trivial patch conflict in adv7511_drv.c while applying] Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
show more ...
|
370f86bc | 22-May-2025 |
Wolfram Sang <wsa+renesas@sang-engineering.com> |
drm: renesas: rcar-du: use proper naming for R-Car
Not RCAR, but R-Car.
Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboa
drm: renesas: rcar-du: use proper naming for R-Car
Not RCAR, but R-Car.
Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Link: https://lore.kernel.org/r/20250522103530.51972-2-wsa+renesas@sang-engineering.com Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
show more ...
|
760e2961 | 19-Jun-2024 |
Jiapeng Chong <jiapeng.chong@linux.alibaba.com> |
drm: Remove unused function rcar_cmm_write
The function are defined in the rcar_cmm.c file, but not called elsewhere, so delete the unused function.
drivers/gpu/drm/renesas/rcar-du/rcar_cmm.c:35:19
drm: Remove unused function rcar_cmm_write
The function are defined in the rcar_cmm.c file, but not called elsewhere, so delete the unused function.
drivers/gpu/drm/renesas/rcar-du/rcar_cmm.c:35:19: warning: unused function 'rcar_cmm_read'.
Reported-by: Abaci Robot <abaci@linux.alibaba.com> Closes: https://bugzilla.openanolis.cn/show_bug.cgi?id=9364 Signed-off-by: Jiapeng Chong <jiapeng.chong@linux.alibaba.com> Reviewed-by: Kieran Bingham <kieran.bingham+renesas@ideasonboard.com> Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Link: https://lore.kernel.org/r/20240619075436.86407-1-jiapeng.chong@linux.alibaba.com Signed-off-by: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com>
show more ...
|
7fc2adcd | 17-Dec-2024 |
Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com> |
drm/rcar-du: Add support for r8a779h0
Add support for r8a779h0. It is very similar to r8a779g0, but has only one output.
Signed-off-by: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com> Test
drm/rcar-du: Add support for r8a779h0
Add support for r8a779h0. It is very similar to r8a779g0, but has only one output.
Signed-off-by: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com> Tested-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com> Link: https://patchwork.freedesktop.org/patch/msgid/20241217-rcar-gh-dsi-v5-7-e77421093c05@ideasonboard.com
show more ...
|
c303814c | 17-Dec-2024 |
Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com> |
drm/rcar-du: dsi: Add r8a779h0 support
Add support for DSI on r8a779h0. As it is identical to DSI on r8a779g0, all we need is to handle the compatible string.
Signed-off-by: Tomi Valkeinen <tomi.va
drm/rcar-du: dsi: Add r8a779h0 support
Add support for DSI on r8a779h0. As it is identical to DSI on r8a779g0, all we need is to handle the compatible string.
Signed-off-by: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com> Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Tested-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com> Link: https://patchwork.freedesktop.org/patch/msgid/20241217-rcar-gh-dsi-v5-6-e77421093c05@ideasonboard.com
show more ...
|
bb5f268b | 17-Dec-2024 |
Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com> |
drm/rcar-du: Write DPTSR only if the second source exists
Currently the driver always writes DPTSR when setting up the hardware. However, writing the register is only meaningful when the second sour
drm/rcar-du: Write DPTSR only if the second source exists
Currently the driver always writes DPTSR when setting up the hardware. However, writing the register is only meaningful when the second source for a plane is used, and the register is not even documented for SoCs that do not have the second source.
So move the write behind a condition.
Signed-off-by: Tomi Valkeinen <tomi.valkeinen+renesas@ideasonboard.com> Reviewed-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Tested-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> # On R-Car M3-N Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com> Link: https://patchwork.freedesktop.org/patch/msgid/20241217-rcar-gh-dsi-v5-2-e77421093c05@ideasonboard.com
show more ...
|