Re: [PATCH 6/6] s390: introduce execute-trampolines for branches

2018-02-08 Thread Masahiro Yamada
2018-02-08 9:57 GMT+09:00 Kees Cook : > On Thu, Feb 8, 2018 at 10:44 AM, Masahiro Yamada > wrote: >> 2018-02-08 2:55 GMT+09:00 Linus Torvalds : >>> What I would really want - and this is entirely unrelated to this >>> particular case - is to have those damn compiler option tests as part >>> of the

Re: [PATCH 6/6] s390: introduce execute-trampolines for branches

2018-02-07 Thread Kees Cook
On Thu, Feb 8, 2018 at 10:44 AM, Masahiro Yamada wrote: > 2018-02-08 2:55 GMT+09:00 Linus Torvalds : >> What I would really want - and this is entirely unrelated to this >> particular case - is to have those damn compiler option tests as part >> of the config phase in general. We now have about a

Re: [PATCH 6/6] s390: introduce execute-trampolines for branches

2018-02-07 Thread Linus Torvalds
On Wed, Feb 7, 2018 at 3:44 PM, Masahiro Yamada wrote: > > I agreed this before, and still motivated. > (because I also motivated to remove kbuild cache. I actually wish I still had my old "run shell script" thing. I had some very preliminary patches that actually worked for simple things, and yo

Re: [PATCH 6/6] s390: introduce execute-trampolines for branches

2018-02-07 Thread Masahiro Yamada
2018-02-08 2:55 GMT+09:00 Linus Torvalds : > On Wed, Feb 7, 2018 at 4:17 AM, Martin Schwidefsky > wrote: >>> That isn't, though. Linus asked us to drop the $(warning) part. >>> >>> ... and then spent a week building with a non-retpoline compiler and >>> not noticing, so he might have changed his m

Re: [PATCH 6/6] s390: introduce execute-trampolines for branches

2018-02-07 Thread Linus Torvalds
On Wed, Feb 7, 2018 at 4:17 AM, Martin Schwidefsky wrote: >> That isn't, though. Linus asked us to drop the $(warning) part. >> >> ... and then spent a week building with a non-retpoline compiler and >> not noticing, so he might have changed his mind ;) > > I found the warning to have some value,

Re: [PATCH 6/6] s390: introduce execute-trampolines for branches

2018-02-07 Thread David Woodhouse
On Wed, 2018-02-07 at 13:17 +0100, Martin Schwidefsky wrote: > On Wed, 07 Feb 2018 12:07:55 + > David Woodhouse wrote: > > > > > On Wed, 2018-02-07 at 11:07 +0100, Pavel Machek wrote: > > > > > > This is really unfortunate naming of kernel option. > > > > > > spectre_v2=off sounds like w

Re: [PATCH 6/6] s390: introduce execute-trampolines for branches

2018-02-07 Thread Martin Schwidefsky
On Wed, 07 Feb 2018 12:07:55 + David Woodhouse wrote: > On Wed, 2018-02-07 at 11:07 +0100, Pavel Machek wrote: > > This is really unfortunate naming of kernel option. > > > > spectre_v2=off sounds like we are turning the "bug" off, but i somehow > > suspect you are turning the bug _workaroun

Re: [PATCH 6/6] s390: introduce execute-trampolines for branches

2018-02-07 Thread David Woodhouse
On Wed, 2018-02-07 at 11:07 +0100, Pavel Machek wrote: > This is really unfortunate naming of kernel option. > > spectre_v2=off sounds like we are turning the "bug" off, but i somehow > suspect you are turning the bug _workaround_ off. That's consistent with what we have on x86. > > +ifdef CON

Re: [PATCH 6/6] s390: introduce execute-trampolines for branches

2018-02-07 Thread Martin Schwidefsky
On Wed, 7 Feb 2018 11:07:26 +0100 Pavel Machek wrote: > On Wed 2018-02-07 08:00:11, Martin Schwidefsky wrote: > > Add CONFIG_EXPOLINE to enable the use of the new -mindirect-branch= and > > -mfunction_return= compiler options to create a kernel fortified against > > the specte v2 attack. > > > >

Re: [PATCH 6/6] s390: introduce execute-trampolines for branches

2018-02-07 Thread Pavel Machek
On Wed 2018-02-07 08:00:11, Martin Schwidefsky wrote: > Add CONFIG_EXPOLINE to enable the use of the new -mindirect-branch= and > -mfunction_return= compiler options to create a kernel fortified against > the specte v2 attack. > > With CONFIG_EXPOLINE=y all indirect branches will be issued with an