mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Christian König" <christian.koenig@amd.com>
To: Jason Yan <yanaijie@huawei.com>,
	harry.wentland@amd.com, sunpeng.li@amd.com,
	alexander.deucher@amd.com, David1.Zhou@amd.com, airlied@linux.ie,
	daniel@ffwll.ch, amd-gfx@lists.freedesktop.org,
	dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] drm/amd/display: remove conversion to bool in dc_link_ddc.c
Date: Mon, 27 Apr 2020 10:03:23 +0200	[thread overview]
Message-ID: <d7546d27-a17f-8dcd-c396-79476a3972c1@amd.com> (raw)
In-Reply-To: <20200427063726.21363-1-yanaijie@huawei.com>

Am 27.04.20 um 08:37 schrieb Jason Yan:
> The '>' expression itself is bool, no need to convert it to bool again.
> This fixes the following coccicheck warning:
>
> drivers/gpu/drm/amd/display/dc/core/dc_link_ddc.c:602:28-33: WARNING:
> conversion to bool not needed here
>
> Signed-off-by: Jason Yan <yanaijie@huawei.com>

Reviewed-by: Christian König <christian.koenig@amd.com>

> ---
>   drivers/gpu/drm/amd/display/dc/core/dc_link_ddc.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/amd/display/dc/core/dc_link_ddc.c b/drivers/gpu/drm/amd/display/dc/core/dc_link_ddc.c
> index 256889eed93e..aefd29a440b5 100644
> --- a/drivers/gpu/drm/amd/display/dc/core/dc_link_ddc.c
> +++ b/drivers/gpu/drm/amd/display/dc/core/dc_link_ddc.c
> @@ -599,7 +599,7 @@ bool dal_ddc_submit_aux_command(struct ddc_service *ddc,
>   	do {
>   		struct aux_payload current_payload;
>   		bool is_end_of_payload = (retrieved + DEFAULT_AUX_MAX_DATA_SIZE) >
> -			payload->length ? true : false;
> +			payload->length;
>   
>   		current_payload.address = payload->address;
>   		current_payload.data = &payload->data[retrieved];


  reply	other threads:[~2020-04-27  8:03 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-27  6:37 Jason Yan
2020-04-27  8:03 ` Christian König [this message]
2020-04-27 19:33   ` Alex Deucher

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=d7546d27-a17f-8dcd-c396-79476a3972c1@amd.com \
    --to=christian.koenig@amd.com \
    --cc=David1.Zhou@amd.com \
    --cc=airlied@linux.ie \
    --cc=alexander.deucher@amd.com \
    --cc=amd-gfx@lists.freedesktop.org \
    --cc=daniel@ffwll.ch \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=harry.wentland@amd.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=sunpeng.li@amd.com \
    --cc=yanaijie@huawei.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®