From nobody Tue Feb 10 05:09:50 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1579795973; cv=none; d=zohomail.com; s=zohoarc; b=INj9gbu5wgwB+VfZHc98NHWDCbdQSGiAgaTQJqoB1Z/nJQR4/arGVXsvtGlJRkCTX0Lx2um8iAp77J3jhR4iUyaoWwz1Hw7yaWYNTaho/UqI3dhVxA5+0E8/RAzbbeM6gbI0GrNVKRwftXQ8pq/OdzFCXYZsdjor1vbyhYe8/L8= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1579795973; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=Ivjz8iFRMvc+SVdpsYBWr7dQMjtFmxs9hPvui4StZIM=; b=Bu6L6W2iDjnFg/5RkwGQjmxD+uJTFvUZ1iCdP+1crNhNdf4ZOs2r9mvVV61LxuPGC8UKuu9eN7nyOkwvM/lBUFWJllV2aNQX5gRQf3j5NWaLmUQ224JdgD0bEObVtpc+40WqealUSnKvHtBADyBNVMl5iAIubNmMqNDyqw92xgo= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=fail; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; dmarc=fail header.from= (p=none dis=none) header.from= Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1579795973533657.0532042906466; Thu, 23 Jan 2020 08:12:53 -0800 (PST) Received: from localhost ([::1]:60116 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iuf6C-0007Uq-0Q for importer@patchew.org; Thu, 23 Jan 2020 11:12:52 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:51531) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iucrT-00057E-Rx for qemu-devel@nongnu.org; Thu, 23 Jan 2020 08:49:32 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1iucrS-0003ZU-Rw for qemu-devel@nongnu.org; Thu, 23 Jan 2020 08:49:31 -0500 Received: from mail-wm1-x335.google.com ([2a00:1450:4864:20::335]:37077) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1iucrS-0003XL-Ko for qemu-devel@nongnu.org; Thu, 23 Jan 2020 08:49:30 -0500 Received: by mail-wm1-x335.google.com with SMTP id f129so2613150wmf.2 for ; Thu, 23 Jan 2020 05:49:30 -0800 (PST) Received: from 640k.localdomain.com ([93.56.166.5]) by smtp.gmail.com with ESMTPSA id s15sm3073171wrp.4.2020.01.23.05.49.28 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 23 Jan 2020 05:49:28 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=Ivjz8iFRMvc+SVdpsYBWr7dQMjtFmxs9hPvui4StZIM=; b=n8Q7bErZI9CmlPWMT/KqNpKwm4f6wNLx/I5raQ6DuS8QSxtjP1disioZ8VQ6mk74ta J/3HykrYEC0hObby+PKJ7x4OalAD8V89mjBP996lG7p3m+NNPpcAPT06Jf9YCj1o7qRX pVrh+iqjNicFLB3jS2mVKGtpHSwZ28OO9YaGxzmQuDBeoVOvkZjkeR8Izt8A4DjypKcd JnhJuSq/5YD7nHPZtsj7X4pvCqLQe7wgFSC1fYzc5FOfZeneO0BKz0vO09XuSCdp1mG0 /TOAORfBD/I2rddWZkNEHkmhONLkaq+/8CaSpz7BKRPhnY9+CJS0EgSBN2evX8bJmxma eiNA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=Ivjz8iFRMvc+SVdpsYBWr7dQMjtFmxs9hPvui4StZIM=; b=A6uXbQSL2T8Gh1KH6B1pvCjjhXiqxtk2kCvNQDXOsoUEtFTcrLeFPMaKzCwWGROB6P zcPNvXdQHxfMQ0GvNNGwY9nZtWvSahA0XrHGQWMvqOj4APDkdVLQviupSf1t6vPsigiX Ytx6zOpctysK3sNxc+Q/YVu8jHfQ/zgB/yOwtKYxEkOUgBa3sZVu4LYTdjRCwulicsvj fqrWiyLykvLOuBK6Pjqt+2Hw99ta+V2fII1DFgFp/DKHAXsOU0QtPYHAmSMOJfJspp+J g+lf5IOk5UJ+47LS08rsE9Do07ssD+LYuprTY12JBGxuIuC0AAG0/5nf7sqY3Tf0xt9i J9kQ== X-Gm-Message-State: APjAAAWvC5O9/qJwx1cTtoI89aFeQXa7eHjMiuLjPXVO+v5fMksU8iWk mI2fMAwgdHwR8kfTcGm86Wr2WhH8 X-Google-Smtp-Source: APXvYqxHdkDyTRvX6t4qjPGYoHgDv269GRN7RdA3ICvXT4bW+315NyDW3Zon+xgnq/G+wgfC3PvMXQ== X-Received: by 2002:a7b:c119:: with SMTP id w25mr3417363wmi.116.1579787369415; Thu, 23 Jan 2020 05:49:29 -0800 (PST) From: Paolo Bonzini To: qemu-devel@nongnu.org Subject: [PULL 25/59] hw/ppc/spapr_rtas: Remove local variable Date: Thu, 23 Jan 2020 14:48:28 +0100 Message-Id: <1579787342-27146-26-git-send-email-pbonzini@redhat.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1579787342-27146-1-git-send-email-pbonzini@redhat.com> References: <1579787342-27146-1-git-send-email-pbonzini@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::335 X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail-DKIM: fail (Header signature does not verify) From: Philippe Mathieu-Daud=C3=A9 We only access this variable in the RTAS_SYSPARM_SPLPAR_CHARACTERISTICS case. Use it in place and remove the local declaration. Suggested-by: Greg Kurz Signed-off-by: Philippe Mathieu-Daud=C3=A9 Message-Id: <20200121110349.25842-4-philmd@redhat.com> Signed-off-by: Paolo Bonzini --- hw/ppc/spapr_rtas.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/hw/ppc/spapr_rtas.c b/hw/ppc/spapr_rtas.c index 6f06e9d..85135e0 100644 --- a/hw/ppc/spapr_rtas.c +++ b/hw/ppc/spapr_rtas.c @@ -268,7 +268,6 @@ static void rtas_ibm_get_system_parameter(PowerPCCPU *c= pu, { PowerPCCPUClass *pcc =3D POWERPC_CPU_GET_CLASS(cpu); MachineState *ms =3D MACHINE(spapr); - unsigned int max_cpus =3D ms->smp.max_cpus; target_ulong parameter =3D rtas_ld(args, 0); target_ulong buffer =3D rtas_ld(args, 1); target_ulong length =3D rtas_ld(args, 2); @@ -280,10 +279,10 @@ static void rtas_ibm_get_system_parameter(PowerPCCPU = *cpu, "DesMem=3D%" PRIu64 "," "DesProcs=3D%d," "MaxPlatProcs=3D%d", - max_cpus, + ms->smp.max_cpus, ms->ram_size / MiB, ms->smp.cpus, - max_cpus); + ms->smp.max_cpus); if (pcc->n_host_threads > 0) { char *hostthr_val, *old =3D param_val; =20 --=20 1.8.3.1