All of lore.kernel.org
 help / color / mirror / Atom feed
From: Vivek Goyal <vgoyal@in.ibm.com>
To: "Eric W. Biederman" <ebiederm@xmission.com>
Cc: Andrew Morton <akpm@linux-foundation.org>,
	Jurriaan <thunder7@xs4all.nl>,
	Helge Hafting <helgehaf@aitel.hist.no>,
	linux-kernel@vger.kernel.org, Magnus Damm <magnus@valinux.co.jp>,
	Horms <horms@verge.net.au>
Subject: Re: 2.6.21-rc5-mm3 - no boot, "address not 2M aligned"
Date: Tue, 3 Apr 2007 15:33:49 +0530	[thread overview]
Message-ID: <20070403100349.GA21759@in.ibm.com> (raw)
In-Reply-To: <m1zm5qc9q2.fsf@ebiederm.dsl.xmission.com>

On Mon, Apr 02, 2007 at 11:23:17PM -0600, Eric W. Biederman wrote:
> Vivek Goyal <vgoyal@in.ibm.com> writes:
> 
> >> I guess at this point the easy case is that we modify /sbin/kexec to support
> >> it.  And the other bootloaders can come be upgraded if the feature is
> >> interesting enough.
> >> 
> >> > On i386, somebody already found an interesting usage of
> > CONFIG_PHYSICAL_START
> >> > where he was running his kernel above 16MB so that he can maximize on
> >> > DMA ZONE. Can't think of any usage for x86_64 at the moment but I think
> >> > down the line people might come up with such usages.
> >> 
> >> Agreed.  We do have CONFIG_PHYSICAL_ALIGN that can handle that case,
> >> although I admit that is a bit of a hack.
> >> 
> >
> > Yes, but x86_64 will not have any of those options and only way to run 
> > kernel will be either use kexec or modify your boot-loader to so that
> > it can handle relocatable images.
> 
> True.
> 
> >> > To me, retaining CONFIG_PHYSICAL_START gives added flexibility to the user,
> >> > at the expense of reduced simplicity. We should definitely change the type
> >> > of vmlinux to ET_DYN but at the same time it might still be worth to retain
> >> > CONFIG_PHYSICAL_START option.
> >> 
> >> I think something like CONFIG_PHYSICAL_START currently gives us very
> >> little gain, and is hard to use correctly, and there are alternative
> >> solutions.  So if we can get rid of it, by only inconveniencing users
> >> who want load their kernels at a weird address it is worth it.
> >> 
> >> >> I think I can switch the vmlinux header type in about 100 lines or so
> >> >> of code.  Assuming I can ever get 30 minutes with the appropriate
> >> >> kernel.
> >> >> 
> >> >
> >> > That would be awesome. Then vmlinux will be relocatable too. (Officially).
> >> 
> >> Yes.  For x86_64 I can do this.  i386 is more difficult.  (Although with
> >> a little cleverness we can move the code that processes relocations into
> >> vmlinux).  
> >> 
> >
> > Performing relocations in vmlinux will be interesting. That way i386 vmlinux
> > too will become relocatable and only piece of puzzle to solve will be to
> > make vmlinux of type ET_DYN.
> 
> Actually making vmlinux have type ET_DYN is the easier piece.  Basically
> the quick way to do this is to have an arch specific: "cmd_vmlinux__"
> like uml does so we can edit things after the make.
> 
> Changing an integer in an ELF header is simple.
> 
> Inserting the code to perform the relocations feels a bit trickier but
> we can probably just dump it in head.S like we do on x86_64.  We still need
> to insert the actual relocations to process though.  Which requires all of the
> post processing we currently do just called at a slightly different location.

Something like what kallsyms does? Read .tmp_vmlinux2, extract and
filter relocations, pack them in relocs.S, build reloc.o and relink it back
to .tmp_vmlinux2 to make vmlinux. Then arch/i386/kernel/head.S can perform
the relocations. But any additiona step of re-linking after final kallsyms
information has been generated can potentially spoil kallsyms data?

Thanks
Vivek

  reply	other threads:[~2007-04-03 10:04 UTC|newest]

Thread overview: 59+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-03-30  8:05 2.6.21-rc5-mm3 Andrew Morton
2007-03-30 11:00 ` 2.6.21-rc5-mm3 Rafael J. Wysocki
2007-03-30 16:31 ` 2.6.21-rc5-mm3 Michal Piotrowski
2007-03-30 16:55   ` 2.6.21-rc5-mm3 Ingo Molnar
2007-03-30 17:19     ` 2.6.21-rc5-mm3 Michal Piotrowski
2007-03-30 16:38 ` 2.6.21-rc5-mm3 Dmitry Torokhov
2007-03-30 16:59   ` 2.6.21-rc5-mm3 Andrew Morton
2007-03-30 17:23 ` 2.6.21-rc5-mm3 Valdis.Kletnieks
2007-03-30 18:58   ` 2.6.21-rc5-mm3 Johannes Berg
2007-03-31  7:12 ` 2.6.21-rc5-mm3 - no boot, "address not 2M aligned" Helge Hafting
2007-03-31  7:53   ` Andrew Morton
2007-03-31  8:14     ` Eric W. Biederman
2007-04-09 22:09       ` Helge Hafting
2007-04-10  4:48         ` Helge Hafting
2007-04-01  5:29     ` thunder7
2007-04-01  6:15       ` Eric W. Biederman
2007-04-01  6:29         ` Andrew Morton
2007-04-02  7:41           ` Vivek Goyal
2007-04-02  8:43             ` Eric W. Biederman
2007-04-02  9:45               ` Vivek Goyal
2007-04-02 17:26                 ` Eric W. Biederman
2007-04-03  4:01                   ` Vivek Goyal
2007-04-03  5:23                     ` Eric W. Biederman
2007-04-03 10:03                       ` Vivek Goyal [this message]
2007-04-23  5:12                         ` [PATCH 1/2] x86_64: Reflect the relocatability of the kernel in the ELF header Eric W. Biederman
2007-04-23  5:12                           ` Eric W. Biederman
2007-04-23  5:15                           ` [PATCH 2/2] x86_64: Remove CONFIG_PHYSICAL_START and CONFIG_RELOCATABLE Eric W. Biederman
2007-04-23  5:15                             ` Eric W. Biederman
2007-04-23  6:07                             ` Vivek Goyal
2007-04-23  6:07                               ` Vivek Goyal
2007-04-23  6:17                               ` Eric W. Biederman
2007-04-23  6:17                                 ` Eric W. Biederman
2007-04-23  6:25                                 ` Vivek Goyal
2007-04-23  6:25                                   ` Vivek Goyal
2007-04-24  6:31                           ` [PATCH 1/2] x86_64: Reflect the relocatability of the kernel in the ELF header Vivek Goyal
2007-04-24  6:31                             ` Vivek Goyal
2007-04-24  7:21                             ` Eric W. Biederman
2007-04-24  7:21                               ` Eric W. Biederman
2007-04-02 11:17             ` 2.6.21-rc5-mm3 - no boot, "address not 2M aligned" thunder7
2007-04-02 11:36               ` Vivek Goyal
2007-04-02 14:49                 ` thunder7
2007-04-02 14:59                   ` thunder7
2007-04-03  4:05                     ` Vivek Goyal
2007-03-31  8:05 ` 2.6.21-rc5-mm3 - cpuidle, acpi, and C-states Valdis.Kletnieks
2007-03-31 19:25 ` 2.6.21-rc5-mm3: Why was my vioc cleanup patch dropped? Adrian Bunk
2007-03-31 20:48 ` [-mm patch] make drivers/ata/pata_ali.c:ali_tf_load() static Adrian Bunk
2007-04-01 16:21   ` Tejun Heo
2007-03-31 20:55 ` [2.6 patch] remove the config option for the cs5530a_warm_reset() quirk Adrian Bunk
2007-03-31 21:05   ` Jeremy Fitzhardinge
2007-03-31 21:11     ` Adrian Bunk
2007-03-31 21:17       ` Jeremy Fitzhardinge
2007-03-31 20:55 ` [-mm patch] make drivers/net/qla3xxx.c:PHY_DEVICES[] static Adrian Bunk
2007-04-04  2:34   ` Jeff Garzik
2007-03-31 20:55 ` [-mm patch] make struct proc_fdinfo_file_operations static Adrian Bunk
2007-04-01 16:00 ` 2.6.21-rc5-mm3 Michal Piotrowski
2007-04-01 19:03   ` 2.6.21-rc5-mm3 Andrew Morton
2007-04-01 20:39     ` 2.6.21-rc5-mm3 Rafael J. Wysocki
2007-04-01 20:56       ` 2.6.21-rc5-mm3 Rafael J. Wysocki
2007-04-01 21:59       ` 2.6.21-rc5-mm3 Rafael J. Wysocki

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=20070403100349.GA21759@in.ibm.com \
    --to=vgoyal@in.ibm.com \
    --cc=akpm@linux-foundation.org \
    --cc=ebiederm@xmission.com \
    --cc=helgehaf@aitel.hist.no \
    --cc=horms@verge.net.au \
    --cc=linux-kernel@vger.kernel.org \
    --cc=magnus@valinux.co.jp \
    --cc=thunder7@xs4all.nl \
    /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.