From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 8B7BE1BDCF for ; Tue, 11 Mar 2025 14:42:20 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.140.110.172 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1741704141; cv=none; b=OIxwisSDocAqy0yD0Yhfd+Tc9IO2aPKyWBvqrP39OT9qscQ0Cjj0dOFLI4OqjZI6F0AQ35ofY3b1oUdRJ4qtsFGrmMj7pYWfGdVga+IwV+BZJQNOfoHxOjPunf3YieFPSyJ0ufroUBftJbP4krZSmQOdPN9c08Iivxvt41t4790= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1741704141; c=relaxed/simple; bh=Mi9GpSUI0YDuIvKM8S4IKN+MPXhoZG8THBz5Fkf2ZJg=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=MY1sXFPUAW2VNX18C2gqq3QV+annoZAOZl4nesTtti8BBfvWcR4drdwFXvTRAvyULzEpm/O/6uHX2X8Sr3QuD72zJGnyudyg2T173URGPgKIWmzZwC1QG5h9UAE5/ZnIAkBHU6heICpRA1HFQ87DbDIPfjNUhle6dFTZxouaBt4= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=fail (p=none dis=none) header.from=arm.com; spf=none smtp.mailfrom=foss.arm.com; arc=none smtp.client-ip=217.140.110.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=fail (p=none dis=none) header.from=arm.com Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=foss.arm.com Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 189092720; Tue, 11 Mar 2025 07:42:31 -0700 (PDT) Received: from bogus (e133711.arm.com [10.1.196.55]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id E34F53F694; Tue, 11 Mar 2025 07:42:15 -0700 (PDT) Date: Tue, 11 Mar 2025 14:42:13 +0000 From: Sudeep Holla To: Yicong Yang Cc: , , , , , , , , , , , , , , , , , , , , , , , , Subject: Re: [PATCH v12 2/4] arch_topology: Support SMT control for OF based system Message-ID: References: <20250311075143.61078-1-yangyicong@huawei.com> <20250311075143.61078-3-yangyicong@huawei.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20250311075143.61078-3-yangyicong@huawei.com> On Tue, Mar 11, 2025 at 03:51:41PM +0800, Yicong Yang wrote: > From: Yicong Yang > > On building the topology from the devicetree, we've already gotten the > SMT thread number of each core. Update the largest SMT thread number > and enable the SMT control by the end of topology parsing. > > The framework's SMT control provides two interface to the users [1] > through /sys/devices/system/cpu/smt/control: > 1) enable SMT by writing "on" and disable by "off" > 2) enable SMT by writing max_thread_number or disable by writing 1 > > Both method support to completely disable/enable the SMT cores so both > work correctly for symmetric SMT platform and asymmetric platform with > non-SMT and one type SMT cores like: > core A: 1 thread > core B: X (X!=1) threads > > Note that for a theoretically possible multiple SMT-X (X>1) core > platform the SMT control is also supported as expected but only > by writing the "on/off" method. > > [1] https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/ABI/testing/sysfs-devices-system-cpu#n542 Just the path must suffice here, no need for URL. LGTM otherwise, much simple now: Reviewed-by: Sudeep Holla -- Regards, Sudeep