mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: Sascha Hauer <sha@pengutronix.de>
To: Ahmad Fatoum <a.fatoum@pengutronix.de>
Cc: Ahmad Fatoum <ahmad@a3f.at>, barebox@lists.infradead.org
Subject: Re: [PATCH 1/2] kbuild: add '-fno-stack-check' to barebox build options
Date: Mon, 22 Mar 2021 06:12:16 +0100	[thread overview]
Message-ID: <20210322051216.GL23724@pengutronix.de> (raw)
In-Reply-To: <f639c838-e999-7a9b-ed03-7fd46c9e6fad@pengutronix.de>

On Tue, Mar 16, 2021 at 08:10:45PM +0100, Ahmad Fatoum wrote:
> Hello Sascha,
> 
> On 24.02.21 09:49, Sascha Hauer wrote:
> > On Tue, Feb 23, 2021 at 08:24:26AM +0100, Ahmad Fatoum wrote:
> >> This ports over Linux commit 3ce120b16cc5 ("kbuild: add
> >> '-fno-stack-check' to kernel build options"):
> >>
> >>   Author:     Linus Torvalds <torvalds@linux-foundation.org>
> >>
> >>     kbuild: add '-fno-stack-check' to kernel build options
> >>
> >>     It appears that hardened gentoo enables "-fstack-check" by default for
> >>     gcc.
> >>
> >>     That doesn't work _at_all_ for the kernel, because the kernel stack
> >>     doesn't act like a user stack at all: it's much smaller, and it doesn't
> >>     auto-expand on use.  So the extra "probe one page below the stack" code
> >>     generated by -fstack-check just breaks the kernel in horrible ways,
> >>     causing infinite double faults etc.
> >>
> >>     [ I have to say, that the particular code gcc generates looks very
> >>       stupid even for user space where it works, but that's a separate
> >>       issue.  ]
> >>
> >>     Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
> >>
> >> I am porting it, because it may become more acute with the incoming
> >> support for multiple stacks (via initjmp).
> >>
> >> Signed-off-by: Ahmad Fatoum <ahmad@a3f.at>
> >> ---
> > 
> > Applied, thanks
> 
> Can't find both patches in next.

They should be there now.

Sascha

-- 
Pengutronix e.K.                           |                             |
Steuerwalder Str. 21                       | http://www.pengutronix.de/  |
31137 Hildesheim, Germany                  | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox


      reply	other threads:[~2021-03-22  5:13 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-23  7:24 Ahmad Fatoum
2021-02-23  7:24 ` [PATCH 2/2] kbuild: add '-fcf-protection=none' " Ahmad Fatoum
2021-02-24  8:49 ` [PATCH 1/2] kbuild: add '-fno-stack-check' " Sascha Hauer
2021-03-16 19:10   ` Ahmad Fatoum
2021-03-22  5:12     ` Sascha Hauer [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210322051216.GL23724@pengutronix.de \
    --to=sha@pengutronix.de \
    --cc=a.fatoum@pengutronix.de \
    --cc=ahmad@a3f.at \
    --cc=barebox@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox