Received: by 2002:a5d:9c59:0:0:0:0:0 with SMTP id 25csp2157705iof; Tue, 7 Jun 2022 21:41:06 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyrDWSAdlSvLeEk8NYlLZsZEHMpExbagCK5OCAcX3rKZ50KgER6qFKx0HbnPX32lDQ09Sur X-Received: by 2002:a17:903:1013:b0:163:e8b9:2429 with SMTP id a19-20020a170903101300b00163e8b92429mr32486506plb.74.1654663266559; Tue, 07 Jun 2022 21:41:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1654663266; cv=none; d=google.com; s=arc-20160816; b=yTVwkSuP15vmhKB3yf/8FDI2hzjJTkILZMR4Gx+h0Ft5oitSqBF4UV+TJWVpFmQnEk 0xo1ZOjoexeQz5BoWRyvlxXFwZs/s+LlbBMpDK4hCCuNNitP+JANVjw9ct7W9fjOs9OE CrVu/qm8T2Hu3aA3WdvttQyUbhYQXEICcy2fNtUCZrgA0DKt3iYQ1ClJ1qmSBhvCjpyK wDX1EGEbRjlIk8FkrQxV0YlKNteVYKSdPveFZtwZEj5ir5xrclMCiQoY+Wtao4QAYdhN KHCsoZLSheZy6NQyidf0kAEGfvovipDk6V2zYLrPXhwu0GtoR6SEl21r2kcCDJMglLBU sW+g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=G3Ji+4lQfl3Ja5MQm4/rD/6sglFgPBpanVJet1x0C5o=; b=Dad6+tiLxtHQEQFODYUr3/MZFADdC4zwiEGNpIuwcirb1dFXFalcq1jvETCKHeukFT icZJhY3r9o9YxSgs1PdQCvySu7Pxi1WUu6B3cPZc0GZNKbAfcszaIFmlcUm0XgKwqjjv 5SAYDarpEWYk57R+ZHbNFVVlGe7h1S2P/NSFzHh0dcYnQE8SE7C/0KFpk0TVbBaOqKKy YIq6EqmMNC+4g95+NJnnkcHGwOlu/BMzZzopeZPosMn4wWrmSBet94Y4p7cLCw5A/oxf Gv8Q6xoZJB7TLX93g+ZiapmdSZn89B45/eGK2mbLDsD/AeIK70qcgLeAK5Z5J+j6KB4U DYeQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=Ekpx1raW; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id f14-20020a63f74e000000b003fe20625995si2921083pgk.458.2022.06.07.21.41.06 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 07 Jun 2022 21:41:06 -0700 (PDT) Received-SPF: softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) client-ip=23.128.96.19; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=Ekpx1raW; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id BE6D344C75F; Tue, 7 Jun 2022 21:13:15 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1359336AbiFGUYM (ORCPT + 99 others); Tue, 7 Jun 2022 16:24:12 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60514 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1351979AbiFGTcJ (ORCPT ); Tue, 7 Jun 2022 15:32:09 -0400 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 06FF9C5E6A; Tue, 7 Jun 2022 11:12:52 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 43E7AB81F38; Tue, 7 Jun 2022 18:12:47 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id A718BC385A2; Tue, 7 Jun 2022 18:12:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1654625566; bh=FQ0KiZojiiCMdSntTJQX+VlNmgl4iS0gWsxYxk6CTm8=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Ekpx1raWIwZRC8jH4/w9N1Nd1XcG58MU8tCKdyG8r6BdtXXDZY9v4HNywrT828LP9 er6mCRRukXeKnTiOLjzENd29vENTqTLf13B6vD+vxDjhefJxMe2+PWf1A8tVdSoYwm Dar9DNrLkXDRB6kLgkVQNHfNZ4zsd5mxUFdQ/NAc= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Mike Travis , Steve Wahl , Borislav Petkov , Dimitri Sivanich , Thomas Gleixner , Sasha Levin Subject: [PATCH 5.17 063/772] x86/platform/uv: Update TSC sync state for UV5 Date: Tue, 7 Jun 2022 18:54:15 +0200 Message-Id: <20220607164950.896055261@linuxfoundation.org> X-Mailer: git-send-email 2.36.1 In-Reply-To: <20220607164948.980838585@linuxfoundation.org> References: <20220607164948.980838585@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-3.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Mike Travis [ Upstream commit bb3ab81bdbd53f88f26ffabc9fb15bd8466486ec ] The UV5 platform synchronizes the TSCs among all chassis, and will not proceed to OS boot without achieving synchronization. Previous UV platforms provided a register indicating successful synchronization. This is no longer available on UV5. On this platform TSC_ADJUST should not be reset by the kernel. Signed-off-by: Mike Travis Signed-off-by: Steve Wahl Signed-off-by: Borislav Petkov Reviewed-by: Dimitri Sivanich Acked-by: Thomas Gleixner Link: https://lore.kernel.org/r/20220406195149.228164-3-steve.wahl@hpe.com Signed-off-by: Sasha Levin --- arch/x86/kernel/apic/x2apic_uv_x.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/arch/x86/kernel/apic/x2apic_uv_x.c b/arch/x86/kernel/apic/x2apic_uv_x.c index f5a48e66e4f5..a6e9c2794ef5 100644 --- a/arch/x86/kernel/apic/x2apic_uv_x.c +++ b/arch/x86/kernel/apic/x2apic_uv_x.c @@ -199,7 +199,13 @@ static void __init uv_tsc_check_sync(void) int mmr_shift; char *state; - /* Different returns from different UV BIOS versions */ + /* UV5 guarantees synced TSCs; do not zero TSC_ADJUST */ + if (!is_uv(UV2|UV3|UV4)) { + mark_tsc_async_resets("UV5+"); + return; + } + + /* UV2,3,4, UV BIOS TSC sync state available */ mmr = uv_early_read_mmr(UVH_TSC_SYNC_MMR); mmr_shift = is_uv2_hub() ? UVH_TSC_SYNC_SHIFT_UV2K : UVH_TSC_SYNC_SHIFT; -- 2.35.1