From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753667AbYDMU54 (ORCPT ); Sun, 13 Apr 2008 16:57:56 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1752302AbYDMU5t (ORCPT ); Sun, 13 Apr 2008 16:57:49 -0400 Received: from terminus.zytor.com ([198.137.202.10]:50505 "EHLO terminus.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751717AbYDMU5s (ORCPT ); Sun, 13 Apr 2008 16:57:48 -0400 Message-ID: <480272BD.9010404@zytor.com> Date: Sun, 13 Apr 2008 13:53:17 -0700 From: "H. Peter Anvin" User-Agent: Thunderbird 2.0.0.12 (X11/20080226) MIME-Version: 1.0 To: Andi Kleen CC: Erik Bosman , Andrew Morton , Thomas Gleixner , Ingo Molnar , Arjan van de Ven , Andrea Arcangeli , Linus Torvalds , linux-kernel@vger.kernel.org Subject: Re: [PATCH 1/3] Add prctl commands PR_GET_TSC and PR_SET_TSC References: <87r6daw2ay.fsf@basil.nowhere.org> <87prstwvkr.fsf@basil.nowhere.org> <48025F1B.10701@zytor.com> <48027225.6000609@firstfloor.org> In-Reply-To: <48027225.6000609@firstfloor.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Andi Kleen wrote: >> I think what Erik is trying to do is to make it possible to disable as >> many of these in the kernel as possible; I/O is easy, it's off by >> default; RDTSC and RDPMC can be disabled in the kernel, and I think >> even XSTORE can be disabled. > > I'm a little sceptical it will work reliably, but we'll see. > > There's also LSL (forgot that earlier). It is used by the vgetcpu() > because it's faster than CPUID or RDTSCP. Kernel > sets a magic segment up which has different limits for different CPUs. > Yeah, that's unlikely to be found in code that isn't actively looking for it, though. -hpa