Received: by 2002:ac0:950c:0:0:0:0:0 with SMTP id f12csp3231397imc; Wed, 13 Mar 2019 12:13:46 -0700 (PDT) X-Google-Smtp-Source: APXvYqzG8iKtxhfR0y/yh1j0pwlgHqG1lPMWHTmdPfWNRHrTVfuebz2eT6iXUGrC+CtuZ8ok+UKC X-Received: by 2002:a63:540c:: with SMTP id i12mr3197695pgb.69.1552504426261; Wed, 13 Mar 2019 12:13:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1552504426; cv=none; d=google.com; s=arc-20160816; b=m08riCSuRZXlUZVgkCcEkpsFAVXzaHoMaJKa5kSEE3FUC3Ya4Gzq3IO2rhjuky67bP C9owkh3YGpVaUyQH9pb6qppScQuFqss/pfO4BIpZ0buWuO62N6i3VkdgAJbRN1hd3tBF XYrg/K1EPNPt0WAJp2nJ5yJv49Ko7LfWtrisROvmd2AVTZcSFoKPqvP0IGaOailhWL4p nOutdcCTDJqDionKn8qwf6Z/uctPNZYUGCoIikfBsZuPh5Q6R6gW+RXuy43cWF9oiOSQ fiC6AdxAkQahQH37DidhrFwVT+I+PzgnmXTfkhVx9+t9eZ9JKhjYNfcgnoUBOekgyloY SfuA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=dpRShOWJPEFuXfhgLvg7gHkoqkK4aB0tK6HluFMED5Q=; b=v7iNCrGRCeYJHwZM+tkGv+YSDtsvQMESxq75irD8KoB/equH+sptnK5w72qUe/gKqj S2J72ovvnar0wg1WbQRLN/ltsjqTAMIwdzD4UNkKSJEIAjTo1Vj5a27aNFFWWfrc96d0 Cow9F5QsTW5Iad1ga726nj0JbzTVLRyzYfeRb3AVhBRm2XuS9Yy0mtRAZNFm0BIg4oan mY5QxsM4w7OC3Dtv0foNVU2ShfBehBqYTB36TmYfzdtKwais/BXOdBP9dkDB5qYaMPgo C0S1UN69OxbqGICicHQKsW23oJjvGp0NWiLDL8sumqozWrg2sx6beEkHG9o3eTr9PLND 6T7Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=IBCOkeJo; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id l4si11688065plb.133.2019.03.13.12.13.30; Wed, 13 Mar 2019 12:13:46 -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; dkim=pass header.i=@kernel.org header.s=default header.b=IBCOkeJo; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727485AbfCMTL1 (ORCPT + 99 others); Wed, 13 Mar 2019 15:11:27 -0400 Received: from mail.kernel.org ([198.145.29.99]:41974 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727453AbfCMTLY (ORCPT ); Wed, 13 Mar 2019 15:11:24 -0400 Received: from sasha-vm.mshome.net (c-73-47-72-35.hsd1.nh.comcast.net [73.47.72.35]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id D0EA5213A2; Wed, 13 Mar 2019 19:11:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1552504283; bh=sUmCNFFZpdty6vBuGfBlRo6K0jX151qsZtCcqzZe+A8=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=IBCOkeJo0CB6dgj6rWVhHwCd1sqzL3tzkfwlEFyuXl82sVSEfERWjJKTHZb7aPmYQ jy/k/qk2tr457BQXtxMLjgE7sc9qmdZZbr7RpFzKTuKU6VNolxXLmkmsEEP50CzEha J5wiBj3meD2WPGFTW8LAOSB5/+75apjz0MKP0SoI= From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: Vladimir Murzin , Will Deacon , Sasha Levin Subject: [PATCH AUTOSEL 4.20 30/60] arm64: Relax GIC version check during early boot Date: Wed, 13 Mar 2019 15:09:51 -0400 Message-Id: <20190313191021.158171-30-sashal@kernel.org> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20190313191021.158171-1-sashal@kernel.org> References: <20190313191021.158171-1-sashal@kernel.org> MIME-Version: 1.0 X-Patchwork-Hint: Ignore Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Vladimir Murzin [ Upstream commit 74698f6971f25d045301139413578865fc2bd8f9 ] Updates to the GIC architecture allow ID_AA64PFR0_EL1.GIC to have values other than 0 or 1. At the moment, Linux is quite strict in the way it handles this field at early boot stage (cpufeature is fine) and will refuse to use the system register CPU interface if it doesn't find the value 1. Fixes: 021f653791ad17e03f98aaa7fb933816ae16f161 ("irqchip: gic-v3: Initial support for GICv3") Reported-by: Chase Conklin Reviewed-by: Marc Zyngier Signed-off-by: Vladimir Murzin Signed-off-by: Will Deacon Signed-off-by: Sasha Levin --- arch/arm64/kernel/head.S | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/arch/arm64/kernel/head.S b/arch/arm64/kernel/head.S index b207a2ce4bc6..715151b6d8b9 100644 --- a/arch/arm64/kernel/head.S +++ b/arch/arm64/kernel/head.S @@ -524,8 +524,7 @@ set_hcr: /* GICv3 system register access */ mrs x0, id_aa64pfr0_el1 ubfx x0, x0, #24, #4 - cmp x0, #1 - b.ne 3f + cbz x0, 3f mrs_s x0, SYS_ICC_SRE_EL2 orr x0, x0, #ICC_SRE_EL2_SRE // Set ICC_SRE_EL2.SRE==1 -- 2.19.1