From patchwork Mon Sep 2 12:11:50 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Andrew Cooper X-Patchwork-Id: 11126517 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 12DC91399 for ; Mon, 2 Sep 2019 12:14:00 +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 E2E27206B8 for ; Mon, 2 Sep 2019 12:13:59 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (1024-bit key) header.d=citrix.com header.i=@citrix.com header.b="CmVc/4PQ" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org E2E27206B8 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=citrix.com 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 1i4lBd-0007Lf-O7; Mon, 02 Sep 2019 12:11:57 +0000 Received: from us1-rack-iad1.inumbo.com ([172.99.69.81]) by lists.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1i4lBd-0007LU-9Q for xen-devel@lists.xenproject.org; Mon, 02 Sep 2019 12:11:57 +0000 X-Inumbo-ID: db4a200e-cd7a-11e9-b95f-bc764e2007e4 Received: from esa2.hc3370-68.iphmx.com (unknown [216.71.145.153]) by us1-rack-iad1.inumbo.com (Halon) with ESMTPS id db4a200e-cd7a-11e9-b95f-bc764e2007e4; Mon, 02 Sep 2019 12:11:56 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=citrix.com; s=securemail; t=1567426317; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=w6i41ZxPiPF2yUs3xAzSTkIf3AiNAEX/fl83Hf/iJ2k=; b=CmVc/4PQ93pV7Ezk7/xYk9dXEB+Jn7ZW3eZxBbmkjioyT328iCLMu551 l4t5MrsufVTEsJaIHUn4KMegEJ/vAoi+RxdS8ju6IDQ4gvL960pAaQm7/ fKcKCWFbUTghqjQ/mkoNuEz7HC5iOOxBm9t/8625s0WwxAwjp3+427Ir2 o=; Authentication-Results: esa2.hc3370-68.iphmx.com; dkim=none (message not signed) header.i=none; spf=None smtp.pra=andrew.cooper3@citrix.com; spf=Pass smtp.mailfrom=Andrew.Cooper3@citrix.com; spf=None smtp.helo=postmaster@mail.citrix.com Received-SPF: None (esa2.hc3370-68.iphmx.com: no sender authenticity information available from domain of andrew.cooper3@citrix.com) identity=pra; client-ip=162.221.158.21; receiver=esa2.hc3370-68.iphmx.com; envelope-from="Andrew.Cooper3@citrix.com"; x-sender="andrew.cooper3@citrix.com"; x-conformance=sidf_compatible Received-SPF: Pass (esa2.hc3370-68.iphmx.com: domain of Andrew.Cooper3@citrix.com designates 162.221.158.21 as permitted sender) identity=mailfrom; client-ip=162.221.158.21; receiver=esa2.hc3370-68.iphmx.com; envelope-from="Andrew.Cooper3@citrix.com"; x-sender="Andrew.Cooper3@citrix.com"; x-conformance=sidf_compatible; x-record-type="v=spf1"; x-record-text="v=spf1 ip4:209.167.231.154 ip4:178.63.86.133 ip4:195.66.111.40/30 ip4:85.115.9.32/28 ip4:199.102.83.4 ip4:192.28.146.160 ip4:192.28.146.107 ip4:216.52.6.88 ip4:216.52.6.188 ip4:162.221.158.21 ip4:162.221.156.83 ~all" Received-SPF: None (esa2.hc3370-68.iphmx.com: no sender authenticity information available from domain of postmaster@mail.citrix.com) identity=helo; client-ip=162.221.158.21; receiver=esa2.hc3370-68.iphmx.com; envelope-from="Andrew.Cooper3@citrix.com"; x-sender="postmaster@mail.citrix.com"; x-conformance=sidf_compatible IronPort-SDR: 6g+TGuXWfnbNTIrHE5QLyOIQVAH9w3CpgRAi7YmJzfsj9i3xgN2WjrrbX+f+27HwnJ5RDiMFBu S0DF/+r5WzOHuFmQjIqFfpOfqBRYxmXdhY1z+CaO/ClyUYsNhF6YDg61gJ8yd5v3teMvcv4n1Q YuEkT9qnKLKgRii4YhSxW4+YYGuuwXWi7h8xeFYLAroG7LPpnkuRDoC9hoNY0mAo7sD0/mT1ug vCmMQky27ZhL4LjDstS5J/60kBJFHWUA/c8O9z+FCY75rch9pKoqqsWjmDSZ4H3QduoUetex2V UHo= X-SBRS: 2.7 X-MesageID: 5014793 X-Ironport-Server: esa2.hc3370-68.iphmx.com X-Remote-IP: 162.221.158.21 X-Policy: $RELAYED X-IronPort-AV: E=Sophos;i="5.64,459,1559534400"; d="scan'208";a="5014793" From: Andrew Cooper To: Xen-devel Date: Mon, 2 Sep 2019 13:11:50 +0100 Message-ID: <20190902121151.11384-1-andrew.cooper3@citrix.com> X-Mailer: git-send-email 2.11.0 MIME-Version: 1.0 Subject: [Xen-devel] [PATCH 1/2] x86/acpi: Drop sleep_states[] and associated print messages 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: Andrew Cooper , Wei Liu , Jan Beulich , =?utf-8?q?Roger_Pau_Monn=C3=A9?= Errors-To: xen-devel-bounces@lists.xenproject.org Sender: "Xen-devel" sleep_states[] is a write-only array, and despite the loop logic, the printed message is consistently "ACPI sleep modes: S3". Drop it all. Signed-off-by: Andrew Cooper Acked-by: Jan Beulich --- CC: Jan Beulich CC: Wei Liu CC: Roger Pau Monné --- xen/arch/x86/acpi/power.c | 15 --------------- 1 file changed, 15 deletions(-) diff --git a/xen/arch/x86/acpi/power.c b/xen/arch/x86/acpi/power.c index d83e8cdd52..6ae9e29229 100644 --- a/xen/arch/x86/acpi/power.c +++ b/xen/arch/x86/acpi/power.c @@ -36,7 +36,6 @@ uint32_t system_reset_counter = 1; static char __initdata opt_acpi_sleep[20]; string_param("acpi_sleep", opt_acpi_sleep); -static u8 sleep_states[ACPI_S_STATE_COUNT]; static DEFINE_SPINLOCK(pm_lock); struct acpi_sleep_info acpi_sinfo; @@ -460,7 +459,6 @@ acpi_status acpi_enter_sleep_state(u8 sleep_state) static int __init acpi_sleep_init(void) { - int i; char *p = opt_acpi_sleep; while ( (p != NULL) && (*p != '\0') ) @@ -474,19 +472,6 @@ static int __init acpi_sleep_init(void) p += strspn(p, ", \t"); } - printk(XENLOG_INFO "ACPI sleep modes:"); - for ( i = 0; i < ACPI_S_STATE_COUNT; i++ ) - { - if ( i == ACPI_STATE_S3 ) - { - sleep_states[i] = 1; - printk(" S%d", i); - } - else - sleep_states[i] = 0; - } - printk("\n"); - return 0; } __initcall(acpi_sleep_init);