From: geoff@infradead.org (Geoff Levand)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 1/9] arm64: Fix efi kernel entry
Date: Tue, 26 Aug 2014 11:42:54 -0700 [thread overview]
Message-ID: <1409078574.11425.29.camel@smoke> (raw)
In-Reply-To: <CAKv+Gu8V1xXtGZm5ae+NiFGDuNr20TUBhL=vCgQ6J2S5CQJakg@mail.gmail.com>
Hi,
On Tue, 2014-08-26 at 18:19 +0200, Ard Biesheuvel wrote:
> First of all, the 'add x13, x18, #0x16' was carefully chosen to be
> both a "MZ" prefix and an executable instruction without any harmful
> side effects.
OK, I didn't look so closely to realize this was an instruction with out
side effects.
> So currently, the EFI stub jumps to that add
> instruction, and not to the 'b stext' that comes after. There is an
> issue with that, which I have already proposed a patch for (arm64/efi:
> efistub: jump to 'stext' directly, not through the header), but this
> is related to the guarantees the UEFI spec gives about where the
> header gets loaded (if at all).
>
> However, going back to your patch, setting ENTRY() only affects the
> vmlinux ELF image, and this information gets stripped when creating
> the binary. Do you need the entry point to be set so you can load
> vmlinux using the debugger, perhaps? In that case, did you have any
> problems branching to the add instruction? If so, I would like to know
> about it.
kexec-tools [1] can load vmlinux elf files, and uses ehdr.e_entry as the
kernel entry point. I tested without this patch (branching to _text),
and it works OK, so we can drop this patch.
-Geoff
[1] https://git.linaro.org/people/geoff.levand/kexec-tools.git
-Geoff
next prev parent reply other threads:[~2014-08-26 18:42 UTC|newest]
Thread overview: 37+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-08-22 19:49 [PATCH 0/9] arm64: minor fixups and enhancements Geoff Levand
2014-08-22 19:49 ` [PATCH 1/9] arm64: Fix efi kernel entry Geoff Levand
2014-08-26 15:55 ` Catalin Marinas
2014-08-26 16:19 ` Ard Biesheuvel
2014-08-26 18:42 ` Geoff Levand [this message]
2014-08-22 19:49 ` [PATCH 5/9] arm64: Fix include header order in vmlinux.lds.S Geoff Levand
2014-08-26 16:27 ` Mark Rutland
2014-08-26 19:27 ` Geoff Levand
2014-08-27 8:24 ` Catalin Marinas
2014-08-29 21:53 ` Geoff Levand
2014-08-22 19:49 ` [PATCH 4/9] arm64: Remove unused variable in head.S Geoff Levand
2014-08-27 8:40 ` Will Deacon
2014-08-22 19:49 ` [PATCH 3/9] arm64: Remove unneeded extern keyword Geoff Levand
2014-08-26 16:11 ` Mark Rutland
2014-08-22 19:49 ` [PATCH 6/9] arm64: Add new routine local_disable Geoff Levand
2014-08-26 16:04 ` Catalin Marinas
2014-08-26 16:23 ` Mark Rutland
2014-08-22 19:49 ` [PATCH 7/9] arm64: Add atomic macros to assembler.h Geoff Levand
2014-08-26 16:05 ` Catalin Marinas
2014-08-26 19:40 ` Geoff Levand
2014-08-27 8:25 ` Catalin Marinas
2014-08-22 19:49 ` [PATCH 2/9] arm64: Fix INVALID_HWID definition Geoff Levand
2014-08-26 15:57 ` Catalin Marinas
2014-08-26 18:18 ` Geoff Levand
2014-08-27 8:21 ` Catalin Marinas
2014-08-26 16:31 ` Mark Rutland
2014-08-26 17:38 ` Geoff Levand
2014-08-22 19:49 ` [PATCH 9/9] arm64: Add new cpu-return-addr device tree binding Geoff Levand
2014-08-22 19:49 ` Geoff Levand
2014-08-27 8:30 ` Catalin Marinas
2014-08-27 8:30 ` Catalin Marinas
2014-08-29 21:45 ` Geoff Levand
2014-08-29 21:45 ` Geoff Levand
2014-08-22 19:49 ` [PATCH 8/9] arm64: Add missing AT() macros to vmlinux.lds.S Geoff Levand
2014-08-26 16:08 ` Catalin Marinas
2014-08-26 19:33 ` Geoff Levand
2014-08-27 6:53 ` AKASHI Takahiro
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=1409078574.11425.29.camel@smoke \
--to=geoff@infradead.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.