Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp1236978pxa; Thu, 20 Aug 2020 06:25:32 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyA/AipiR6LQO0b6lFsB+dgwTNzw9aMzmHxPAJpsuu3drzUUL49x0oIEkvWbTMpx58tSQEK X-Received: by 2002:a17:906:454c:: with SMTP id s12mr3144861ejq.339.1597929932306; Thu, 20 Aug 2020 06:25:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1597929932; cv=none; d=google.com; s=arc-20160816; b=FaurS8xOLfJGbgjlasQTxvxwb3Yjs6HLyTtMCkbYjZ0rzBOphm6q0HF8GNM4vblba1 5UME/IUX5hRt871skTFvgcJpNMsAVZvwSKs9gavx5moKqUJPP2pZOiLNuYv5KKvYu/St GVciVNpuT7H2tCTbVXhZYcnTjdIT956TfTLF25o11hi7ULuh+/IK+/fcU/MwLQQVHiWd nJ3VwlaTZ0/LYzYst464zgLIcc84FAFuQmGU88HUKRVhr5AYUsy5qyx8u4Aq199ToBIA SZ6wzW2qcBGe7UHswK6vpahTm4D6Ma//fWKXrAOMjzc5/mi6/FS/FSzpSSIFzOI+h5Pa LtHg== 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 :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=VUX1C/BX3TGlX9SVk50VEsw4IsZFCzyl8wSjwU/W2kU=; b=uQTVGsrTkszeRveF8NY7rkPhCN7hOnONSVLtMSaSEhOczAy90duqGdWg+1JC7EdX2X wV2GACa5I3KALdvsqr0wVDtfffpgI94BIA7X85oJYHouPV5eLph6Ym3SYDAyvOFX4L4Y FGKth9JFk+KnVAOoyj07AzTrv5TZVzCpMKhJmmF9a5AN64z7yZj0VwyL8EJpuhj8zwEV C9jyiP7HkcGQ3B7hMbSm+j8GGOVuDvjMWsa40ETvalKn2giNpjD1i4aoG8wouUyKrE1N ataKQW1IXnpH0iHAeK5FPB4S0iMg67OtKZ1RKIov/xbiM4aXodIb3AzRqAGFqt+smok4 hk9Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=Bo5aqiUC; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id ec15si1105971ejb.236.2020.08.20.06.25.06; Thu, 20 Aug 2020 06:25:32 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=Bo5aqiUC; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730582AbgHTNY1 (ORCPT + 99 others); Thu, 20 Aug 2020 09:24:27 -0400 Received: from mail.kernel.org ([198.145.29.99]:45002 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728405AbgHTJd0 (ORCPT ); Thu, 20 Aug 2020 05:33:26 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id CB9A822BEF; Thu, 20 Aug 2020 09:33:12 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1597915993; bh=0pkLbZ3ecE1PW8MfK1EZfq9ZmaccVL2nFYhP+U3ugMU=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Bo5aqiUCvvmFnpok/m7u/8NaniYKQlT3inDMT939nVGBQAHdXcYAiKbuvPQR7TARf oA7Giwk7NMruK3mNqB+lKwxNnhm+HFX4EBZMktl6UfC5FJwuSqyer8GLn5y5Yb5U/6 0hPDIzmh2WYJlddqwR9q12UaX3gpBf2MaCmiE2cY= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Dilip Kota , Ingo Molnar , Andy Shevchenko , Sasha Levin Subject: [PATCH 5.8 189/232] x86/tsr: Fix tsc frequency enumeration bug on Lightning Mountain SoC Date: Thu, 20 Aug 2020 11:20:40 +0200 Message-Id: <20200820091621.948589440@linuxfoundation.org> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20200820091612.692383444@linuxfoundation.org> References: <20200820091612.692383444@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Dilip Kota [ Upstream commit 7d98585860d845e36ee612832a5ff021f201dbaf ] Frequency descriptor of Lightning Mountain SoC doesn't have all the frequency entries so resulting in the below failure causing a kernel hang: Error MSR_FSB_FREQ index 15 is unknown tsc: Fast TSC calibration failed So, add all the frequency entries in the Lightning Mountain SoC frequency descriptor. Fixes: 0cc5359d8fd45 ("x86/cpu: Update init data for new Airmont CPU model") Fixes: 812c2d7506fd ("x86/tsc_msr: Use named struct initializers") Signed-off-by: Dilip Kota Signed-off-by: Ingo Molnar Reviewed-by: Andy Shevchenko Link: https://lore.kernel.org/r/211c643ae217604b46cbec43a2c0423946dc7d2d.1596440057.git.eswara.kota@linux.intel.com Signed-off-by: Sasha Levin --- arch/x86/kernel/tsc_msr.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/arch/x86/kernel/tsc_msr.c b/arch/x86/kernel/tsc_msr.c index 4fec6f3a1858b..a654a9b4b77c0 100644 --- a/arch/x86/kernel/tsc_msr.c +++ b/arch/x86/kernel/tsc_msr.c @@ -133,10 +133,15 @@ static const struct freq_desc freq_desc_ann = { .mask = 0x0f, }; -/* 24 MHz crystal? : 24 * 13 / 4 = 78 MHz */ +/* + * 24 MHz crystal? : 24 * 13 / 4 = 78 MHz + * Frequency step for Lightning Mountain SoC is fixed to 78 MHz, + * so all the frequency entries are 78000. + */ static const struct freq_desc freq_desc_lgm = { .use_msr_plat = true, - .freqs = { 78000, 78000, 78000, 78000, 78000, 78000, 78000, 78000 }, + .freqs = { 78000, 78000, 78000, 78000, 78000, 78000, 78000, 78000, + 78000, 78000, 78000, 78000, 78000, 78000, 78000, 78000 }, .mask = 0x0f, }; -- 2.25.1