From patchwork Mon Feb 12 15:18:06 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Prarit Bhargava X-Patchwork-Id: 10213327 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 16A6E60467 for ; Mon, 12 Feb 2018 15:38:16 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 05E9028987 for ; Mon, 12 Feb 2018 15:38:16 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id EEA032898E; Mon, 12 Feb 2018 15:38:15 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.2 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_MED autolearn=unavailable version=3.3.1 Received: from casper.infradead.org (casper.infradead.org [85.118.1.10]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 176DB28988 for ; Mon, 12 Feb 2018 15:38:15 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:Date:Message-ID:From: References:To:Subject:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=FpM6+J77hBsFW3VGbH3C6TVFqVRECfCJ4VBdD/qzKFE=; b=LclXpWhbD4BliINvBrxkcUon4 g+ezpR+5WBGF6UuPIXJf2eE1gXR3ms/ZMXQ6AZLVORWNiEqOQn1Ql/ByqpZ68fMUfq3Ek+UK7FYA7 K/7Im/QYiIJiggwXBua7jF0PcmURoHx5AALJijB1O7YM77xT7d3kwu+pqu6eVrMJaA+hQOap8WM8q lQ/nFUjt0789X61/oazbL5DTNm7j7PBcQsHSqI5gjK2wqf2f4Kax491Yt5l7BeXfsoZabOzTu4jzH rNK46cUMB4VH7o+gzdTgWxsFLLF90gS0B7mQ22vOkSSCaGhYLBpNx7/O6AD8d6lRjTk/cJNNcbeCZ SyakSYWUA==; Received: from [198.137.202.133] (helo=bombadil.infradead.org) by casper.infradead.org with esmtps (Exim 4.89 #1 (Red Hat Linux)) id 1elGB9-00052h-OV for patchwork-linux-arm@patchwork.kernel.org; Mon, 12 Feb 2018 15:38:04 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:Date: Message-ID:From:References:To:Subject:Reply-To:Content-ID:Content-Description :Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=FpM6+J77hBsFW3VGbH3C6TVFqVRECfCJ4VBdD/qzKFE=; b=VWt1Sv1RwYwJM5 Zgx+9GfL0blrg/xK1UJRTJi9zA667zzFr4YJAZoAD21nwvlZmHe89CLuxrbTkKAOwTmkC4O7RkGUP 8FeUIpuhlX6OHem8a382QP5Tzwd7w6kyexgRTzzewyQ0TzjldLTCpRRQIaKR5k0ZTINpN4wEqTh/3 sGgCXS4nl3lgCtAAN9uIeRWTNZbVsnZTJPmyYbl/kQv6QpNGhGKOLlbZletV3oDnvjOxSbgw5jb/K Ww0dUAsDOTtpB+5sRl4TsG5Eofq6RMGiRHODsSaKxP4WaXGCNlzqNed70wqSs0MUydmhXA3MWtToH zl2xpLCVjF8fusCz6MBw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.89 #1 (Red Hat Linux)) id 1elFs8-0002Jh-0r; Mon, 12 Feb 2018 15:18:24 +0000 Received: from mx3-rdu2.redhat.com ([66.187.233.73] helo=mx1.redhat.com) by bombadil.infradead.org with esmtps (Exim 4.89 #1 (Red Hat Linux)) id 1elFs4-0002C0-Fd for linux-arm-kernel@lists.infradead.org; Mon, 12 Feb 2018 15:18:21 +0000 Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.rdu2.redhat.com [10.11.54.3]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 7CBF540201A0; Mon, 12 Feb 2018 15:18:09 +0000 (UTC) Received: from [10.16.186.145] (prarit-guest.khw.lab.eng.bos.redhat.com [10.16.186.145]) by smtp.corp.redhat.com (Postfix) with ESMTP id 2CEFE100859A; Mon, 12 Feb 2018 15:18:06 +0000 (UTC) Subject: Re: [PATCH] acpi, spcr: Make SPCR available to x86 To: Peter Zijlstra References: <20180118150951.28964-1-prarit@redhat.com> <20180212133429.GC25314@hirez.programming.kicks-ass.net> <1e69fffc-1c3b-8cc0-f1cb-695de5ccdcb5@redhat.com> <20180212145652.GM25181@hirez.programming.kicks-ass.net> From: Prarit Bhargava Message-ID: <03e799c6-a0f3-eccf-882d-78205e9335ad@redhat.com> Date: Mon, 12 Feb 2018 10:18:06 -0500 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.7.0 MIME-Version: 1.0 In-Reply-To: <20180212145652.GM25181@hirez.programming.kicks-ass.net> X-Scanned-By: MIMEDefang 2.78 on 10.11.54.3 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.6]); Mon, 12 Feb 2018 15:18:09 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.6]); Mon, 12 Feb 2018 15:18:09 +0000 (UTC) for IP:'10.11.54.3' DOMAIN:'int-mx03.intmail.prod.int.rdu2.redhat.com' HELO:'smtp.corp.redhat.com' FROM:'prarit@redhat.com' RCPT:'' X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Jonathan Corbet , x86@kernel.org, graeme.gregory@linaro.org, linux-pm@vger.kernel.org, Catalin Marinas , Bhupesh Sharma , linux-doc@vger.kernel.org, Will Deacon , linux-kernel@vger.kernel.org, mark.salter@redhat.com, linux-acpi@vger.kernel.org, Ingo Molnar , Lv Zheng , linux-serial@vger.kernel.org, "H. Peter Anvin" , Thomas Gleixner , Timur Tabi , linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP On 02/12/2018 09:56 AM, Peter Zijlstra wrote: > On Mon, Feb 12, 2018 at 08:47:57AM -0500, Prarit Bhargava wrote: >> >> >> On 02/12/2018 08:34 AM, Peter Zijlstra wrote: >>> On Thu, Jan 18, 2018 at 10:09:51AM -0500, Prarit Bhargava wrote: >>>> config ACPI_SPCR_TABLE >>>> + bool "ACPI Serial Port Console Redirection Support" >>>> + default y if X86 >>>> + help >>>> + Enable support for Serial Port Console Redirection (SPCR) Table. >>>> + This table provides information about the configuration of the >>>> + earlycon console. >>> >>> I just got asked this by oldconfig, which left me rather puzzled, WTF >>> does this do? >> >> Odd -- I thought I had taken care of that :( My apologies Peter. >> >> ACPI SPCR is used by a vendor to define the serial console for a system. If >> SPCR exists a user can add kernel parameter "earlycon" (no extra kernel >> parameters) and the console will work out-of-the-box. >> >> The serial console configuration varies from vendor to vendor. This takes the >> guess-work out of defining a serial console. > > But when I specify "earlyprintk=serial,ttyS0,115200" this SPCR crud will > not interfere? > I tested "earlyprintk=serial,ttyS0,115200" on a system which is known to have a functional console with "console=ttyS0,1152008N1" both with and without CONFIG_ACPI_SPCR_TABLE enabled. I do not see any significant difference in output. root=/dev/mapper/rhel_intel--purley--lr--02-root ro crashkernel=auto rd.lvm.lv=rhel_intel-purley-lr-02/root rd.lvm.lv=rhel_intel-purley-lr-02/swap earlyprintk=serial,ttyS0,115200 LANG=en_US.UTF-8 x86/fpu: Supporting XSAVE feature 0x001: 'x87 floating point registers' x86/fpu: Supporting XSAVE feature 0x002: 'SSE registers' @@ -205,7 +205,7 @@ e820: last_pfn = 0x6f800 max_arch_pfn = 0x400000000 Using GB pages for direct mapping Secure boot disabled -RAMDISK: [mem 0x3a563000-0x3bba2fff] +RAMDISK: [mem 0x3a5da000-0x3bba2fff] ACPI: Early table checksum verification disabled ACPI: RSDP 0x000000006922A014 000024 (v02 INTEL ) ACPI: XSDT 0x00000000690DD188 000114 (v01 INTEL EDK2 00000000 01000013) @@ -519,6 +519,8 @@ ACPI: INT_SRC_OVR (bus 0 bus_irq 9 global_irq 9 high level) Using ACPI (MADT) for SMP configuration information ACPI: HPET id: 0x8086a701 base: 0xfed00000 +ACPI: SPCR: SPCR table version 1 +ACPI: SPCR: console: uart,io,0x3f8,115200 smpboot: Allowing 432 CPUs, 224 hotplug CPUs PM: Registered nosave memory: [mem 0x00000000-0x00000fff] PM: Registered nosave memory: [mem 0x000a0000-0x000fffff] @@ -555,10 +557,10 @@ log_buf_len total cpu_extra contributions: 1765376 bytes log_buf_len min size: 524288 bytes log_buf_len: 4194304 bytes -early log buf free: 477984(91%) -Memory: 394593504K/401282564K available (10252K kernel code, 2147K rwdata, 3664K rodata, 2504K init, 1800K bss, 6689060K reserved, 0K cma-reserved) +early log buf free: 477876(91%) +Memory: 394593976K/401282564K available (10252K kernel code, 2147K rwdata, 3664K rodata, 2504K init, 1800K bss, 6688588K reserved, 0K cma-reserved) Kernel/User page tables isolation: enabled -ftrace: allocating 35205 entries in 138 pages +ftrace: allocating 35206 entries in 138 pages Hierarchical RCU implementation. RCU restricting CPUs from NR_CPUS=8192 to nr_cpu_ids=432. Tasks RCU enabled. P. diff of boot logs: --- earlyprintk_no_spcr_enable 2018-02-12 10:11:00.477288423 -0500 +++ earlyprintk_spcr_enable 2018-02-12 10:16:02.282574797 -0500 @@ -1,5 +1,5 @@ microcode: microcode updated early to revision 0x2000035, date = 2017-10-17 -Linux version 4.15.0+ (root@intel-purley-lr-02.khw.lab.eng.bos.redhat.com) (gcc version 4.8.5 20150623 (Red Hat 4.8.5-28) (GCC)) #5 SMP Mon Feb 12 10:06:08 EST 2018 +Linux version 4.15.0+ (root@intel-purley-lr-02.khw.lab.eng.bos.redhat.com) (gcc version 4.8.5 20150623 (Red Hat 4.8.5-28) (GCC)) #6 SMP Mon Feb 12 10:11:42 EST 2018 Command line: BOOT_IMAGE=/vmlinuz-4.15.0+