Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp1738991pxk; Sat, 19 Sep 2020 00:15:56 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzM/SzvS3lwZlnwQc2AGW0r6Pj7uYcOvKiOgcfStMRHsh36w4L47l1w03vPlwskgcR5C8zC X-Received: by 2002:a17:906:3aca:: with SMTP id z10mr27703968ejd.419.1600499756754; Sat, 19 Sep 2020 00:15:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1600499756; cv=none; d=google.com; s=arc-20160816; b=irfRC6c8MYJT67UGnkg/dbjP8z5FhEX5D8MetgJwcZTzTqR2aRIFzBlhTQwNWJrj73 Ie8Q91RXWKzXSTZ6/qjSoSCOVFFnT0LSq/Uvakx6Ywm1z3fJpRJd86pXEqqVoLL+WX8J mTrYjBiJPChBuOwxaLP+o1zCMm7asUdcIjvhV2bVTs/SsvMSMGD6A5kqC9if1GoFjf33 gc8k3kR4jPX6FZeQ+CC6++e6u7eziJWNbYEIeSPEUn3mq3kPUZ7Bv0pBdPJ1SH++xQco gM3cmB/NVuHWGP4E/sCB8wZFc146QdB8c0ELghaNkqS3Ch/pfBUM5hghYtlQqCFxxlFS iCiA== 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=JQVmwrckHhsN+Y9Kf4emcHuuA880i9/2ThoZ1H1dsxo=; b=GwDdwUHF7E3A+PIjfZVRmHpxblgfsDveFTP0wi+j4rLDsqQni12glRFK4TNKq7JLt/ z1coUpVI4kb1DvZnr8C0NTVrrH248OUSeZUfHd7hA44e3uttluWyRR6g6HM1wOstJlRv l3HEQKTT07dSLjaDY/DEXQ/0vXmfJVXGweYd/LeSYLokRSNEHiheEfbI9WCGIR0X5+fd V5mGqI24lA5AXIe6qoLdp5YpjSyMeUR73S2RvBMaElfsLE7xcLs3VsE1EQbIs8BSOGbW YwchdzJCKizaGnJmrYBwC85vu5495mE2bvT9i7dQM04m7LoQekRpABMBnEf0sZ9WLuKR lYsw== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id pw5si3865367ejb.513.2020.09.19.00.15.33; Sat, 19 Sep 2020 00:15:56 -0700 (PDT) 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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726255AbgISHMW (ORCPT + 99 others); Sat, 19 Sep 2020 03:12:22 -0400 Received: from szxga04-in.huawei.com ([45.249.212.190]:13327 "EHLO huawei.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726054AbgISHMW (ORCPT ); Sat, 19 Sep 2020 03:12:22 -0400 Received: from DGGEMS410-HUB.china.huawei.com (unknown [172.30.72.58]) by Forcepoint Email with ESMTP id 064361527795F6012CE4; Sat, 19 Sep 2020 15:12:16 +0800 (CST) Received: from localhost.localdomain.localdomain (10.175.113.25) by DGGEMS410-HUB.china.huawei.com (10.3.19.210) with Microsoft SMTP Server id 14.3.487.0; Sat, 19 Sep 2020 15:12:07 +0800 From: Jing Xiangfeng To: , , CC: , , , Subject: [PATCH] KVM: PPC: Book3S: Remove redundant initialization of variable ret Date: Sat, 19 Sep 2020 15:12:30 +0800 Message-ID: <20200919071230.125798-1-jingxiangfeng@huawei.com> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Content-Transfer-Encoding: 7BIT Content-Type: text/plain; charset=US-ASCII X-Originating-IP: [10.175.113.25] X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The variable ret is being initialized with '-ENOMEM' that is meaningless. So remove it. Signed-off-by: Jing Xiangfeng --- arch/powerpc/kvm/book3s_64_vio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/powerpc/kvm/book3s_64_vio.c b/arch/powerpc/kvm/book3s_64_vio.c index 1a529df0ab44..b277a75cd1be 100644 --- a/arch/powerpc/kvm/book3s_64_vio.c +++ b/arch/powerpc/kvm/book3s_64_vio.c @@ -283,7 +283,7 @@ long kvm_vm_ioctl_create_spapr_tce(struct kvm *kvm, struct kvmppc_spapr_tce_table *siter; struct mm_struct *mm = kvm->mm; unsigned long npages, size = args->size; - int ret = -ENOMEM; + int ret; if (!args->size || args->page_shift < 12 || args->page_shift > 34 || (args->offset + args->size > (ULLONG_MAX >> args->page_shift))) -- 2.17.1