Received: by 2002:a05:6359:c8b:b0:c7:702f:21d4 with SMTP id go11csp856433rwb; Fri, 23 Sep 2022 05:13:07 -0700 (PDT) X-Google-Smtp-Source: AMsMyM4qDoNFOTz/Y1zJLbStIeupFBGA/EYXmO5vXoHJuPi3CI7jllZ1tXOrdxVfsP5PnrzyeYQ4 X-Received: by 2002:a05:6402:400e:b0:44f:1b9d:9556 with SMTP id d14-20020a056402400e00b0044f1b9d9556mr8069401eda.208.1663935187194; Fri, 23 Sep 2022 05:13:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1663935187; cv=none; d=google.com; s=arc-20160816; b=H+cy96U4AUaPBqFBcpT6ead0fbRpbHRdCvcNYsBZYTfeiOlBUgML8YJ0fSfv2tRdoq 9nmP++Cd/vaKsbAZpV+UqYc/5jHYdN+2JeYFSWo4g4MDXsZmP//CjOeheTRBpD04w6cj vjzpqUk0E3gIcRaA1gcPq1RVL8D4VbdipvclgME4gLH5j+x6zsCU5CMDV0bemvjGJBw0 aUJ7EIz/KsCs1Tm1FzlTwpp82eHLsQhFFt07BSE9BHuqQMShMOuFuiVRuAg+xIHaYdpT xV39Rq9jNqKlB6WvJNbEXbvLqbVAtUuiFEl1J+g0ek7XldEqhVDVbkKYyGI4/eeJp6CY kh2Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=3btT2x0cH+HP6fYreU8XIOy9C4X/FOpu0OS528fAssc=; b=tc2GCTnwGAx7Xt6c5n6r2WuaJ67u1LFmHqOvzxkpeJv92pJi/V7XtUExOuyFtWzCs9 bijAqnivwVDl7+MsXayN/k19DRGxJCBzOlprgddZ8wmBm6RIFcLRCwt4DSQ6cwv8iaa7 d3BuBb6Zalx1wcn91OJQPBkh2jRt0SkeWgvf4x4zyKwK7B46dvCifvf80MqRTtMGKBnd aDXxqxsCKAMSDAuONVIVGeb2YOFRwIdc9lwc1eaNyUQwbEXeBHwNqzVwTMz745ecFDNq 3b54zgw43hYVJhy3Ywq7b+Ct+xev4We9wT8uGd2KtJiutR2Ah+05NPbtSxt/pzr99spX tIIg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id n13-20020aa7db4d000000b0044ecac7a710si6488156edt.65.2022.09.23.05.12.40; Fri, 23 Sep 2022 05:13:07 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231751AbiIWLgM (ORCPT + 99 others); Fri, 23 Sep 2022 07:36:12 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41166 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231221AbiIWLf6 (ORCPT ); Fri, 23 Sep 2022 07:35:58 -0400 Received: from szxga08-in.huawei.com (szxga08-in.huawei.com [45.249.212.255]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7269CC8416 for ; Fri, 23 Sep 2022 04:35:56 -0700 (PDT) Received: from dggemv704-chm.china.huawei.com (unknown [172.30.72.57]) by szxga08-in.huawei.com (SkyGuard) with ESMTP id 4MYqjs1c0Xz1P6sk; Fri, 23 Sep 2022 19:31:45 +0800 (CST) Received: from kwepemm600017.china.huawei.com (7.193.23.234) by dggemv704-chm.china.huawei.com (10.3.19.47) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.31; Fri, 23 Sep 2022 19:35:54 +0800 Received: from huawei.com (10.67.175.88) by kwepemm600017.china.huawei.com (7.193.23.234) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.31; Fri, 23 Sep 2022 19:35:53 +0800 From: Li Zetao To: , , , , , , , , CC: , Subject: [PATCH -next] x86/sev: Remove unused variable "err" in enforce_vmpl0() Date: Fri, 23 Sep 2022 11:32:09 +0000 Message-ID: <20220923113209.3046960-1-lizetao1@huawei.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 8bit X-Originating-IP: [10.67.175.88] X-ClientProxiedBy: dggems701-chm.china.huawei.com (10.3.19.178) To kwepemm600017.china.huawei.com (7.193.23.234) X-CFilter-Loop: Reflected X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Gcc report warning as follows: arch/x86/boot/compressed/sev.c: In function ‘enforce_vmpl0’: arch/x86/boot/compressed/sev.c:256:13: error: unused variable ‘err’ [-Werror=unused-variable] Fix it by removing the unused variable "err". Fixes: 81cc3df9a90e ("x86/sev: Check the VMPL level") Signed-off-by: Li Zetao --- arch/x86/boot/compressed/sev.c | 1 - 1 file changed, 1 deletion(-) diff --git a/arch/x86/boot/compressed/sev.c b/arch/x86/boot/compressed/sev.c index c93930d5ccbd..b9451761a69a 100644 --- a/arch/x86/boot/compressed/sev.c +++ b/arch/x86/boot/compressed/sev.c @@ -253,7 +253,6 @@ void do_boot_stage2_vc(struct pt_regs *regs, unsigned long exit_code) static void enforce_vmpl0(void) { u64 attrs; - int err; /* * RMPADJUST modifies RMP permissions of a lesser-privileged (numerically -- 2.34.1