From patchwork Wed Feb 19 20:31:31 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sander Eikelenboom X-Patchwork-Id: 11392375 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 1ACA5924 for ; Wed, 19 Feb 2020 20:33:57 +0000 (UTC) Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id EBEBD24654 for ; Wed, 19 Feb 2020 20:33:56 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (1024-bit key) header.d=eikelenboom.it header.i=@eikelenboom.it header.b="ZZuofW68" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org EBEBD24654 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=eikelenboom.it Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=xen-devel-bounces@lists.xenproject.org Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1j4W1P-0001pZ-1A; Wed, 19 Feb 2020 20:32:39 +0000 Received: from us1-rack-iad1.inumbo.com ([172.99.69.81]) by lists.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1j4W1N-0001pJ-Pk for xen-devel@lists.xenproject.org; Wed, 19 Feb 2020 20:32:37 +0000 X-Inumbo-ID: f3c5876a-5356-11ea-ade5-bc764e2007e4 Received: from server.eikelenboom.it (unknown [91.121.65.215]) by us1-rack-iad1.inumbo.com (Halon) with ESMTPS id f3c5876a-5356-11ea-ade5-bc764e2007e4; Wed, 19 Feb 2020 20:32:31 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=eikelenboom.it; s=20180706; h=Content-Transfer-Encoding:MIME-Version: References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender:Reply-To: Content-Type:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help: List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=IwM5xDVexTtFbifpzcvRacL+iCjmBdmezBNuwX9Wrb0=; b=ZZuofW68kpx+4sW8OdtDPa/85Z SSgzQLjxBfPG7cy1LSkpSfPD9XGIiRK7PazMHd1pyLtPeLA3f1zL0syJxeJc7uNi/s6Nu0/97yhIP tmFiuWKz8K3RST5emu0za8a2qv0RdiZI7V5vP425+XwLQgLzzPoaJ7stvwFyDUsv8ZWE=; Received: from ip4da85049.direct-adsl.nl ([77.168.80.73]:60560 helo=localhost.localdomain) by server.eikelenboom.it with esmtpsa (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1j4W2k-0005p1-AC; Wed, 19 Feb 2020 21:34:02 +0100 From: Sander Eikelenboom To: xen-devel@lists.xenproject.org Date: Wed, 19 Feb 2020 21:31:31 +0100 Message-Id: X-Mailer: git-send-email 2.20.1 In-Reply-To: References: MIME-Version: 1.0 Subject: [Xen-devel] [PATCH 2/3] tools/xentop: Remove dead code X-BeenThere: xen-devel@lists.xenproject.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Cc: Sander Eikelenboom , Ian Jackson , Wei Liu Errors-To: xen-devel-bounces@lists.xenproject.org Sender: "Xen-devel" Signed-off-by: Sander Eikelenboom Acked-by: Wei Liu --- tools/xenstat/xentop/xentop.c | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/tools/xenstat/xentop/xentop.c b/tools/xenstat/xentop/xentop.c index 13b612f26d..bbb5d47b76 100644 --- a/tools/xenstat/xentop/xentop.c +++ b/tools/xenstat/xentop/xentop.c @@ -943,7 +943,6 @@ void do_summary(void) crash = 0, dying = 0, shutdown = 0; unsigned i, num_domains = 0; unsigned long long used = 0; - long freeable_mb = 0; xenstat_domain *domain; time_t curt; @@ -970,17 +969,12 @@ void do_summary(void) num_domains, run, block, pause, crash, dying, shutdown); used = xenstat_node_tot_mem(cur_node)-xenstat_node_free_mem(cur_node); - freeable_mb = 0; /* Dump node memory and cpu information */ - if ( freeable_mb <= 0 ) - print("Mem: %lluk total, %lluk used, %lluk free ", + print("Mem: %lluk total, %lluk used, %lluk free ", xenstat_node_tot_mem(cur_node)/1024, used/1024, xenstat_node_free_mem(cur_node)/1024); - else - print("Mem: %lluk total, %lluk used, %lluk free, %ldk freeable, ", - xenstat_node_tot_mem(cur_node)/1024, used/1024, - xenstat_node_free_mem(cur_node)/1024, freeable_mb*1024); + print("CPUs: %u @ %lluMHz\n", xenstat_node_num_cpus(cur_node), xenstat_node_cpu_hz(cur_node)/1000000);