Received: by 2002:a05:7412:40d:b0:e2:908c:2ebd with SMTP id 13csp484965rdf; Tue, 21 Nov 2023 07:57:07 -0800 (PST) X-Google-Smtp-Source: AGHT+IGsXpYO9o9rLK/G9tz8R++jg0WfrF3oKsixMuICQpP2PegMUE04XJQ7u960yxUExr3JD+1i X-Received: by 2002:a17:90b:4d0e:b0:27d:198:fcc2 with SMTP id mw14-20020a17090b4d0e00b0027d0198fcc2mr9472070pjb.33.1700582227252; Tue, 21 Nov 2023 07:57:07 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1700582227; cv=none; d=google.com; s=arc-20160816; b=TrSm472adYA0sA23/cC/CwA1Z1h2wLKvPcSo3ZBr9jTohNEtFY/5zlJN4hwQtycTU/ QuvbpKxORz2+Zv+Iy2bLnvwBrRs3zrnJEewcXJIQtvJ9rET5D1xBAYFMoaA5wiefUPRw j2ajb3I/guoJciaY8Yzcle6p5ba0QeRvhSQiXyIVENhTOh+CRPWxaRzgZmUrVKQ3ogLq UNw4u+o17l2bz0U/NlxPGmwMGcTu91k1vj06qmllfjio/rsUuQEV9dfGTiKHxPoq35d1 jafmXQYRsetTqr2wsXyR6LPNDje0rGyZ0K4PMjx9FVOoJINKKcuPOekiYJYSjmsTY0/0 JZiw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date; bh=0Dhh+jYPrKA9bHQpIhkyY8luyQfeiRtmNUIIuX4AcKs=; fh=C1Jt1xn3xYgx3sJ5OxzmPL1uviROdcBxKCLzeiDIeNU=; b=lM7ZJItMnKBfkEkLoPxdFWdE17TvG6d0t8XKYoq/Uek32RSyWIGzGTqGhaC+Nh78s4 4+toIYtfml0JSe3ZfIel1SGyHa8y3KjYUuvkInZJ4Wei10MgI7iqjMdWtx5xQl/4FuL8 advt06aRWGKJZ9WiB18kelEoR6ZggCOCSqIpkWvT1TaRkcLNnCf74KaGMG8OOAH8u3oq LfnTsxKpc1bhY9lE3vqQA3uRyLJepp5t0ZbAGCfvHFBWT3N73kQZxo8Jnr/To10ETHTr 2c5RKWpy+h+2g92V1yTBlmZh1c2cAcsnHEzM60GB5QWSkjSZ5gJ/BPmLovNvFi0dbVPB P5Ag== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:3 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from lipwig.vger.email (lipwig.vger.email. [2620:137:e000::3:3]) by mx.google.com with ESMTPS id br17-20020a17090b0f1100b00283a5548126si7851247pjb.98.2023.11.21.07.57.06 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 21 Nov 2023 07:57:07 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:3 as permitted sender) client-ip=2620:137:e000::3:3; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:3 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by lipwig.vger.email (Postfix) with ESMTP id BCAAD807753C; Tue, 21 Nov 2023 07:56:01 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at lipwig.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234634AbjKUPzh (ORCPT + 99 others); Tue, 21 Nov 2023 10:55:37 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34756 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234657AbjKUPzf (ORCPT ); Tue, 21 Nov 2023 10:55:35 -0500 Received: from mail-ed1-f52.google.com (mail-ed1-f52.google.com [209.85.208.52]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 903C218C for ; Tue, 21 Nov 2023 07:55:31 -0800 (PST) Received: by mail-ed1-f52.google.com with SMTP id 4fb4d7f45d1cf-5488bf9e193so4140467a12.2 for ; Tue, 21 Nov 2023 07:55:31 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1700582130; x=1701186930; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=0Dhh+jYPrKA9bHQpIhkyY8luyQfeiRtmNUIIuX4AcKs=; b=uMINHEBUTq/fwo4VkUmNdxg0/H3FieqoVm6BtN2gwx/6QVNTYe9+wDUPcvnZYLtXUW vWxEtbdbq20wAl+Xnx8EMTW/ofv/Go+JnqGJ8lkunIrzfyF8vgJlP0EKVBNVY8sNTq7W rz5ByJt7u7Glgg3GwbDvmCPrKDF1UtjGTRv6LXGnGVxAmcQZTkeusu6XlXzrv2TOk+mt D1VbnAMvvowsFmFGGxrpUq+xBBozsgia3/BHKIn0dbUVMOB1d3r/n1k4wDRxcn1aqoUH BgP42vlT7qY0ivfY31RGpyz5YAQlbGn9dVr/EIJcM7quGr+LHeCUj6KkNlcxJsMJe1gG t0Ag== X-Gm-Message-State: AOJu0YyU7ClJJpbj5WHi4/JMMDqj3LTjlDgSv3ESkGI/7pzUOAV2d6Qt v+K16BiC2OSY1iqc6sfatfo= X-Received: by 2002:a17:906:221c:b0:9c7:5a14:ecf2 with SMTP id s28-20020a170906221c00b009c75a14ecf2mr8928160ejs.56.1700582129853; Tue, 21 Nov 2023 07:55:29 -0800 (PST) Received: from gmail.com (fwdproxy-cln-014.fbsv.net. [2a03:2880:31ff:e::face:b00c]) by smtp.gmail.com with ESMTPSA id cm28-20020a170906f59c00b009fcb5fcfbe6sm3215439ejd.220.2023.11.21.07.55.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 21 Nov 2023 07:55:29 -0800 (PST) Date: Tue, 21 Nov 2023 07:55:25 -0800 From: Breno Leitao To: Josh Poimboeuf Cc: mingo@redhat.com, tglx@linutronix.de, bp@alien8.de, Dave Hansen , x86@kernel.org, "H. Peter Anvin" , Peter Zijlstra , Pawan Gupta , leit@meta.com, "open list:X86 ARCHITECTURE (32-BIT AND 64-BIT)" Subject: Re: [PATCH v5 12/12] x86/bugs: Add a separate config for missing mitigation Message-ID: References: <20231019181158.1982205-1-leitao@debian.org> <20231019181158.1982205-13-leitao@debian.org> <20231025162906.abnyb7xum7cpjwxy@treble> <20231109224356.diks3jws5ezfldzy@treble> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20231109224356.diks3jws5ezfldzy@treble> X-Spam-Status: No, score=0.5 required=5.0 tests=FSL_HELO_FAKE, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lipwig.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (lipwig.vger.email [0.0.0.0]); Tue, 21 Nov 2023 07:56:01 -0800 (PST) On Thu, Nov 09, 2023 at 02:43:56PM -0800, Josh Poimboeuf wrote: > On Thu, Oct 26, 2023 at 10:09:17AM -0700, Breno Leitao wrote: > > > I'm thinking CONFIG_MITIGATION_SPECTRE_V2 should also affect whether the spectre v2 user > > > mitigation gets enabled. > > > > Makes sense, would something like this be enough? > > Looks good to me. > > While you're at it, for consistency can you add a cpu_mitigations_off() > check to spectre_v2_parse_user_cmdline()? Good catch. I think we might want to do it in `spectre_v2_user_select_mitigation()`, but let me test better and send it. Since this is not dependent on this patch series, I will send this as an idividual patch, to avoiding growing this patchset much (currently at 13 patches). Thanks