From mboxrd@z Thu Jan 1 00:00:00 1970 From: Yu-cheng Yu Subject: Re: [RFC PATCH 5/5] selftest/x86: Add CET quick test Date: Fri, 22 May 2020 11:07:49 -0700 Message-ID: <02d825344b39891cf9c084edce44db168cce45fe.camel@intel.com> 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> <202005221034.59F5DF75@keescook> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <202005221034.59F5DF75@keescook> Sender: linux-api-owner-u79uwXL29TY76Z2rM5mHXA@public.gmane.org To: Kees Cook , Peter Zijlstra Cc: x86-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org, "H. Peter Anvin" , Thomas Gleixner , Ingo Molnar , linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-doc-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-mm-Bw31MaZKKs3YtjvyW6yDsg@public.gmane.org, linux-arch-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-api-u79uwXL29TY76Z2rM5mHXA@public.gmane.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 , Oleg Nesterov , Pavel List-Id: linux-arch.vger.kernel.org On Fri, 2020-05-22 at 10:36 -0700, Kees Cook wrote: > 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). Yes, that was the reason. Yu-cheng From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga06.intel.com ([134.134.136.31]:13909 "EHLO mga06.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726373AbgEVSIx (ORCPT ); Fri, 22 May 2020 14:08:53 -0400 Message-ID: <02d825344b39891cf9c084edce44db168cce45fe.camel@intel.com> Subject: Re: [RFC PATCH 5/5] selftest/x86: Add CET quick test From: Yu-cheng Yu Date: Fri, 22 May 2020 11:07:49 -0700 In-Reply-To: <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> <202005221034.59F5DF75@keescook> Content-Type: text/plain; charset="UTF-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Sender: linux-arch-owner@vger.kernel.org List-ID: To: Kees Cook , Peter Zijlstra Cc: 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 , Oleg Nesterov , Pavel Machek , Randy Dunlap , "Ravi V. Shankar" , Vedvyas Shanbhogue , Dave Martin , Weijiang Yang Message-ID: <20200522180749.yYR8OhYkxZF1SxcqMSU92fwcFXZC3i0H0SaAqLmc7zs@z> On Fri, 2020-05-22 at 10:36 -0700, Kees Cook wrote: > 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). Yes, that was the reason. Yu-cheng