Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
To: buildroot@busybox.net
Subject: [Buildroot] [PATCH 1/2] gcc: backport upstream patch for sync_8 in !glibc
Date: Sat, 26 Nov 2016 15:27:06 +0100	[thread overview]
Message-ID: <20161126152706.0f1366d7@free-electrons.com> (raw)
In-Reply-To: <20161121234340.30463-1-arnout@mind.be>

Hello,

On Tue, 22 Nov 2016 00:43:39 +0100, Arnout Vandecappelle
(Essensium/Mind) wrote:
> gcc 4.7 introduced the sync_8 builtin functions for ARM. For ARM < v7,
> this requires calling into the kernel. However, the failure path of
> that call reports an error with the __write() function, which is a
> glibc internal function. Therefore, it fails to link with uClibc or
> musl. This was fixed in gcc 5.2.0, by replacing the __write() with
> a plain write().
> 
> For sync_8 itself we have solved this with the conditions on
> BR2_TOOLCHAIN_ARM_HAS_SYNC_8. However, the same function is also used
> for the implementation of atomics.
> 
> For the internal toolchain, we can fix this by backporting the patch
> to 4.9.4 and 4.8.5.
> 
> Fixes:
> http://autobuild.buildroot.net/results/1db64b4830f499621e44523e0ef68191505e2ce9
> 
> Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
> ---
>  ...et-68059-libgcc-should-not-use-__write-fo.patch | 43 ++++++++++++++++++++++
>  ...et-68059-libgcc-should-not-use-__write-fo.patch | 43 ++++++++++++++++++++++
>  2 files changed, 86 insertions(+)
>  create mode 100644 package/gcc/4.8.5/0001-ARM-PR-target-68059-libgcc-should-not-use-__write-fo.patch
>  create mode 100644 package/gcc/4.9.4/0001-ARM-PR-target-68059-libgcc-should-not-use-__write-fo.patch

Applied to master, thanks.

Thomas
-- 
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com

      parent reply	other threads:[~2016-11-26 14:27 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-11-21 23:43 [Buildroot] [PATCH 1/2] gcc: backport upstream patch for sync_8 in !glibc Arnout Vandecappelle
2016-11-21 23:43 ` [Buildroot] [PATCH 2/2] toolchain: simplify the conditions for BR2_TOOLCHAIN_ARM_HAS_SYNC_8 Arnout Vandecappelle
2016-11-22  8:35   ` Thomas Petazzoni
2016-11-24 23:13     ` Arnout Vandecappelle
2016-11-25  8:56       ` Thomas Petazzoni
2016-12-08 21:44       ` Thomas Petazzoni
2016-11-26 14:27 ` Thomas Petazzoni [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=20161126152706.0f1366d7@free-electrons.com \
    --to=thomas.petazzoni@free-electrons.com \
    --cc=buildroot@busybox.net \
    /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