diff mbox series

drm/stm: ltdc: fix various coding-style warnings

Message ID 20220603134334.592805-1-yannick.fertre@foss.st.com (mailing list archive)
State New, archived
Headers show
Series drm/stm: ltdc: fix various coding-style warnings | expand

Commit Message

Yannick Fertre June 3, 2022, 1:43 p.m. UTC
Fix issues reported by checkpatch.pl:
- Braces {} should be used on all arms
- Blank lines

Signed-off-by: Yannick Fertre <yannick.fertre@foss.st.com>
---
 drivers/gpu/drm/stm/ltdc.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

Comments

Raphael Gallais-Pou June 9, 2022, 3:36 p.m. UTC | #1
Hi,


Thanks

Acked-by: Raphael Gallais-Pou <raphael.gallais-pou@foss.st.com>


Cheers,

Raphaƫl

On 6/3/22 15:43, Yannick Fertre wrote:
> Fix issues reported by checkpatch.pl:
> - Braces {} should be used on all arms
> - Blank lines
>
> Signed-off-by: Yannick Fertre <yannick.fertre@foss.st.com>
> ---
>  drivers/gpu/drm/stm/ltdc.c | 5 ++---
>  1 file changed, 2 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/gpu/drm/stm/ltdc.c b/drivers/gpu/drm/stm/ltdc.c
> index a4098aaff243..6a9f613839b5 100644
> --- a/drivers/gpu/drm/stm/ltdc.c
> +++ b/drivers/gpu/drm/stm/ltdc.c
> @@ -908,9 +908,9 @@ static void ltdc_crtc_mode_set_nofb(struct drm_crtc *crtc)
>  		drm_connector_list_iter_end(&iter);
>  	}
>  
> -	if (bridge && bridge->timings)
> +	if (bridge && bridge->timings) {
>  		bus_flags = bridge->timings->input_bus_flags;
> -	else if (connector) {
> +	} else if (connector) {
>  		bus_flags = connector->display_info.bus_flags;
>  		if (connector->display_info.num_bus_formats)
>  			bus_formats = connector->display_info.bus_formats[0];
> @@ -1917,7 +1917,6 @@ int ltdc_load(struct drm_device *ddev)
>  			DRM_ERROR("Failed to register LTDC interrupt\n");
>  			goto err;
>  		}
> -
>  	}
>  
>  	crtc = devm_kzalloc(dev, sizeof(*crtc), GFP_KERNEL);
Philippe CORNU June 27, 2022, 2:11 p.m. UTC | #2
On 6/3/22 15:43, Yannick Fertre wrote:
> Fix issues reported by checkpatch.pl:
> - Braces {} should be used on all arms
> - Blank lines
> 
> Signed-off-by: Yannick Fertre <yannick.fertre@foss.st.com>
> ---
>   drivers/gpu/drm/stm/ltdc.c | 5 ++---
>   1 file changed, 2 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/gpu/drm/stm/ltdc.c b/drivers/gpu/drm/stm/ltdc.c
> index a4098aaff243..6a9f613839b5 100644
> --- a/drivers/gpu/drm/stm/ltdc.c
> +++ b/drivers/gpu/drm/stm/ltdc.c
> @@ -908,9 +908,9 @@ static void ltdc_crtc_mode_set_nofb(struct drm_crtc *crtc)
>   		drm_connector_list_iter_end(&iter);
>   	}
>   
> -	if (bridge && bridge->timings)
> +	if (bridge && bridge->timings) {
>   		bus_flags = bridge->timings->input_bus_flags;
> -	else if (connector) {
> +	} else if (connector) {
>   		bus_flags = connector->display_info.bus_flags;
>   		if (connector->display_info.num_bus_formats)
>   			bus_formats = connector->display_info.bus_formats[0];
> @@ -1917,7 +1917,6 @@ int ltdc_load(struct drm_device *ddev)
>   			DRM_ERROR("Failed to register LTDC interrupt\n");
>   			goto err;
>   		}
> -
>   	}
>   
>   	crtc = devm_kzalloc(dev, sizeof(*crtc), GFP_KERNEL);
Dear Yannick,
Many thanks for your patch,
Applied on drm-misc-next.
Have a good day
Philippe :-)
diff mbox series

Patch

diff --git a/drivers/gpu/drm/stm/ltdc.c b/drivers/gpu/drm/stm/ltdc.c
index a4098aaff243..6a9f613839b5 100644
--- a/drivers/gpu/drm/stm/ltdc.c
+++ b/drivers/gpu/drm/stm/ltdc.c
@@ -908,9 +908,9 @@  static void ltdc_crtc_mode_set_nofb(struct drm_crtc *crtc)
 		drm_connector_list_iter_end(&iter);
 	}
 
-	if (bridge && bridge->timings)
+	if (bridge && bridge->timings) {
 		bus_flags = bridge->timings->input_bus_flags;
-	else if (connector) {
+	} else if (connector) {
 		bus_flags = connector->display_info.bus_flags;
 		if (connector->display_info.num_bus_formats)
 			bus_formats = connector->display_info.bus_formats[0];
@@ -1917,7 +1917,6 @@  int ltdc_load(struct drm_device *ddev)
 			DRM_ERROR("Failed to register LTDC interrupt\n");
 			goto err;
 		}
-
 	}
 
 	crtc = devm_kzalloc(dev, sizeof(*crtc), GFP_KERNEL);