Received: by 2002:a25:824b:0:0:0:0:0 with SMTP id d11csp821147ybn; Wed, 2 Oct 2019 06:45:54 -0700 (PDT) X-Google-Smtp-Source: APXvYqyUECF2hqnMlXOwQwwO8O1o2tdaX24zxstwQcZRS9jUdyPRCVzKj2apsUSm3T2JCIyvkgrl X-Received: by 2002:a17:906:5584:: with SMTP id y4mr3104023ejp.89.1570023954173; Wed, 02 Oct 2019 06:45:54 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1570023954; cv=none; d=google.com; s=arc-20160816; b=W4rk19nwrhQaaRZfLj6vida29Q3O8Cl5bqqvVvPsoSMb88Iw+RXqxh00k+4WOy1teq +HRUxmNEQepZ+DJZ9p9333HeUFzZVe0O6ePI7G/HfVf1sgmbV5Y8YxDIi3R9PXKJHS2s rcyoipA/RoCBf/3hxCKcHbrh+6zpOdW44ew99N6DKOqCFYUYL80lvzWgsu2cW2W6UpMr NEZkWBy15J7mDHj3n37iACx5WvSuEF3MQIG1X9Jxz75MNkRnlSD7BerMzYDQNrYGTPi3 a6m347ls8ev8s+pjiEXZUBq/X41owlMj4tdqdXlrAfDdBX9McHNTnTtHmShtplFF+Thg 1jKQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=7C/lmvhnOK2ftbFYct5zRz8/v/Ze5kOZrnGinFzRgjI=; b=IpKXqMHY6Fw7EGTUTq1/8AEJfprxMwxS7dI5xPDGBDzFddQ/pyBHgTH5WlUxEl5tB7 qIK0EEuH4+vMPf5p9Dlwf2kJfYbDenN0aw7B9EaCHRbid6bsv3/lo56Qh1lhP9NGOudA 8z+p6TMu/XHcKTXugxR8B+8/wdYXrCB32oS23bhNR9SHBzPNoUsXS0wWAP5Xd/6amO31 Uj1Yh+5Jg0Ktmsf2BbMkuEINZb9yJJVmKs2nbbmBcWd1MjLt0EmxjvPJGZ72VyaS03dn junK1MTubhA6KXTHegtyDRRD8JVam7nAzRK5CMH60/MasbnzT5vYUXbdiZxhS2lzhh1b pHIA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b="EmzgMvl/"; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id p14si12896422eda.411.2019.10.02.06.45.30; Wed, 02 Oct 2019 06:45:54 -0700 (PDT) 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=@gmail.com header.s=20161025 header.b="EmzgMvl/"; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727348AbfJBNjn (ORCPT + 99 others); Wed, 2 Oct 2019 09:39:43 -0400 Received: from mail-wm1-f65.google.com ([209.85.128.65]:52019 "EHLO mail-wm1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726179AbfJBNjm (ORCPT ); Wed, 2 Oct 2019 09:39:42 -0400 Received: by mail-wm1-f65.google.com with SMTP id 7so7262063wme.1 for ; Wed, 02 Oct 2019 06:39:42 -0700 (PDT) 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:content-transfer-encoding; bh=7C/lmvhnOK2ftbFYct5zRz8/v/Ze5kOZrnGinFzRgjI=; b=EmzgMvl/cYe7h2v3GRBOlUfZcm7b3Blw3Q6HGG1ZYwjZZjOM7qquPWWzUP4IIpRNuK x+OZTSIigZUvASgyv6pKxtCEp1TiiK6+tCqouiYPc5eKthuuiPBxg7+tWs0ByTx3iQ0x u6HHGYdd25KkRi2jYBZW0lK37XvFT9vLNeqdM7lXe1grBO7JdGhu1h5Dim1I+xr+LvGX WkfXB23EDKqMmy9YyooyQ+ixCwHfUwbXcedn54zJ7ovCteYTMdeBNKrluLQVjCEU7Eic v4t1xqdOyBtpaLbJCfeYGfdBgRoYybC+UaFGQqzzwbswCz8HniR3AKU1AWRj+UkIfonZ j0yQ== 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:content-transfer-encoding; bh=7C/lmvhnOK2ftbFYct5zRz8/v/Ze5kOZrnGinFzRgjI=; b=DBLSUIKSsc6AeBSF3sZWyKgNR3HslTNLKYGIFuMDOUH+4q0PlxHX6dG4x41yKOq5Me dO0qqEbyQ0bhu4MbSIdBnefOYRH+5AghIGufMgcc32ANkReZ/BBiKE2W/SGQlcQkwmjM FV1exFInvDm3TUq1dk3xiWpPdsSVxI+RWFCKiypwV+pL0rf5cz5Mgz7+Tz6gwwSkrj9H R3s2p54M0Pv2DzpsMBEP9VYkzZ/cZIEI76CV+i78QC6CvPi+6zPMUYS5HfB0W26ubgYT 5D19gyxcQonvYRf8lI4PrJ+uCmXsYeNdIM0hI7S8LastzlwryXeVF68JXHiZJY7bOblf 7/hQ== X-Gm-Message-State: APjAAAXaqBFyuu1bf9cb5WfnTYMjK89J+V1KjONSacu57XJj5R/Kdof5 Xyv/TM24vz9uO7Nfhwkpje/+WdOh9qJd22AGow81HA== X-Received: by 2002:a05:600c:54a:: with SMTP id k10mr3134474wmc.127.1570023581249; Wed, 02 Oct 2019 06:39:41 -0700 (PDT) MIME-Version: 1.0 References: <20191002051759.GA161133@LGEARND20B15> In-Reply-To: <20191002051759.GA161133@LGEARND20B15> From: Alex Deucher Date: Wed, 2 Oct 2019 09:39:28 -0400 Message-ID: Subject: Re: [PATCH] drm/amdgpu: Drop unused variable and statement To: Austin Kim Cc: "Deucher, Alexander" , "Quan, Evan" , Christian Koenig , Chunming Zhou , Dave Airlie , Daniel Vetter , Maling list - DRI developers , amd-gfx list , LKML Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Oct 2, 2019 at 3:19 AM Austin Kim wrote: > > Even though 'smu8_smu' is declared, it is not used after below statement. > > smu8_smu =3D hwmgr->smu_backend; > > So 'unused variable' could be safely removed > to stop warning message as below: > > drivers/gpu/drm/amd/amdgpu/../powerplay/smumgr/smu8_smumgr.c:180:22: > warning: variable =E2=80=98smu8_smu=E2=80=99 set but not used > [-Wunused-but-set-variable] > > struct smu8_smumgr *smu8_smu; > ^ > Signed-off-by: Austin Kim Applied. Thanks! Alex > --- > drivers/gpu/drm/amd/powerplay/smumgr/smu8_smumgr.c | 2 -- > 1 file changed, 2 deletions(-) > > diff --git a/drivers/gpu/drm/amd/powerplay/smumgr/smu8_smumgr.c b/drivers= /gpu/drm/amd/powerplay/smumgr/smu8_smumgr.c > index 4728aa2..7dca04a 100644 > --- a/drivers/gpu/drm/amd/powerplay/smumgr/smu8_smumgr.c > +++ b/drivers/gpu/drm/amd/powerplay/smumgr/smu8_smumgr.c > @@ -177,12 +177,10 @@ static int smu8_load_mec_firmware(struct pp_hwmgr *= hwmgr) > uint32_t tmp; > int ret =3D 0; > struct cgs_firmware_info info =3D {0}; > - struct smu8_smumgr *smu8_smu; > > if (hwmgr =3D=3D NULL || hwmgr->device =3D=3D NULL) > return -EINVAL; > > - smu8_smu =3D hwmgr->smu_backend; > ret =3D cgs_get_firmware_info(hwmgr->device, > CGS_UCODE_ID_CP_MEC, &inf= o); > > -- > 2.6.2 > > _______________________________________________ > amd-gfx mailing list > amd-gfx@lists.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/amd-gfx