Received: by 2002:a25:1506:0:0:0:0:0 with SMTP id 6csp2051405ybv; Fri, 14 Feb 2020 10:30:11 -0800 (PST) X-Google-Smtp-Source: APXvYqw20qnHJfi4tz3fSicF1C4dAh+3slZig0BaxR/EtOFfSeW/U9zlekXHEJlMOfOvvbx0d72T X-Received: by 2002:a05:6808:8cd:: with SMTP id k13mr2882921oij.4.1581705011591; Fri, 14 Feb 2020 10:30:11 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1581705011; cv=pass; d=google.com; s=arc-20160816; b=LMgRo3QsYYlMpIzu4VdpZPPmEUKAVWfz3OyoZRnk9kfIKVd/FzGTzIuh08RLZOQgpo qN6YJUa+oVNOqgPjCSsaMCguW7qxAcEMNKdWmIz9xRqBiqhhWAxIXYsammYa/ByQHG90 tdm5svuVzFOwbIwR/xtV4hT73MrDQy+V01YFPCGkxL1Oa86Pyxo874kCzPvJif9Yh+/x b9d42iuXd32eNfdpvuVe5L18+3L5HfUkHKic11O2Ms94OP6INDhEIYLoMCXD+oD9piTG ifJLUuOX45zqCr/whTiSa2BcYr3ze9cPvK2GQ4+okUfas811vcO8HfUoYa5WQVSJd6L6 AcvQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:content-transfer-encoding :content-language:accept-language:in-reply-to:references:message-id :date:thread-index:thread-topic:subject:cc:to:from:dkim-signature; bh=Orn0aJH5F+MQm92Avsdy56sOSPhcSt+laqHLN6njMk4=; b=ji6Mkpo9VT6BKj4Oe0W+4a1Gi5naaVn9DNjz4ygmCfGFtyAq2Gl3P7JxlZkGQ5ej/C Kpm/vpN1Gc/jAJTHkcDqyeQauJFjXvqm0JwQYC3m30KQ5Tc8BxwfWPQBunMWQTUbjdDD ZeNb8vGIWcnWbGixpwviBdstrglv3VEr9WzKgd+RtTdWQLA7j2hJTo17LpCYzXjAmyPk zzH0esVR2WBflWoeYQFQVEN9IE7P38qAOXr9brkeGC6fVSazIOKpUsEQZaGFA8sSRTOh 8YTlUl0lxyPYma06Ui3DPg0FkrKIfeAxqUjUZT3TTFIhziCdPa824DHCE/Lk2GcevVuF kx5w== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@amdcloud.onmicrosoft.com header.s=selector2-amdcloud-onmicrosoft-com header.b=diFxGgnV; arc=pass (i=1 spf=pass spfdomain=amd.com dkim=pass dkdomain=amd.com dmarc=pass fromdomain=amd.com); spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id u132si3118022oie.250.2020.02.14.10.29.58; Fri, 14 Feb 2020 10:30:11 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@amdcloud.onmicrosoft.com header.s=selector2-amdcloud-onmicrosoft-com header.b=diFxGgnV; arc=pass (i=1 spf=pass spfdomain=amd.com dkim=pass dkdomain=amd.com dmarc=pass fromdomain=amd.com); spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729591AbgBNS3r (ORCPT + 99 others); Fri, 14 Feb 2020 13:29:47 -0500 Received: from mail-dm6nam10on2073.outbound.protection.outlook.com ([40.107.93.73]:6051 "EHLO NAM10-DM6-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1729542AbgBNS3q (ORCPT ); Fri, 14 Feb 2020 13:29:46 -0500 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=fZIStkgm7+NSeZD1UbJ8Ks/Ylg1v+yxAa9m5171s/A19vwzxZUM0gOsdPgQO5mAdHAZLCgAdCOEHdTwIMZtltRHFmTudY4A31NNr+QXuY/5H62VyA+HcCu1Lj33mFFHN4ueLzhR2NFBWAVpYcUz0sTpouHpkojvg19nKWRmhIq146R3Fu+QFSaHAAmClmOm7lxWDfCoju1vueHNYWcGaxXa0ASTmz0edO/g+qdGq5EaMczSMDT1VQkeFL22rV+dhUcPlJ0ICdSF2BJcT0xQNTI3Qb4ZKZT0tL7fVRUWM6sn5b82YK8/ChvmHYfpOkm3EV2FjXu7Yb8n+x1titQN31A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=Orn0aJH5F+MQm92Avsdy56sOSPhcSt+laqHLN6njMk4=; b=og0tHHzi/94+9Q2n+6LUvCGaMRseJfHzc2DxTAQVEg24H/CxBzTSYRszSVdNXmv9vpscwZdzVQD6y4RP1ybjg3zmdphPPTpwV4oBdKgyQVowml6puNaeXnYCQwzj4m+WO3MoKvDNCqFU+1lXs8saHsNC0h24vqMgL8ttTM8TuYK0+h0/+tGF/pNIsNOHLZg/PgH40KkMFXvJLQNITCsBEjuWP6pWD4zchK+jOa/UV9kvdyh1Qz3oZY+sYEXWZYaHdUmkbM1Zy/NgJpCh70MskuhNOfkUh/+Hri9FvqdKIJEKdcFbLIhd6jIu0Jc35WfXL21ylqveN38jeZk7AotEoA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=amd.com; dmarc=pass action=none header.from=amd.com; dkim=pass header.d=amd.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amdcloud.onmicrosoft.com; s=selector2-amdcloud-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=Orn0aJH5F+MQm92Avsdy56sOSPhcSt+laqHLN6njMk4=; b=diFxGgnVmnsLEhi3r9Mw4ggMV8rCONur8Pczs/3hRfkEmtbC7lYf5tK0pupVlAAp/1NBsb5ALUXaymiwk+4GN8Ab5aog+XhosN9ilBatdxXoAy7RSuhK2RPsLw3Vc9D9zJWQlSnrt6LE/rj+rWZGDoyiSkQv8OVcqt1vpSFEp6A= Received: from DM5PR1201MB2554.namprd12.prod.outlook.com (10.172.92.14) by DM5PR1201MB0201.namprd12.prod.outlook.com (10.174.109.149) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2729.22; Fri, 14 Feb 2020 18:29:44 +0000 Received: from DM5PR1201MB2554.namprd12.prod.outlook.com ([fe80::c4c:bafd:5833:2b51]) by DM5PR1201MB2554.namprd12.prod.outlook.com ([fe80::c4c:bafd:5833:2b51%5]) with mapi id 15.20.2729.025; Fri, 14 Feb 2020 18:29:44 +0000 From: "Liu, Zhan" To: 'Nathan Chancellor' , "Wentland, Harry" , "Li, Sun peng (Leo)" , "Deucher, Alexander" , "Koenig, Christian" , "Zhou, David(ChunMing)" CC: "'clang-built-linux@googlegroups.com'" , "'dri-devel@lists.freedesktop.org'" , "'amd-gfx@lists.freedesktop.org'" , "'linux-kernel@vger.kernel.org'" Subject: RE: [PATCH] drm/amd/display: Don't take the address of skip_scdc_overwrite in dc_link_detect_helper Thread-Topic: [PATCH] drm/amd/display: Don't take the address of skip_scdc_overwrite in dc_link_detect_helper Thread-Index: AQHV4w3nrdEjDXoM7k+tBRh46kQ/F6ga2T+AgAAp02A= Date: Fri, 14 Feb 2020 18:29:44 +0000 Message-ID: References: <20200214062950.14151-1-natechancellor@gmail.com> In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: spf=none (sender IP is ) smtp.mailfrom=Zhan.Liu@amd.com; x-originating-ip: [165.204.55.250] x-ms-publictraffictype: Email x-ms-office365-filtering-ht: Tenant x-ms-office365-filtering-correlation-id: bd2e77cf-6706-4148-79cd-08d7b17bdd35 x-ms-traffictypediagnostic: DM5PR1201MB0201:|DM5PR1201MB0201: x-ms-exchange-transport-forked: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:5797; x-forefront-prvs: 03137AC81E x-forefront-antispam-report: SFV:NSPM;SFS:(10009020)(4636009)(39860400002)(136003)(376002)(346002)(366004)(396003)(199004)(189003)(8676002)(8936002)(55016002)(2940100002)(64756008)(966005)(4326008)(9686003)(478600001)(66946007)(66556008)(66446008)(66476007)(316002)(6506007)(53546011)(54906003)(110136005)(76116006)(186003)(2906002)(33656002)(71200400001)(81166006)(81156014)(86362001)(52536014)(6636002)(26005)(7696005)(5660300002)(921003)(1121003);DIR:OUT;SFP:1101;SCL:1;SRVR:DM5PR1201MB0201;H:DM5PR1201MB2554.namprd12.prod.outlook.com;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;A:1;MX:1; received-spf: None (protection.outlook.com: amd.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: 7sDVZ02PuuwGX7aDgZlZ6B3poXoAnL2A14wCY7T+dSIzNw4Df4O63+f0Rrkml7jtB+8pOjMZMUQ1McwwinUyEljytviiUwZQrqWxPxXhhTOGuFb50Y8ef9nTZ4O3KGyeGglw8lSg2/aTfMBo0aPnDovS7U7XxxiTxZ1F15HJ2396q8Brz1eZRST2YCtb5sRNcrfaMkTTnMdOFiC5n/2GY3Rkx2gmsZFEtkcJr62Z4yOUC2k7J8mXoIjMxc5GzFmJ0hTWoveiYA4skdRA95pHfe88wfseirFzULJrCDdzKi8DXwgyhPRWH9FuoyGZvcH0izPj0BqAhdPdcdsa2OUYUf9eqfjO7lzgUxDBT2KZ2sIIxxVZLRVstahlXwcRqvZGfJb7gmz45RvYGCIlgnb539Zkgh8UE/ClXzHJ2sbwe9ZZH3w2yK+gq5MVa0Uu3AflhBW/72UXYW/MIhIgVU43JuodRRWXvMx+OpvUDaRRQKQnnQQ3UvRRxXO4CNcDbX63t5GbQOBfHsJmQtf4MBoUo/F4H2HbzfKm9E8WojyI+H1i37ZJrUTWNPn5x5XfP8cg8MTdo2CZPJSQw4FKctecsw== x-ms-exchange-antispam-messagedata: xjn0WItcHzZnTMEHH+KN4VkzSZBflH0PcBTm36VFQo0/lY9s3ql+MZtVEGNAuTJR7bUNxX9nPkfZZPi5wKFO+f3vwyoQmtkrVOCyZeRFQ95SdxEwtc+ugjp5frMZsUb6qbitgijyIROz0JY/e6WLQw== Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-Network-Message-Id: bd2e77cf-6706-4148-79cd-08d7b17bdd35 X-MS-Exchange-CrossTenant-originalarrivaltime: 14 Feb 2020 18:29:44.5518 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: 4AHzmMHNeUNwGeuPi6MIDpnW4J9PRsX4FpGoGvpQHu628TPj+hfd+c5UZoEyi5YU X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR1201MB0201 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > -----Original Message----- > From: Liu, Zhan > Sent: 2020/February/14, Friday 11:01 AM > To: Nathan Chancellor ; Wentland, Harry > ; Li, Sun peng (Leo) ; > Deucher, Alexander ; Koenig, Christian > ; Zhou, David(ChunMing) > > Cc: clang-built-linux@googlegroups.com; dri-devel@lists.freedesktop.org; > amd-gfx@lists.freedesktop.org; linux-kernel@vger.kernel.org > Subject: RE: [PATCH] drm/amd/display: Don't take the address of > skip_scdc_overwrite in dc_link_detect_helper >=20 >=20 >=20 > > -----Original Message----- > > From: dri-devel On Behalf Of > > Nathan Chancellor > > Sent: 2020/February/14, Friday 1:30 AM > > To: Wentland, Harry ; Li, Sun peng (Leo) > > ; Deucher, Alexander > ; > > Koenig, Christian ; Zhou, David(ChunMing) > > > > Cc: clang-built-linux@googlegroups.com; Nathan Chancellor > > ; dri-devel@lists.freedesktop.org; amd- > > gfx@lists.freedesktop.org; linux-kernel@vger.kernel.org > > Subject: [PATCH] drm/amd/display: Don't take the address of > > skip_scdc_overwrite in dc_link_detect_helper > > > > Clang warns: > > > > ../drivers/gpu/drm/amd/amdgpu/../display/dc/core/dc_link.c:980:36: > > warning: address of 'sink->edid_caps.panel_patch.skip_scdc_overwrite' > > will always evaluate to 'true' [-Wpointer-bool-conversion] > > if (&sink->edid_caps.panel_patch.skip_scdc_overwrite) > > ~~ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~ > > 1 warning generated. > > > > This is probably not what was intended so remove the address of > > operator, which matches how skip_scdc_overwrite is handled in the rest = of > the driver. > > > > While we're here, drop an extra newline after this if block. > > > > Fixes: a760fc1bff03 ("drm/amd/display: add monitor patch to disable > > SCDC > > read/write") > > Link: > > https://github.com/ClangBuiltLinux/linux/issues/879 > > Signed-off-by: Nathan Chancellor >=20 > Thank you! > Reviewed-by: Zhan Liu Also applied, thanks! Zhan >=20 > > --- > > > > As an aside, I don't see skip_scdc_overwrite assigned a value > > anywhere, is this working as intended? > > > > drivers/gpu/drm/amd/display/dc/core/dc_link.c | 3 +-- > > 1 file changed, 1 insertion(+), 2 deletions(-) > > > > diff --git a/drivers/gpu/drm/amd/display/dc/core/dc_link.c > > b/drivers/gpu/drm/amd/display/dc/core/dc_link.c > > index 24d99849be5e..a3bfa05c545e 100644 > > --- a/drivers/gpu/drm/amd/display/dc/core/dc_link.c > > +++ b/drivers/gpu/drm/amd/display/dc/core/dc_link.c > > @@ -977,10 +977,9 @@ static bool dc_link_detect_helper(struct dc_link > > *link, > > if ((prev_sink !=3D NULL) && ((edid_status =3D=3D EDID_THE_SAME) > > || (edid_status =3D=3D EDID_OK))) > > same_edid =3D is_same_edid(&prev_sink->dc_edid, > &sink->dc_edid); > > > > - if (&sink->edid_caps.panel_patch.skip_scdc_overwrite) > > + if (sink->edid_caps.panel_patch.skip_scdc_overwrite) > > link->ctx->dc->debug.hdmi20_disable =3D true; > > > > - > > if (link->connector_signal =3D=3D SIGNAL_TYPE_DISPLAY_PORT > && > > sink_caps.transaction_type =3D=3D > > DDC_TRANSACTION_TYPE_I2C_OVER_AUX) { > > /* > > -- > > 2.25.0 > > > > _______________________________________________ > > dri-devel mailing list > > dri-devel@lists.freedesktop.org