From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752306AbcEIJm1 (ORCPT ); Mon, 9 May 2016 05:42:27 -0400 Received: from merlin.infradead.org ([205.233.59.134]:57049 "EHLO merlin.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751079AbcEIJm0 (ORCPT ); Mon, 9 May 2016 05:42:26 -0400 Date: Mon, 9 May 2016 11:42:19 +0200 From: Peter Zijlstra To: Andi Kleen Cc: acme@kernel.org, jolsa@kernel.org, linux-kernel@vger.kernel.org, Andi Kleen , Thomas Gleixner , x86@kernel.org Subject: Re: [PATCH 02/10] x86, perf: Support sysfs files depending on SMT status Message-ID: <20160509094219.GO3448@twins.programming.kicks-ass.net> References: <1462489447-31832-1-git-send-email-andi@firstfloor.org> <1462489447-31832-3-git-send-email-andi@firstfloor.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1462489447-31832-3-git-send-email-andi@firstfloor.org> User-Agent: Mutt/1.5.21 (2012-12-30) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, May 05, 2016 at 04:03:59PM -0700, Andi Kleen wrote: > From: Andi Kleen > > Add a way to show different sysfs events attributes depending on > HyperThreading is on or off. This is difficult to determine > early at boot, so we just do it dynamically when the sysfs > attribute is read. > > v2: > Compute HT status only once in CPU online/offline hooks. > v3: Use topology_max_smt_threads() > Signed-off-by: Andi Kleen > --- > arch/x86/events/core.c | 24 ++++++++++++++++++++++++ > arch/x86/events/perf_event.h | 14 ++++++++++++++ > include/linux/perf_event.h | 7 +++++++ > 3 files changed, 45 insertions(+) > Should this not now live in /sys/devices/system/cpu/ ? Thomas?