From nobody Mon Nov 25 12:52:55 2024 Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.13]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 8D12C1DED7C; Mon, 28 Oct 2024 16:12:22 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=192.198.163.13 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730131944; cv=none; b=uh+JykL4f+5wgUXlvSd2bcwPN7JAkrMaEteQZBNypRf3L3AuY/of42BsF4/YjLgTQvez7y79BR4HW929aFuR7CMgISFaiyvD81nrAmk+ftAL9hPWuT/ScVmWlLlOUGH5raKXC7eqnz4518WehsaZ9v4xMN4p+o5FFGB0ubM4wzM= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1730131944; c=relaxed/simple; bh=0UbvcEXBzd96pFeQsY9BD0bfGY00eu1UunRcSxKT5fU=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=VSGWvkrizX9yACgN+3srQTug34YMP40Dg6lY0ZffVeSVDOvKKMGNkk7lrgVysQegC5dfoRJtZj2v0+d59GRTMlDNliwJb4lIMpW6XapuAJ3PTutFpv89e15eNRefodh3qiEI1g90DTYnebBCcg0wUB5V5XkGO6tUrV0NDYTXPk4= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.intel.com; spf=none smtp.mailfrom=linux.intel.com; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b=DqWFAGtL; arc=none smtp.client-ip=192.198.163.13 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.intel.com Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=linux.intel.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b="DqWFAGtL" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1730131943; x=1761667943; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=0UbvcEXBzd96pFeQsY9BD0bfGY00eu1UunRcSxKT5fU=; b=DqWFAGtLb907DCbwlBPrMqOkr5TwiejP5h+sO+j8GkYA80c35VwtybCQ c1rK4Hfwn/wCmLqeGVVxFVw1VLuxYX6eK0Sumi0KAKA4v8wJNu4D6EqE2 eJgPnsq9CFXqk7HGbf4hq2JVWMHw/UuhBusM5MnXSENOQoTsK7AOnhOUp GoW6Jb7Fli43Ik+EE2NQznGSvAli15wBnY+qpb12gBnOvkzuPPmQ+jQVp zbOZhK02DmJ2QXpLOZFCjo3m14YI7j5dJb8RL1Qd4S5Scds/30sdKL8Z3 3BogiCDJ17SCmNZJKjzZGP6aPG7ZoOKgSZUaq5D+9rtiFwlUDw0D6jx9U A==; X-CSE-ConnectionGUID: b0Z6s+9CR2OW6MTab+kvsA== X-CSE-MsgGUID: amLNDxlLSFGK0S3kKLRkIA== X-IronPort-AV: E=McAfee;i="6700,10204,11239"; a="32594311" X-IronPort-AV: E=Sophos;i="6.11,239,1725346800"; d="scan'208";a="32594311" Received: from orviesa002.jf.intel.com ([10.64.159.142]) by fmvoesa107.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 28 Oct 2024 09:12:22 -0700 X-CSE-ConnectionGUID: Rjo4v9BvTwSSynfELkT3AQ== X-CSE-MsgGUID: bNFLXTAdSx2iW22Mb41jqQ== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.11,239,1725346800"; d="scan'208";a="112478842" Received: from black.fi.intel.com (HELO black.fi.intel.com.) ([10.237.72.28]) by orviesa002.jf.intel.com with ESMTP; 28 Oct 2024 09:12:10 -0700 From: Alexander Shishkin To: Andy Lutomirski , Thomas Gleixner , Ingo Molnar , Borislav Petkov , Dave Hansen , x86@kernel.org, "H. Peter Anvin" , Peter Zijlstra , Ard Biesheuvel , "Paul E. McKenney" , Josh Poimboeuf , Xiongwei Song , Xin Li , "Mike Rapoport (IBM)" , Brijesh Singh , Michael Roth , Tony Luck , "Kirill A. Shutemov" , Alexey Kardashevskiy Cc: Jonathan Corbet , Alexander Shishkin , Sohil Mehta , Ingo Molnar , Pawan Gupta , Daniel Sneddon , Kai Huang , Sandipan Das , Breno Leitao , Rick Edgecombe , Alexei Starovoitov , Hou Tao , Juergen Gross , Vegard Nossum , Kees Cook , Eric Biggers , Jason Gunthorpe , "Masami Hiramatsu (Google)" , Andrew Morton , Luis Chamberlain , Yuntao Wang , Rasmus Villemoes , Christophe Leroy , Tejun Heo , Changbin Du , Huang Shijie , Geert Uytterhoeven , Namhyung Kim , Arnaldo Carvalho de Melo , linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, linux-efi@vger.kernel.org Subject: [PATCH v5 14/16] x86/cpu: Make LAM depend on LASS Date: Mon, 28 Oct 2024 18:08:02 +0200 Message-ID: <20241028160917.1380714-15-alexander.shishkin@linux.intel.com> X-Mailer: git-send-email 2.45.2 In-Reply-To: <20241028160917.1380714-1-alexander.shishkin@linux.intel.com> References: <20241028160917.1380714-1-alexander.shishkin@linux.intel.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" To prevent exploits for Spectre based on LAM as demonstrated by the whitepaper [1], make LAM depend on LASS, which avoids this type of vulnerability. [1] https://download.vusec.net/papers/slam_sp24.pdf Signed-off-by: Alexander Shishkin --- arch/x86/kernel/cpu/cpuid-deps.c | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/x86/kernel/cpu/cpuid-deps.c b/arch/x86/kernel/cpu/cpuid-d= eps.c index 3f73c4b03348..d9fb2423605e 100644 --- a/arch/x86/kernel/cpu/cpuid-deps.c +++ b/arch/x86/kernel/cpu/cpuid-deps.c @@ -84,6 +84,7 @@ static const struct cpuid_dep cpuid_deps[] =3D { { X86_FEATURE_SHSTK, X86_FEATURE_XSAVES }, { X86_FEATURE_FRED, X86_FEATURE_LKGS }, { X86_FEATURE_LASS, X86_FEATURE_SMAP }, + { X86_FEATURE_LAM, X86_FEATURE_LASS }, {} }; =20 --=20 2.45.2