All of lore.kernel.org
 help / color / mirror / Atom feed
From: ebiederm@xmission.com (Eric W. Biederman)
To: Vivek Goyal <vgoyal@redhat.com>
Cc: Kexec Mailing List <kexec@lists.infradead.org>
Subject: Re: Query regarding ELF loader arg style
Date: Tue, 14 Jan 2014 17:42:13 -0800	[thread overview]
Message-ID: <87a9eyaumi.fsf@xmission.com> (raw)
In-Reply-To: <20140109153703.GE25897@redhat.com> (Vivek Goyal's message of "Thu, 9 Jan 2014 10:37:03 -0500")

Vivek Goyal <vgoyal@redhat.com> writes:

> Hi Eric,
>
> I am looking at kexec ELF loader code and wondering what are arg style
> options.
>
> #define ARG_STYLE_ELF   0
> #define ARG_STYLE_LINUX 1
> #define ARG_STYLE_NONE  2
>
>
> I have looked at them many a times but frankly never fully understood
> what do they represent and what's the intention behind them. Can you
> please elaborate a bit on this.

There is no standard of what kind of arguments a standalone ELF
executable will receive from a bootloader.

Which means that in practice to support different OS's you either need
to pass nothing or make something up.

ARG_STYLE_ELF is my own invention and a sad attempt at coming up with an
OS agnostic standard.

ARG_STYLE_LINUX is an ELF image receiving the same arguments as the
linux kernel.  It is a mess but it is reasonably well documented.

ARG_STYLE_NONE should just be simpley passing nothing into an ELF image.

When moving the code into the kernel we should be able to simply use
ARG_STYLE_LINUX.  We can revist the other cases if there is ever a need.

The problem is real but I don't know if it needs to be solved any time soon.

Eric


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

  reply	other threads:[~2014-01-15  1:43 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-01-09 15:37 Query regarding ELF loader arg style Vivek Goyal
2014-01-15  1:42 ` Eric W. Biederman [this message]
2014-01-16 15:13   ` Vivek Goyal
2014-01-16 23:27     ` Eric W. Biederman
2014-01-17 14:03       ` Vivek Goyal
2014-01-17 18:03         ` Eric W. Biederman

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=87a9eyaumi.fsf@xmission.com \
    --to=ebiederm@xmission.com \
    --cc=kexec@lists.infradead.org \
    --cc=vgoyal@redhat.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.