Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp3204489yba; Tue, 16 Apr 2019 06:52:20 -0700 (PDT) X-Google-Smtp-Source: APXvYqwiFyqddOJvggKrYPE0ev+ITvxbHzokbsTpxQDp+wI8eFVDLN3IH8USAwSk6SXV88L9GYmz X-Received: by 2002:a65:6546:: with SMTP id a6mr76938004pgw.5.1555422740182; Tue, 16 Apr 2019 06:52:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1555422740; cv=none; d=google.com; s=arc-20160816; b=tHIx0CAnSQ5sEH9u5s75c4+U3ESJLT5/4gcgxFqqc3O3xvELq6NcyIy6y7+18v8fE/ cj7cOyP+DFfpr/hXjzXyEO3QxrCTsHyqNiOQ6sU6vMuKtkPWccCLOixAsGLfqAokzBI2 MVKuLTZDLsjzmNh5X6TmQeSKh/IUZ6ELW1LiAnDdNPhVYOdfjfSu68txdR84Fnh2Xq0q dihnPGWPs3yT9ETDmkO0Uly/PeOO+oCnCgNm4rNBgwO3xDeCbm89LBfSq9J+hL9J6T6b 5oJjh2YWQTu7tVcyiYqWFIkQbKbL5pivsusiiEJAo/nt0F79sdqwFU3NMExaKj8OuUzX pfJw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:content-language:in-reply-to:cc :user-agent:content-transfer-encoding:mime-version:references :message-id:date:subject:from:to; bh=XOn0LGDqgvd945BA1sU0VBLiVT9GFNB2ze8Ut1jTv+o=; b=aTXMlHAtEXWF8ITqCpiv7skhy5yAwA8zfVDV0IrlxpJDAKZHsh4q64dkY/A5Lc91FW 1w78B489L0Noi/s8Od0AeD/Qk6EkROylSIzc1iBA+mylI+wxhhxBkob2hMnPDztMpdJ7 8GlRln0X7te2iJc4t0EzY2XaIxZG/+f87dL/DNZVK51vUo1E2Y8YB5hKGwraKUw1jsCU oZmaKISMZCGAECtrJQXhuRD1MSZc6897WWclRAKfq6ny1Jn0J2S+Uwioo9S0k9ULbAcq TmuRwL72coG0mb0uXpe2Q5Wg+K/WxtoErYe8YruB6zyLcAIrvS46HgaInaBA3KouQPd2 uz0g== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id u185si46572871pgd.489.2019.04.16.06.52.03; Tue, 16 Apr 2019 06:52:20 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729474AbfDPNtz (ORCPT + 99 others); Tue, 16 Apr 2019 09:49:55 -0400 Received: from [195.159.176.226] ([195.159.176.226]:45046 "EHLO blaine.gmane.org" rhost-flags-FAIL-FAIL-OK-OK) by vger.kernel.org with ESMTP id S1726605AbfDPNtz (ORCPT ); Tue, 16 Apr 2019 09:49:55 -0400 Received: from list by blaine.gmane.org with local (Exim 4.89) (envelope-from ) id 1hGOTB-000sqi-7H for linux-kernel@vger.kernel.org; Tue, 16 Apr 2019 15:49:53 +0200 X-Injected-Via-Gmane: http://gmane.org/ To: linux-kernel@vger.kernel.org From: Helge Deller Subject: Re: [PATCH 4.9 64/76] parisc: Detect QEMU earlier in boot process Date: Tue, 16 Apr 2019 15:49:47 +0200 Message-ID: <26f36020-9c8f-0559-7692-56fe88f5f6c1@gmx.de> References: <20190415183707.712011689@linuxfoundation.org> <20190415183726.478117691@linuxfoundation.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.6.1 Cc: stable@vger.kernel.org In-Reply-To: <20190415183726.478117691@linuxfoundation.org> Content-Language: en-US Cc: linux-kernel@vger.kernel.org Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Greg, please do NOT apply this patch to the 4.9 tree. See below, it was tagged for v4.14+ only. It breaks the build on 4.9, I got a 0-day build bug about it. Thanks, Helge On 15.04.19 20:44, Greg Kroah-Hartman wrote: > From: Helge Deller > > commit d006e95b5561f708d0385e9677ffe2c46f2ae345 upstream. > > While adding LASI support to QEMU, I noticed that the QEMU detection in > the kernel happens much too late. For example, when a LASI chip is found > by the kernel, it registers the LASI LED driver as well. But when we > run on QEMU it makes sense to avoid spending unnecessary CPU cycles, so > we need to access the running_on_QEMU flag earlier than before. > > This patch now makes the QEMU detection the fist task of the Linux > kernel by moving it to where the kernel enters the C-coding. > > Fixes: 310d82784fb4 ("parisc: qemu idle sleep support") > Signed-off-by: Helge Deller > Cc: stable@vger.kernel.org # v4.14+ > Signed-off-by: Greg Kroah-Hartman > > --- > arch/parisc/kernel/process.c | 6 ------ > arch/parisc/kernel/setup.c | 3 +++ > 2 files changed, 3 insertions(+), 6 deletions(-) > > --- a/arch/parisc/kernel/process.c > +++ b/arch/parisc/kernel/process.c > @@ -206,12 +206,6 @@ void __cpuidle arch_cpu_idle(void) > > static int __init parisc_idle_init(void) > { > - const char *marker; > - > - /* check QEMU/SeaBIOS marker in PAGE0 */ > - marker = (char *) &PAGE0->pad0; > - running_on_qemu = (memcmp(marker, "SeaBIOS", 8) == 0); > - > if (!running_on_qemu) > cpu_idle_poll_ctrl(1); > > --- a/arch/parisc/kernel/setup.c > +++ b/arch/parisc/kernel/setup.c > @@ -403,6 +403,9 @@ void start_parisc(void) > int ret, cpunum; > struct pdc_coproc_cfg coproc_cfg; > > + /* check QEMU/SeaBIOS marker in PAGE0 */ > + running_on_qemu = (memcmp(&PAGE0->pad0, "SeaBIOS", 8) == 0); > + > cpunum = smp_processor_id(); > > set_firmware_width_unlocked(); > > >