All of lore.kernel.org
 help / color / mirror / Atom feed
From: Christoph Hellwig <hch@infradead.org>
To: Anup Patel <anup@brainfault.org>
Cc: Damien Le Moal <Damien.LeMoal@wdc.com>,
	Anup Patel <anup.patel@wdc.com>,
	Palmer Dabbelt <palmer@sifive.com>,
	Mike Rapoport <rppt@linux.ibm.com>,
	Christoph Hellwig <hch@infradead.org>,
	Atish Patra <atish.patra@wdc.com>,
	linux-riscv@lists.infradead.org
Subject: Re: 32bit kernel is broken for Linux-5.1-rc1 due to GCC cmodel=medlow
Date: Sun, 24 Mar 2019 01:37:39 -0700	[thread overview]
Message-ID: <20190324083739.GA31909@infradead.org> (raw)
In-Reply-To: <CAAhSdy07GsHXpG9MJZ4aiB5uG7D+9RA+17Nb1MrWdFg9ee6rUA@mail.gmail.com>

On Sun, Mar 24, 2019 at 07:12:07AM +0530, Anup Patel wrote:
> > Just curios - if you just move setup_vm and dependencies into a new
> > file that is compiled with -mcmodel=medany, just like setup.c,
> > what issues would we still have that require explicitly passing the
> > load address?
> 
> There are four cases here:
> 1. 64bit with cmodel=medany (default for 64bit system)
> 2. 64bit with cmodel=medlow
> 3. 32bit with cmodel=medany
> 4. 32bit with cmodel=medlow (default for 32bit system)
> 
> I had tried using cmodel=medany as default for both 64bit and 32bit system
> and it works fine because there is no issue with cmodel=medany but it is a very
> crude fix and things break again if someone explicitly selects cmodel=medlow
> using kconfig.

Well.  What I meant is to override the model just for the new file
containing setup_vm, just like we explicitly override the model for
setup.c in arch/riscv/kernel/Makefile:

CFLAGS_setup.o := -mcmodel=medany

_______________________________________________
linux-riscv mailing list
linux-riscv@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-riscv

      parent reply	other threads:[~2019-03-24  8:37 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-03-22  6:16 32bit kernel is broken for Linux-5.1-rc1 due to GCC cmodel=medlow Anup Patel
2019-03-22 10:42 ` Mike Rapoport
2019-03-22 12:29   ` Anup Patel
2019-03-22 13:26     ` Christoph Hellwig
2019-03-22 13:38       ` Anup Patel
2019-03-22 13:25   ` Christoph Hellwig
2019-03-22 13:37     ` Anup Patel
2019-03-22 13:40       ` Christoph Hellwig
2019-03-22 13:45         ` Anup Patel
2019-03-23 17:21           ` Christoph Hellwig
2019-03-24  1:42             ` Anup Patel
2019-03-24  1:56               ` Gary Guo
2019-03-24  3:04                 ` Anup Patel
2019-03-24  3:10                 ` Anup Patel
2019-03-24  6:05                   ` Mike Rapoport
2019-03-24  9:41                     ` Anup Patel
2019-03-24  8:37               ` Christoph Hellwig [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=20190324083739.GA31909@infradead.org \
    --to=hch@infradead.org \
    --cc=Damien.LeMoal@wdc.com \
    --cc=anup.patel@wdc.com \
    --cc=anup@brainfault.org \
    --cc=atish.patra@wdc.com \
    --cc=linux-riscv@lists.infradead.org \
    --cc=palmer@sifive.com \
    --cc=rppt@linux.ibm.com \
    /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.