All of lore.kernel.org
 help / color / mirror / Atom feed
From: shawn.guo@linaro.org (Shawn Guo)
To: linux-arm-kernel@lists.infradead.org
Subject: Build LSK 3.14 kernel with android-toolchain
Date: Tue, 2 Dec 2014 20:04:32 +0800	[thread overview]
Message-ID: <20141202120430.GE2411@dragon> (raw)
In-Reply-To: <2048273.C5mPR68Ukg@wuerfel>

On Tue, Dec 02, 2014 at 11:24:03AM +0100, Arnd Bergmann wrote:
> > > I tracked it a little bit with debug_ll routine printch() and found it
> > > dies at the first pr_info() call in arch/arm/kernel/setup.c:
> > > 
> > >       pr_info("Booting Linux on physical CPU 0x%x\n", mpidr);
> > > 
> > > And I spent some time to find out that the issue was introduced by
> > > commit dad5451a322b (ARM: 7605/1: vmlinux.lds: Move .notes section
> > > next to the rodata) since v3.8 release.  Reverting the commit helps me
> > > to get a booting kernel that is built by arm-linux-androideabi
> > > toolchain.  But I do not have the knowledge to understand what is
> > > happening.
> > > 
> > 
> > From my experience in last several years
> > 
> > 1. the arm-linux-androideabi- toolchain sets some options by default, PIC for
> > example, even -mno-android can't disable all the side effects per my test.
> 
> Yes, that's definitely possible. Any idea how the android folks build their
> kernel?
> 
> > 2. the arm-linux-eandroideabi- toolchain use gold for linker by default. Maybe
> > gold can't understand vmlinux.lds correctly?
> 
> That would be very easy to test, just set LD=${CROSS_COMPILE}ld.bfd on the
> command line and rebuild. In my testing, I've encountered a number of different
> bugs in both ld.bfd and ld.gold that prevent you from building the kernel.

Yes, either reverting commit dad5451a322b (ARM: 7605/1: vmlinux.lds:
Move .notes section next to the rodata) or building kernel with
LD=${CROSS_COMPILE}ld.bfd get me a working kernel.

Shawn

      parent reply	other threads:[~2014-12-02 12:04 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CAAQ0ZWRQ05GiCOqV2Q6g2B6n+XN-qs9o6MKOFXiK2wKrW0nvog@mail.gmail.com>
     [not found] ` <2052560.M0NHOo7Rnz@wuerfel>
2014-12-02  9:04   ` Build LSK 3.14 kernel with android-toolchain Shawn Guo
2014-12-02  9:39     ` Jisheng Zhang
2014-12-02 10:24       ` Arnd Bergmann
2014-12-02 10:29         ` Jisheng Zhang
2014-12-02 12:34           ` Shawn Guo
2014-12-02 13:04             ` Arnd Bergmann
2014-12-02 13:03           ` Arnd Bergmann
2014-12-02 12:04         ` Shawn Guo [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=20141202120430.GE2411@dragon \
    --to=shawn.guo@linaro.org \
    --cc=linux-arm-kernel@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.