From patchwork Mon Jul 31 15:35:56 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: tip-bot2 for Thomas Gleixner X-Patchwork-Id: 128794 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:918b:0:b0:3e4:2afc:c1 with SMTP id s11csp2147899vqg; Mon, 31 Jul 2023 10:07:44 -0700 (PDT) X-Google-Smtp-Source: APBJJlHUvYfGg125JjwMoFjit34wJTCwwdNPOhBBb1A9jRFPxGTNGF55LwZMoGyvt9ouf38joFMu X-Received: by 2002:aa7:c553:0:b0:51e:2e39:9003 with SMTP id s19-20020aa7c553000000b0051e2e399003mr461679edr.40.1690823263848; Mon, 31 Jul 2023 10:07:43 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1690823263; cv=none; d=google.com; s=arc-20160816; b=knrGMwLcoDMS5rqhSylrfAM8/YmA3lDAA9PPfowe467AdDZKJZrTL3UrmxncCkKntv oRBXOtsrbh7+DlqAgN0d50k011gOidmylIMPLY30bBnGmHxBULk//xZQ99zKly4fGm8I YwTMQ5+TJuVKyNyhKT9bf/q/3+4qy17bpMhdllsOkrlmeSbqUBbL80FjWM3bvzOy0uiS Drbe2HrlA8GyduRUbmxZc3mwwM5ZqWS7vxIuknGkCFH4kSvQiXowjMptYc+/ke+rj486 nMVtpha3a/rrUOvlKcG9GwFn0OL9rwkvLLh6pHZ+DlXvrSrAFJGpzm1U+tSq1HZqeX4O udKA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:robot-unsubscribe :robot-id:message-id:mime-version:references:in-reply-to:cc:subject :to:reply-to:sender:from:dkim-signature:dkim-signature:date; bh=lXQ2UlHztnSm7+VktGweD1ERC2/wwrBIcTkCarc5xAU=; fh=upF951G2H9k/GoAwEVjFOkoHtv14ziFm/Tyvv4uTTWs=; b=qoJaGEq/oTQcBBxH0JP9i+9APk2Hn5q6S8CnNdwO1OMX0Nk7d2kjIZg9OsDPAfP+bu LBGzNXIbjDjDzC9L1VgOgJ+RLC0z1cXj7dcji5q+Sf0yqJNOFGdoncNQqZu3DD68if4v 83V1CAmuFx3T4YTaHBkDD1x6SdMWVau1QPSlyuzfaMeaL5sgP7wpAg2J4gPhbfRpGVpq 7jPaMnnzapCAZGBlrh7Ap42SsKCsrJbh6k1i1x/KA/jhBctGJKPlAXMC7RP9oC6d7k72 DhvQqbi+sIqZm2OhbAl0CsTc8XLAg/2Rg2VXh6FQyb1bfiB2NdtUGJ5UizjfEC6myiaw v2uA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=s6zw5x4d; dkim=neutral (no key) header.i=@linutronix.de; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id e10-20020a056402148a00b005223a37a46bsi2012663edv.588.2023.07.31.10.07.19; Mon, 31 Jul 2023 10:07:43 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=s6zw5x4d; dkim=neutral (no key) header.i=@linutronix.de; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230149AbjGaPgB (ORCPT + 99 others); Mon, 31 Jul 2023 11:36:01 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48560 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230171AbjGaPf7 (ORCPT ); Mon, 31 Jul 2023 11:35:59 -0400 Received: from galois.linutronix.de (Galois.linutronix.de [193.142.43.55]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D5ACC126; Mon, 31 Jul 2023 08:35:58 -0700 (PDT) Date: Mon, 31 Jul 2023 15:35:56 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1690817757; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=lXQ2UlHztnSm7+VktGweD1ERC2/wwrBIcTkCarc5xAU=; b=s6zw5x4dkby2sE8Od+vaTzPkZMiBkUxKhohNUIZOa7Qg4x08pRw8lpCIPnrpDYfD/XqPVN l6R8EwOZg/XV7r7JkNlobCvohEHmRFw6rGKxrgYScLVrP15smYySsdi2e8Lr7hPkrgoqCm BSstqyEqf2UgCIrq/UV1XyCU7FE/dZ5adKkG8cRNzoVGUqiJoH9BboLiVolIl+PA8TYSwm UeyrFtusegoLW+Bsu40giK9uAp2RjGSzO3hHvSFJRmY10W6qOyQp0ucYzH8k9aJnPqhHqw lMQ7Gt9CxYrIRsDsxwTDp9z9KIivVKV6eH5tpKwSBg/yTjFQqdnmLZxexKgyNw== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1690817757; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=lXQ2UlHztnSm7+VktGweD1ERC2/wwrBIcTkCarc5xAU=; b=Txh65fJ0g+AhCBJiHTvb5jYL7Kn9pzOhRKQt1+5vEZ3Xlfw2hveeTw/Q8e7ubJ5EEJLg8W YZx5J3ONgKfryfBg== From: "tip-bot2 for Zhang Rui" Sender: tip-bot2@linutronix.de Reply-to: linux-kernel@vger.kernel.org To: linux-tip-commits@vger.kernel.org Subject: [tip: smp/core] cpu/SMT: Fix cpu_smt_possible() comment Cc: Zhang Rui , Thomas Gleixner , Vitaly Kuznetsov , x86@kernel.org, linux-kernel@vger.kernel.org In-Reply-To: <20230728155313.44170-1-rui.zhang@intel.com> References: <20230728155313.44170-1-rui.zhang@intel.com> MIME-Version: 1.0 Message-ID: <169081775691.28540.11108672281544540952.tip-bot2@tip-bot2> Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_BLOCKED, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham 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 X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1772681410582532467 X-GMAIL-MSGID: 1772956694674830868 The following commit has been merged into the smp/core branch of tip: Commit-ID: 52b38b7ad589c89a8c69272497bed20034f8e322 Gitweb: https://git.kernel.org/tip/52b38b7ad589c89a8c69272497bed20034f8e322 Author: Zhang Rui AuthorDate: Fri, 28 Jul 2023 23:53:13 +08:00 Committer: Thomas Gleixner CommitterDate: Mon, 31 Jul 2023 17:32:44 +02:00 cpu/SMT: Fix cpu_smt_possible() comment Commit e1572f1d08be ("cpu/SMT: create and export cpu_smt_possible()") introduces cpu_smt_possible() to represent if SMT is theoretically possible. It returns true when SMT is supported and not forcefully disabled ('nosmt=force'). But the comment of it says "Returns true if SMT is not supported of forcefully (irreversibly) disabled", which is wrong. Fix that comment accordingly. Signed-off-by: Zhang Rui Signed-off-by: Thomas Gleixner Reviewed-by: Vitaly Kuznetsov Link: https://lore.kernel.org/r/20230728155313.44170-1-rui.zhang@intel.com --- kernel/cpu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kernel/cpu.c b/kernel/cpu.c index 7e8f1b0..f6811c8 100644 --- a/kernel/cpu.c +++ b/kernel/cpu.c @@ -676,7 +676,7 @@ static inline bool cpu_smt_allowed(unsigned int cpu) return !cpumask_test_cpu(cpu, &cpus_booted_once_mask); } -/* Returns true if SMT is not supported of forcefully (irreversibly) disabled */ +/* Returns true if SMT is supported and not forcefully (irreversibly) disabled */ bool cpu_smt_possible(void) { return cpu_smt_control != CPU_SMT_FORCE_DISABLED &&