Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 200C3C64EC7 for ; Mon, 20 Feb 2023 19:02:30 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233017AbjBTTC3 (ORCPT ); Mon, 20 Feb 2023 14:02:29 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50954 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233025AbjBTTCY (ORCPT ); Mon, 20 Feb 2023 14:02:24 -0500 Received: from ams.source.kernel.org (ams.source.kernel.org [IPv6:2604:1380:4601:e00::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0BF86222C3; Mon, 20 Feb 2023 11:01:52 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id D7B0FB80DC7; Mon, 20 Feb 2023 19:00:01 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id DB716C4339B; Mon, 20 Feb 2023 18:59:59 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1676919600; bh=ts6SEtewZVGy5pgs+9q4VeqLaHWaM9C2UcAoTTVBen0=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=W/0mig6dnpdhlKG/yjNPcaj6ORSK7jpUwuqgGLP2rWYhVuCVy29pCWkORoV9hc5Es IuSoZgw+VVtLOUxsO9okNlJVVaSS7njpHl+JFM+Diaa4bPbFKwue+y9VZ2nvE2C+IW v57ZCjidGvDg/eZpJY5woOP+F7C6diLCRFWCy6rYk2MrcMU1e6/MzHQMdFZXLjqVud yllLKtwYFNgU3vKANxLxX7UTfS4I22j1hI3+ipWabnukQWIKTbqQWaoezS0dFEGeOF sDN/m5JSK5FpHP5KmuKekhNyr0A9MWP1xQzFjSK6SCQfMhOoJPt1x/bKtUKLSjHVx3 m+TYhTBNmq+bw== Date: Mon, 20 Feb 2023 10:59:57 -0800 From: Josh Poimboeuf To: KP Singh Cc: Borislav Petkov , linux-kernel@vger.kernel.org, pjt@google.com, evn@google.com, tglx@linutronix.de, mingo@redhat.com, dave.hansen@linux.intel.com, x86@kernel.org, hpa@zytor.com, peterz@infradead.org, pawan.kumar.gupta@linux.intel.com, kim.phillips@amd.com, alexandre.chartre@oracle.com, daniel.sneddon@linux.intel.com, =?utf-8?B?Sm9zw6k=?= Oliveira , Rodrigo Branco , Alexandra Sandulescu , Jim Mattson , stable@vger.kernel.org Subject: Re: [PATCH] x86/bugs: Allow STIBP with IBRS Message-ID: <20230220185957.yzjdnhcqpmkji2xs@treble> References: <20230220120127.1975241-1-kpsingh@kernel.org> <20230220121350.aidsipw3kd4rsyss@treble> <20230220163442.7fmaeef3oqci4ee3@treble> <20230220175929.2laflfb2met6y3kc@treble> <20230220182717.uzrym2gtavlbjbxo@treble> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Feb 20, 2023 at 10:33:56AM -0800, KP Singh wrote: > static char *stibp_state(void) > { > - if (spectre_v2_in_ibrs_mode(spectre_v2_enabled)) > + if (!spectre_v2_user_needs_stibp(spectre_v2_enabled)) > return ""; > > switch (spectre_v2_user_stibp) { > > Also Josh, is it okay for us to have a discussion and have me write > the patch as a v2? Your current patch does not even credit me at all. > Seems a bit unfair, but I don't really care. I was going to rev up the > patch with your suggestions. Well, frankly the patch needed a complete rewrite. The patch description was unclear about what the problem is and what's being fixed. The code was obtuse and the comments didn't help. I could tell by the other replies that I wasn't the only one confused. I can give you Reported-by, or did you have some other tag in mind? -- Josh