From: Kees Cook Subject: Re: [RFC PATCH 5/5] selftest/x86: Add CET quick test Date: Fri, 22 May 2020 10:36:00 -0700 Message-ID: <202005221034.59F5DF75@keescook> References: <20200521211720.20236-1-yu-cheng.yu@intel.com> <20200521211720.20236-6-yu-cheng.yu@intel.com> <20200522092848.GJ325280@hirez.programming.kicks-ass.net> <202005221020.B578B8C6@keescook> <20200522172711.GA317569@hirez.programming.kicks-ass.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Content-Disposition: inline In-Reply-To: <20200522172711.GA317569@hirez.programming.kicks-ass.net> Sender: linux-kernel-owner@vger.kernel.org To: Peter Zijlstra Cc: Yu-cheng Yu , x86@kernel.org, "H. Peter Anvin" , Thomas Gleixner , Ingo Molnar , linux-kernel@vger.kernel.org, linux-doc@vger.kernel.org, linux-mm@kvack.org, linux-arch@vger.kernel.org, linux-api@vger.kernel.org, Arnd Bergmann , Andy Lutomirski , Balbir Singh , Borislav Petkov , Cyrill Gorcunov , Dave Hansen , Eugene Syromiatnikov , Florian Weimer , "H.J. Lu" , Jann Horn , Jonathan Corbet , Mike Kravetz , Nadav Amit List-Id: linux-arch.vger.kernel.org On Fri, May 22, 2020 at 07:27:11PM +0200, Peter Zijlstra wrote: > On Fri, May 22, 2020 at 10:22:51AM -0700, Kees Cook wrote: > > > But yes, I think getting a copy of asm.h would be nice here. I don't > > think the WRITE_ONCE() is needed in this particular case. Hmm. > > Paranoia on my end because I had no clue wth he wanted with his -O0 > magic gunk. Heh, yes, which is why I asked for many more comments. ;) I *think* it was entirely to control the stack (and ssp) behavior (i.e. don't inline, don't elide unused stack variables, etc). -- Kees Cook