Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp4092545pxk; Tue, 8 Sep 2020 10:27:23 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw/rDNkUoQbYy0/EEaruofgxcTvWCT5cmncDF/JUILljAVyaW8fWeWJ1ZAEImPfzac+UXrq X-Received: by 2002:aa7:cd5a:: with SMTP id v26mr45750edw.38.1599586043083; Tue, 08 Sep 2020 10:27:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1599586043; cv=none; d=google.com; s=arc-20160816; b=Ef4Unxx/EJc6cTSSOEewF7RZ3xcpGQ9gMuOuSzct3jCbMP+qqIN0mhDWBZUH1y6U7H GJulxhem0ZS17+nMYPDdzAQfU+5dkZxCxALtHkpS1/VCvuChyjerlHH0T/A8Suq5o7OV x+4II5iQXyUBRWWtMcZ79nl4evPK2kSFPWvR/z4ADAbg8/a8ul5vYf/MqBtx/irXh+As y+4MmnuDecNRCTePgLSwwiNAHZvEW5fDS8OqNQHPv+gzNMqTQI0YQ5OuTkdhsofHNDl1 XVTnENK20uCik7v9J2V7b/H6vYEHWyDSKDYAl/5Tfh91R2GKqZZp36UY1Z9EyNFMCk6c GyzA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=CDPHzVOtjsYxVqMtTeVl7g411FkW4WHmSDs5Qd5T+KA=; b=bjOBQg74c3x20gA/S70wT1hEhEMHNMIvOJwdveekVtIv2bi2K+Sz+ZSd/5SzTEq5RK /iu6I9kLBtE6AFLIP8XUzwrgt7GDfL++cjPBVzL4t+CCSeAeh6p1yJlfVc8KsULOFIcV 04StK0CF3XKISJ4awS05N2kAGkpxLwf51gXC5hTOGIiu/guWphyo+XZpO2sL3TAWduyZ S4IUBsJL9NEm7qVbYHZsKapguVQxlp3s0FfFAavH4InFzoR7m9p9pAK4UqqpN1kf3TAm a1SXYDZbAMNyFoQBL/iP5TZ35xWawq/m9yFiJpGY/FxQhdOCEGM/fRrymKz+T8xOM82F RQuw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@alien8.de header.s=dkim header.b=LQ1D4gtn; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=alien8.de Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id q5si9837372eji.118.2020.09.08.10.26.59; Tue, 08 Sep 2020 10:27:23 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@alien8.de header.s=dkim header.b=LQ1D4gtn; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=alien8.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731635AbgIHR0Z (ORCPT + 99 others); Tue, 8 Sep 2020 13:26:25 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40030 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1731808AbgIHR0A (ORCPT ); Tue, 8 Sep 2020 13:26:00 -0400 Received: from mail.skyhub.de (mail.skyhub.de [IPv6:2a01:4f8:190:11c2::b:1457]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 02F8BC061573 for ; Tue, 8 Sep 2020 10:25:59 -0700 (PDT) Received: from zn.tnic (p200300ec2f10bf0070b09dfd4356f225.dip0.t-ipconnect.de [IPv6:2003:ec:2f10:bf00:70b0:9dfd:4356:f225]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.skyhub.de (SuperMail on ZX Spectrum 128k) with ESMTPSA id 776091EC0489; Tue, 8 Sep 2020 19:25:58 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alien8.de; s=dkim; t=1599585958; h=from:from: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:in-reply-to:in-reply-to: references:references; bh=CDPHzVOtjsYxVqMtTeVl7g411FkW4WHmSDs5Qd5T+KA=; b=LQ1D4gtne1y2gBQFmGW6p4rvLKM9mrwANcc1dl80u88eOSkzSRibQ2cxgLLhczSnW5Bv7S cb0LPDvm17Rxy3NfnVG4RGBiXJHkxgtCY02oh/AWtD79iroosjS0DT9gMSP9hoZsh0mBKR tir9k29H8eWXFBKswCucewg91YfKiwU= Date: Tue, 8 Sep 2020 19:25:58 +0200 From: Borislav Petkov To: "Jason A. Donenfeld" , Srinivas Pandruvada Cc: kitsunyan , "Brown, Len" , X86 ML , LKML Subject: Re: [PATCH] x86/msr: do not warn on writes to OC_MAILBOX Message-ID: <20200908172558.GG25236@zn.tnic> References: <20200907094843.1949-1-Jason@zx2c4.com> <20200907100647.GB10657@zn.tnic> <22617e57e541e460fac09db04fdb370f8e96e8ef.camel@linux.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Sep 08, 2020 at 07:12:44PM +0200, Jason A. Donenfeld wrote: > > Overclocking is not architectural I/F and is supported by some special > > CPU skews. I can't find any public document to specify the commands > > which can be used via this OC mailbox. I have to check internally to > > see if there is any. To add a proper sysfs interface we have to make > > sure that we are not allowing some random commands to hardware and > > crash the system. > > Well you can definitely crash the system this way -- undervolting can > result in all sorts of nice glitching. You might be able to even > programmatically undervolt to compromise the kernel in clever ways (a > lockdown bypass, I guess, but who cares). > > That's why I initially suggested this was pretty squarely in the realm > of hobbyists and should just be added to that whitelist. If that MSR can cause all kinds of crazy, I'd prefer writes to it from userspace to be completely forbidden, actually. And if force-enabled, with a BIG FAT WARNING each time userspace writes to it. -- Regards/Gruss, Boris. https://people.kernel.org/tglx/notes-about-netiquette