Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp2089148pxb; Mon, 8 Mar 2021 13:58:11 -0800 (PST) X-Google-Smtp-Source: ABdhPJx8fHF7WPvA5s3LJ63DF7a5H/WPTc2+c4Kow6Zi0FqpffpClLv9ncRhNwh2haO2jYVKsixT X-Received: by 2002:a05:6402:254f:: with SMTP id l15mr646660edb.189.1615240691470; Mon, 08 Mar 2021 13:58:11 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1615240691; cv=none; d=google.com; s=arc-20160816; b=VPp0xuBjZcBusDQFXjVEAWg+BKpt5WxWl7g2qFKZwWC70PD4qcWCHQA39qLiNWjRl7 InqDnRkLinX8HN+slkw0/thXFmRHfQoTytwyH589edvwCWDlKRWE7RWhhlehavDpINZA FdX1aepzOh7uLJ/ltXeIVrWEpl8hmdkFf+jey9yfhQmjDAoimIhnD+NOfBgL39wKSoL1 r4uI88WDOkiDz0/r9tBnDuU1MUpH5ubjJJ/AWzLJVqZwpdpOZ9SyJu9sBObXZWqiFcyi sZnoN4A+r8se93FkG34xU3fznQjGQGRdrWOPL8l6l2J34WIYsnmiorrb0fw7I4ji2YJW UdkA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=uyJ0PeO5KwJeqSfUyZWIUqn/iwMU0KWoLqv+BcNnnbs=; b=bBIloDEdOS/rrOl7AZkMNKUQ17ZwBrtqKqt2xw0f9repdBf1bFFsVxfiL+jRt5PsTY ff1AuviAFhbJQAyk9eXTxNeswdj6mvydoob0mBDVYJs9jtqtRxdi5w39FDgLCe7A/V3G t7eJLgtcmjW/qJzUX+T6tjc4GC3miIIxcAdj9drm9KK3z3jUvOVcgYGLe8Wgq4BfxhUv UPRXeBMqxIVnircRf5OwLyex9WkyorDIAO7dp/p0Etc8xSJais5rFFgZJptzrRwN/Qjr 0C7FVheJIprsCxETipQ8Nv9EiFahhxjEY5Y3JKvA4Owbarx/xZUqnBkequtYQiYD7IiM Lh3Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=UQ10zTsp; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id e21si7384641edr.370.2021.03.08.13.57.49; Mon, 08 Mar 2021 13:58:11 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=UQ10zTsp; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231689AbhCHV4x (ORCPT + 99 others); Mon, 8 Mar 2021 16:56:53 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41636 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229740AbhCHV41 (ORCPT ); Mon, 8 Mar 2021 16:56:27 -0500 Received: from mail-oi1-x22b.google.com (mail-oi1-x22b.google.com [IPv6:2607:f8b0:4864:20::22b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A64A4C06174A for ; Mon, 8 Mar 2021 13:56:26 -0800 (PST) Received: by mail-oi1-x22b.google.com with SMTP id w195so6020410oif.11 for ; Mon, 08 Mar 2021 13:56:26 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=uyJ0PeO5KwJeqSfUyZWIUqn/iwMU0KWoLqv+BcNnnbs=; b=UQ10zTspdmlb5BBImKzv93z4b8rcgHoxxMXyDAGirJ6ZgQdlU3oCoy3/VlIySTVQ9G vKjr/FqjR7o+Yu8UECfsO2tAxBqkl1dd9NRaiC7d+XVJKftt981D7j+5kv4r9JGR6wb/ djLRjS5HT8gaALDGwT9XPp9wVxCKhh+4Pfex+porGxTetWm7f8cRKHM3jCVTrKFKv6sN ii2+saA/94KALMXo3L3S2sp749DJ7nxT9UAcXTSxmDiXrORdg20/aDFnjDEmIvsO73m5 kBEhlJw7H7aZ+W/xTqkG7te3ufg/mLpWyCpOTQ+BogUV6x80+Xosfo9US/SbB0xMwzHK BVQw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=uyJ0PeO5KwJeqSfUyZWIUqn/iwMU0KWoLqv+BcNnnbs=; b=attPaprazjz2TGVr45+jq69VfDDnGARD48QjC0gq9ge1Ll19sCtejfbMSYb3YTvaE5 C+pBLiFB8tNGL6DEWkFpTkjvuWe3xiendLqDZF0giweUe7Ko7C2nrQ2ouwxBqFiCD5tZ mGn94BaTHJyGwkmdKw1XgZSeHSaNzfzB5ImTxZWS0qpgPArenwIrIUw0agXJKRyK1E2l Mn2a39R3X56G5DJavztLWNnnbhLSkvWrjnOBqhJTBtIH9wMO6M1lby3WYDaAL18/KkJh /90TeRztnsjg2l2l1YW9bm7vzD6w+pZe5DBSq1HZNXyqm2ZOCQ6BaSfrON8Y92zU7hlW MS+Q== X-Gm-Message-State: AOAM532vNwxPdL/RJU+Iv0oBDCu23od5jZziQEpU7Hp2Vm0+69hEisA6 /kfqepor6bl/DbA3j3KhP8WoiKJWgd8nB4Kc8mw= X-Received: by 2002:a05:6808:f15:: with SMTP id m21mr696521oiw.123.1615240586175; Mon, 08 Mar 2021 13:56:26 -0800 (PST) MIME-Version: 1.0 References: <1615172407-4847-1-git-send-email-jiapeng.chong@linux.alibaba.com> In-Reply-To: <1615172407-4847-1-git-send-email-jiapeng.chong@linux.alibaba.com> From: Alex Deucher Date: Mon, 8 Mar 2021 16:56:15 -0500 Message-ID: Subject: Re: [PATCH] drm/amd/display: Remove unnecessary conversion to bool To: Jiapeng Chong Cc: "Wentland, Harry" , "Leo (Sunpeng) Li" , LKML , amd-gfx list , Dave Airlie , Maling list - DRI developers , "Deucher, Alexander" , Christian Koenig Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sun, Mar 7, 2021 at 10:00 PM Jiapeng Chong wrote: > > Fix the following coccicheck warnings: > > ./drivers/gpu/drm/amd/display/dc/core/dc_link_ddc.c:561:34-39: WARNING: > conversion to bool not needed here. > > Reported-by: Abaci Robot > Signed-off-by: Jiapeng Chong This patch was already applied. Alex > --- > 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 ae6484a..42a4177 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 > @@ -558,7 +558,7 @@ bool dal_ddc_service_query_ddc_data( > /* should not set mot (middle of transaction) to 0 > * if there are pending read payloads > */ > - payload.mot = read_size == 0 ? false : true; > + payload.mot = !(read_size == 0); > payload.length = write_size; > payload.data = write_buf; > > -- > 1.8.3.1 > > _______________________________________________ > dri-devel mailing list > dri-devel@lists.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/dri-devel