LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
* [PATCH] drm/msm: remove unneeded variable
@ 2021-08-31 11:51 cgel.zte
  2021-09-02 18:40 ` Lyude Paul
  2021-09-03 18:51 ` Dmitry Baryshkov
  0 siblings, 2 replies; 5+ messages in thread
From: cgel.zte @ 2021-08-31 11:51 UTC (permalink / raw)
  To: robdclark
  Cc: sean, airlied, daniel, lyude, airlied, laurent.pinchart,
	chi.minghao, treding, linux-arm-msm, dri-devel, freedreno,
	linux-kernel, Zeal Robot

From: Chi Minghao <chi.minghao@zte.com.cn>

Fix the following coccicheck REVIEW:
./drivers/gpu/drm/msm/edp/edp_ctrl.c:1245:5-8 Unneeded variable

Reported-by: Zeal Robot <zealci@zte.com.cn>
Signed-off-by: Chi Minghao <chi.minghao@zte.com.cn>
---
 drivers/gpu/drm/msm/edp/edp_ctrl.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/gpu/drm/msm/edp/edp_ctrl.c b/drivers/gpu/drm/msm/edp/edp_ctrl.c
index 4fb397ee7c84..3610e26e62fa 100644
--- a/drivers/gpu/drm/msm/edp/edp_ctrl.c
+++ b/drivers/gpu/drm/msm/edp/edp_ctrl.c
@@ -1242,8 +1242,6 @@ bool msm_edp_ctrl_panel_connected(struct edp_ctrl *ctrl)
 int msm_edp_ctrl_get_panel_info(struct edp_ctrl *ctrl,
 		struct drm_connector *connector, struct edid **edid)
 {
-	int ret = 0;
-
 	mutex_lock(&ctrl->dev_mutex);
 
 	if (ctrl->edid) {
@@ -1278,7 +1276,7 @@ int msm_edp_ctrl_get_panel_info(struct edp_ctrl *ctrl,
 	}
 unlock_ret:
 	mutex_unlock(&ctrl->dev_mutex);
-	return ret;
+	return 0;
 }
 
 int msm_edp_ctrl_timing_cfg(struct edp_ctrl *ctrl,
-- 
2.25.1


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] drm/msm: remove unneeded variable
  2021-08-31 11:51 [PATCH] drm/msm: remove unneeded variable cgel.zte
@ 2021-09-02 18:40 ` Lyude Paul
  2021-09-03 18:31   ` Dmitry Baryshkov
  2021-09-03 18:51 ` Dmitry Baryshkov
  1 sibling, 1 reply; 5+ messages in thread
From: Lyude Paul @ 2021-09-02 18:40 UTC (permalink / raw)
  To: cgel.zte, robdclark
  Cc: sean, airlied, daniel, airlied, laurent.pinchart, chi.minghao,
	treding, linux-arm-msm, dri-devel, freedreno, linux-kernel,
	Zeal Robot

Reviewed-by: Lyude Paul <lyude@redhat.com>

Do you need me to push this?

On Tue, 2021-08-31 at 04:51 -0700, cgel.zte@gmail.com wrote:
> From: Chi Minghao <chi.minghao@zte.com.cn>
> 
> Fix the following coccicheck REVIEW:
> ./drivers/gpu/drm/msm/edp/edp_ctrl.c:1245:5-8 Unneeded variable
> 
> Reported-by: Zeal Robot <zealci@zte.com.cn>
> Signed-off-by: Chi Minghao <chi.minghao@zte.com.cn>
> ---
>  drivers/gpu/drm/msm/edp/edp_ctrl.c | 4 +---
>  1 file changed, 1 insertion(+), 3 deletions(-)
> 
> diff --git a/drivers/gpu/drm/msm/edp/edp_ctrl.c
> b/drivers/gpu/drm/msm/edp/edp_ctrl.c
> index 4fb397ee7c84..3610e26e62fa 100644
> --- a/drivers/gpu/drm/msm/edp/edp_ctrl.c
> +++ b/drivers/gpu/drm/msm/edp/edp_ctrl.c
> @@ -1242,8 +1242,6 @@ bool msm_edp_ctrl_panel_connected(struct edp_ctrl
> *ctrl)
>  int msm_edp_ctrl_get_panel_info(struct edp_ctrl *ctrl,
>                 struct drm_connector *connector, struct edid **edid)
>  {
> -       int ret = 0;
> -
>         mutex_lock(&ctrl->dev_mutex);
>  
>         if (ctrl->edid) {
> @@ -1278,7 +1276,7 @@ int msm_edp_ctrl_get_panel_info(struct edp_ctrl *ctrl,
>         }
>  unlock_ret:
>         mutex_unlock(&ctrl->dev_mutex);
> -       return ret;
> +       return 0;
>  }
>  
>  int msm_edp_ctrl_timing_cfg(struct edp_ctrl *ctrl,

-- 
Cheers,
 Lyude Paul (she/her)
 Software Engineer at Red Hat


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] drm/msm: remove unneeded variable
  2021-09-02 18:40 ` Lyude Paul
@ 2021-09-03 18:31   ` Dmitry Baryshkov
  2021-09-03 18:40     ` Lyude Paul
  0 siblings, 1 reply; 5+ messages in thread
From: Dmitry Baryshkov @ 2021-09-03 18:31 UTC (permalink / raw)
  To: Lyude Paul, cgel.zte, robdclark
  Cc: sean, airlied, daniel, airlied, laurent.pinchart, chi.minghao,
	treding, linux-arm-msm, dri-devel, freedreno, linux-kernel,
	Zeal Robot

On 02/09/2021 21:40, Lyude Paul wrote:
> Reviewed-by: Lyude Paul <lyude@redhat.com>
> 
> Do you need me to push this?

We'd pick this up through the msm tree.

> 
> On Tue, 2021-08-31 at 04:51 -0700, cgel.zte@gmail.com wrote:
>> From: Chi Minghao <chi.minghao@zte.com.cn>
>>
>> Fix the following coccicheck REVIEW:
>> ./drivers/gpu/drm/msm/edp/edp_ctrl.c:1245:5-8 Unneeded variable
>>
>> Reported-by: Zeal Robot <zealci@zte.com.cn>
>> Signed-off-by: Chi Minghao <chi.minghao@zte.com.cn>
>> ---
>>   drivers/gpu/drm/msm/edp/edp_ctrl.c | 4 +---
>>   1 file changed, 1 insertion(+), 3 deletions(-)
>>
>> diff --git a/drivers/gpu/drm/msm/edp/edp_ctrl.c
>> b/drivers/gpu/drm/msm/edp/edp_ctrl.c
>> index 4fb397ee7c84..3610e26e62fa 100644
>> --- a/drivers/gpu/drm/msm/edp/edp_ctrl.c
>> +++ b/drivers/gpu/drm/msm/edp/edp_ctrl.c
>> @@ -1242,8 +1242,6 @@ bool msm_edp_ctrl_panel_connected(struct edp_ctrl
>> *ctrl)
>>   int msm_edp_ctrl_get_panel_info(struct edp_ctrl *ctrl,
>>                  struct drm_connector *connector, struct edid **edid)
>>   {
>> -       int ret = 0;
>> -
>>          mutex_lock(&ctrl->dev_mutex);
>>   
>>          if (ctrl->edid) {
>> @@ -1278,7 +1276,7 @@ int msm_edp_ctrl_get_panel_info(struct edp_ctrl *ctrl,
>>          }
>>   unlock_ret:
>>          mutex_unlock(&ctrl->dev_mutex);
>> -       return ret;
>> +       return 0;
>>   }
>>   
>>   int msm_edp_ctrl_timing_cfg(struct edp_ctrl *ctrl,
> 


-- 
With best wishes
Dmitry

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] drm/msm: remove unneeded variable
  2021-09-03 18:31   ` Dmitry Baryshkov
@ 2021-09-03 18:40     ` Lyude Paul
  0 siblings, 0 replies; 5+ messages in thread
From: Lyude Paul @ 2021-09-03 18:40 UTC (permalink / raw)
  To: Dmitry Baryshkov, cgel.zte, robdclark
  Cc: sean, airlied, daniel, airlied, laurent.pinchart, chi.minghao,
	treding, linux-arm-msm, dri-devel, freedreno, linux-kernel,
	Zeal Robot

On Fri, 2021-09-03 at 21:31 +0300, Dmitry Baryshkov wrote:
> On 02/09/2021 21:40, Lyude Paul wrote:
> > Reviewed-by: Lyude Paul <lyude@redhat.com>
> > 
> > Do you need me to push this?
> 
> We'd pick this up through the msm tree.

ah-totally forgot msm had their own tree and didn't go through drm-misc-next.
Thanks!

> 
> > 
> > On Tue, 2021-08-31 at 04:51 -0700, cgel.zte@gmail.com wrote:
> > > From: Chi Minghao <chi.minghao@zte.com.cn>
> > > 
> > > Fix the following coccicheck REVIEW:
> > > ./drivers/gpu/drm/msm/edp/edp_ctrl.c:1245:5-8 Unneeded variable
> > > 
> > > Reported-by: Zeal Robot <zealci@zte.com.cn>
> > > Signed-off-by: Chi Minghao <chi.minghao@zte.com.cn>
> > > ---
> > >   drivers/gpu/drm/msm/edp/edp_ctrl.c | 4 +---
> > >   1 file changed, 1 insertion(+), 3 deletions(-)
> > > 
> > > diff --git a/drivers/gpu/drm/msm/edp/edp_ctrl.c
> > > b/drivers/gpu/drm/msm/edp/edp_ctrl.c
> > > index 4fb397ee7c84..3610e26e62fa 100644
> > > --- a/drivers/gpu/drm/msm/edp/edp_ctrl.c
> > > +++ b/drivers/gpu/drm/msm/edp/edp_ctrl.c
> > > @@ -1242,8 +1242,6 @@ bool msm_edp_ctrl_panel_connected(struct edp_ctrl
> > > *ctrl)
> > >   int msm_edp_ctrl_get_panel_info(struct edp_ctrl *ctrl,
> > >                  struct drm_connector *connector, struct edid **edid)
> > >   {
> > > -       int ret = 0;
> > > -
> > >          mutex_lock(&ctrl->dev_mutex);
> > >   
> > >          if (ctrl->edid) {
> > > @@ -1278,7 +1276,7 @@ int msm_edp_ctrl_get_panel_info(struct edp_ctrl
> > > *ctrl,
> > >          }
> > >   unlock_ret:
> > >          mutex_unlock(&ctrl->dev_mutex);
> > > -       return ret;
> > > +       return 0;
> > >   }
> > >   
> > >   int msm_edp_ctrl_timing_cfg(struct edp_ctrl *ctrl,
> > 
> 
> 

-- 
Cheers,
 Lyude Paul (she/her)
 Software Engineer at Red Hat


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH] drm/msm: remove unneeded variable
  2021-08-31 11:51 [PATCH] drm/msm: remove unneeded variable cgel.zte
  2021-09-02 18:40 ` Lyude Paul
@ 2021-09-03 18:51 ` Dmitry Baryshkov
  1 sibling, 0 replies; 5+ messages in thread
From: Dmitry Baryshkov @ 2021-09-03 18:51 UTC (permalink / raw)
  To: cgel.zte, robdclark
  Cc: sean, airlied, daniel, lyude, airlied, laurent.pinchart,
	chi.minghao, treding, linux-arm-msm, dri-devel, freedreno,
	linux-kernel, Zeal Robot, Alexey Minnekhanov, Brian Masney

On 31/08/2021 14:51, cgel.zte@gmail.com wrote:
> From: Chi Minghao <chi.minghao@zte.com.cn>
> 
> Fix the following coccicheck REVIEW:
> ./drivers/gpu/drm/msm/edp/edp_ctrl.c:1245:5-8 Unneeded variable
> 
> Reported-by: Zeal Robot <zealci@zte.com.cn>
> Signed-off-by: Chi Minghao <chi.minghao@zte.com.cn>

Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>

Glancing on msm/edp, as it was never supported by the in-kernel dts I 
wonder: maybe we should drop it completely? If the need arises the 
removal can be reverted anytime.

Does anybody hacking 8084/8074/8974 support has eDP port access?

> ---
>   drivers/gpu/drm/msm/edp/edp_ctrl.c | 4 +---
>   1 file changed, 1 insertion(+), 3 deletions(-)
> 
> diff --git a/drivers/gpu/drm/msm/edp/edp_ctrl.c b/drivers/gpu/drm/msm/edp/edp_ctrl.c
> index 4fb397ee7c84..3610e26e62fa 100644
> --- a/drivers/gpu/drm/msm/edp/edp_ctrl.c
> +++ b/drivers/gpu/drm/msm/edp/edp_ctrl.c
> @@ -1242,8 +1242,6 @@ bool msm_edp_ctrl_panel_connected(struct edp_ctrl *ctrl)
>   int msm_edp_ctrl_get_panel_info(struct edp_ctrl *ctrl,
>   		struct drm_connector *connector, struct edid **edid)
>   {
> -	int ret = 0;
> -
>   	mutex_lock(&ctrl->dev_mutex);
>   
>   	if (ctrl->edid) {
> @@ -1278,7 +1276,7 @@ int msm_edp_ctrl_get_panel_info(struct edp_ctrl *ctrl,
>   	}
>   unlock_ret:
>   	mutex_unlock(&ctrl->dev_mutex);
> -	return ret;
> +	return 0;
>   }
>   
>   int msm_edp_ctrl_timing_cfg(struct edp_ctrl *ctrl,
> 


-- 
With best wishes
Dmitry

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2021-09-03 18:51 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-08-31 11:51 [PATCH] drm/msm: remove unneeded variable cgel.zte
2021-09-02 18:40 ` Lyude Paul
2021-09-03 18:31   ` Dmitry Baryshkov
2021-09-03 18:40     ` Lyude Paul
2021-09-03 18:51 ` Dmitry Baryshkov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).