Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp1452833rwd; Thu, 15 Jun 2023 10:41:07 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ6r+g6ASJ2+e8RXAerYu9Qwc0Vk2q46WtlAAX4yLco0tlrzlHD1y36AVIAP+uZukrr0QVx4 X-Received: by 2002:a17:907:2ce5:b0:978:af9d:4d4c with SMTP id hz5-20020a1709072ce500b00978af9d4d4cmr20880251ejc.75.1686850867119; Thu, 15 Jun 2023 10:41:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1686850867; cv=none; d=google.com; s=arc-20160816; b=JFOHsG8WcVvJDh1QctOs44tiiQDQhxtEefxu5Qj7AONaXCt1evFoLw+WMJwzKchQAB 3Ej79uFnBh2tqsIUJMxs3dIcvB1ur5iTdItIjQDybKdrx0ZZyaHy78ItCeK7sOyuSYVv Kbq0Y0s2z8H+wX9FFs3xKOQK8viPc/lBhdn1+WE5ZO3QAfeyrcvU+Shd7vIM04geYgt3 tVE0V1J/F3oTaOPFcyIz0Yh4Q9FyJugx+EvghiZTQpShbYt8wRb1dBVgEKy1kyp6FpNF i8+J2d1XYhB0HSd8yZK5XCYcnL48vW5fYPtoW8VIBeMQ0DGkGuALdmMxQr7f3xE2cIUi 7GWw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:user-agent:message-id:in-reply-to :date:references:subject:cc:to:from:dkim-signature; bh=gj1PE8jgcTAjvU5QpELZ2BVDX+vgouCIrJw6XJgXAGI=; b=J61Oq64ucqLk1+2oGByskz6QLzdyj9Pq34sQHaL/W9HAWxtN2jpvUsKrNoxq0Rdh/c mVi7NZcHz0XEG4mQp+esDJGycLlcnewcN6V1Mvlm8YkNh+yGxbZrLn2E7g8q4AJOQ++G 6+cNpfvOSlgIwGm1eF1QFVxzA/g4wH6arImQeaj6fVuH/wCo+oumSs2gZYpj4uVTR+5L RroFB7n7Nxdtb+q5J5nqkF9oyVClEYut0OnG35lXh7PLWyZD7H4j5mKayY/kQLNWv3YD wcngJqDQUTn/Y6jQe8nJcCHkXs0Q9ZpXeVcatjrOuV+xOW/VYpmdVZ4kb4JYbnEbU+S7 2HVQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=GqFT9P00; 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=NONE dis=NONE) header.from=intel.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id xo6-20020a170907bb8600b0096f445350d8si6595909ejc.805.2023.06.15.10.40.42; Thu, 15 Jun 2023 10:41:07 -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=@intel.com header.s=Intel header.b=GqFT9P00; 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=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229812AbjFORcb (ORCPT + 99 others); Thu, 15 Jun 2023 13:32:31 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44046 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230167AbjFORc2 (ORCPT ); Thu, 15 Jun 2023 13:32:28 -0400 Received: from mga03.intel.com (mga03.intel.com [134.134.136.65]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 559101FDD for ; Thu, 15 Jun 2023 10:32:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1686850347; x=1718386347; h=from:to:cc:subject:references:date:in-reply-to: message-id:mime-version; bh=gj1PE8jgcTAjvU5QpELZ2BVDX+vgouCIrJw6XJgXAGI=; b=GqFT9P00Zbh0a2/lpaNRpar0aXHALKvhhx6hveRRBeOtrL+PVeEfWY1B M5cCX1UPlUJLQF6uJuMiL3AoGgIlMuSmDVVE3RZ1gCGMyOQNNV5Y75GfQ t+vn3olJLL8c8zJL2VATcnmK8JTTme5VPaPWNE6/sAdXgexC4pm6fNRx3 B5s+B/LhkXb8MzpgGyLE4PeIWawGUEvx+xjIXia4Mjp1qv7LSulf4OHcd 9HS+7fgptj7b8Cnq+Quh6iM52qu39UyFbSohXy8fKpPw3tMgdrYigRiXZ SOkmEozxPP78Npv3AZBVgQ9h9crlIr/uyZONw8rse2TOvYEhciDsbibEI g==; X-IronPort-AV: E=McAfee;i="6600,9927,10742"; a="362402750" X-IronPort-AV: E=Sophos;i="6.00,245,1681196400"; d="scan'208";a="362402750" Received: from orsmga007.jf.intel.com ([10.7.209.58]) by orsmga103.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 15 Jun 2023 10:21:55 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10742"; a="706764961" X-IronPort-AV: E=Sophos;i="6.00,245,1681196400"; d="scan'208";a="706764961" Received: from tassilo.jf.intel.com (HELO tassilo.localdomain) ([10.54.38.190]) by orsmga007.jf.intel.com with ESMTP; 15 Jun 2023 10:21:55 -0700 Received: by tassilo.localdomain (Postfix, from userid 1000) id 86E65302A4D; Thu, 15 Jun 2023 10:21:55 -0700 (PDT) From: Andi Kleen To: Breno Leitao Cc: pawan.kumar.gupta@linux.intel.com, jpoimboe@kernel.org, peterz@infradead.org, tglx@linutronix.de, bp@alien8.de, leit@fb.com, hpa@zytor.com, x86@kernel.org, mingo@redhat.com, dave.hansen@linux.intel.com, linux-kernel@vger.kernel.org Subject: Re: [PATCH 0/2] x86/bugs: Break down mitigations configurations References: <20230615164417.3588162-1-leitao@debian.org> Date: Thu, 15 Jun 2023 10:21:55 -0700 In-Reply-To: <20230615164417.3588162-1-leitao@debian.org> (Breno Leitao's message of "Thu, 15 Jun 2023 09:44:11 -0700") Message-ID: <87352shc98.fsf@linux.intel.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Status: No, score=-4.3 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE, SPF_NONE,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 Breno Leitao writes: > There is no way to compile a kernel today with some of the speculative > mitigations disabled. Even if the kernel has > CONFIG_SPECULATION_MITIGATIONS=n, some Intel mitigations, such as MDS, TAA, > MMIO are still enabled and can only be disabled using a kernel parameter. > > This patchset creates a way to choose what to enable or disable, and, > get the mitigations disable if CONFIG_SPECULATION_MITIGATIONS is not > set, as the rest of other mitigations. > > Also, we want to print a warning message letting users know that these > mitigations are disabled. > > This is a follow up to this discussion: https://lkml.org/lkml/2023/6/12/798 > Isn't this all roughly equivalent to CONFIG_CMDLINE="mitigations=..." ? -Andi