diff options
author | Mark Kettenis <kettenis@cvs.openbsd.org> | 2016-06-21 15:39:52 +0000 |
---|---|---|
committer | Mark Kettenis <kettenis@cvs.openbsd.org> | 2016-06-21 15:39:52 +0000 |
commit | 5d692b9ad6122991afa12698bc3d53b574ee66fa (patch) | |
tree | 356098f8d29e1c789b01da7550c1c3d7c9ad1c8f | |
parent | 4f908dbab81e31a5ed85d33cfc5f13efa43a042f (diff) |
Remove code to generate uboot tags. It hardcoded information for a single
board and a device tree is required by our kernel now.
ok patrick@, jsg@
-rw-r--r-- | sys/arch/armv7/stand/efiboot/exec.c | 62 |
1 files changed, 1 insertions, 61 deletions
diff --git a/sys/arch/armv7/stand/efiboot/exec.c b/sys/arch/armv7/stand/efiboot/exec.c index 5e6b77abd9c..76bdd29f040 100644 --- a/sys/arch/armv7/stand/efiboot/exec.c +++ b/sys/arch/armv7/stand/efiboot/exec.c @@ -1,4 +1,4 @@ -/* $OpenBSD: exec.c,v 1.7 2016/05/17 23:16:10 kettenis Exp $ */ +/* $OpenBSD: exec.c,v 1.8 2016/06/21 15:39:51 kettenis Exp $ */ /* * Copyright (c) 2006, 2016 Mark Kettenis @@ -18,7 +18,6 @@ #include <sys/param.h> #include <sys/reboot.h> -#include <machine/bootconfig.h> #include <dev/cons.h> #include <lib/libkern/libkern.h> @@ -31,53 +30,8 @@ #include "efiboot.h" #include "libsa.h" -extern void *fdt; - typedef void (*startfuncp)(void *, void *, void *) __attribute__ ((noreturn)); -struct uboot_tag_header { - uint32_t size; - uint32_t tag; -}; -struct uboot_tag_core { - uint32_t flags; - uint32_t pagesize; - uint32_t rootdev; -}; -struct uboot_tag_serialnr { - uint32_t low; - uint32_t high; -}; -struct uboot_tag_revision { - uint32_t rev; -}; -struct uboot_tag_mem32 { - uint32_t size; - uint32_t start; -}; -struct uboot_tag_cmdline { - char cmdline[64]; -}; - -#define ATAG_CORE 0x54410001 -#define ATAG_MEM 0x54410002 -#define ATAG_CMDLINE 0x54410009 -#define ATAG_SERIAL 0x54410006 -#define ATAG_REVISION 0x54410007 -#define ATAG_NONE 0x00000000 -struct uboot_tag { - struct uboot_tag_header hdr; - union { - struct uboot_tag_core core; - struct uboot_tag_mem32 mem; - struct uboot_tag_revision rev; - struct uboot_tag_serialnr serialnr; - struct uboot_tag_cmdline cmdline; - } u; -}; - -struct uboot_tag tags[3]; - void run_loadfile(u_long *marks, int howto) { @@ -125,20 +79,6 @@ run_loadfile(u_long *marks, int howto) *++cp = 0; fdt = efi_makebootargs(args, &board_id); - if (fdt == 0) { - tags[0].hdr.tag = ATAG_MEM; - tags[0].hdr.size = sizeof(struct uboot_tag) / sizeof(uint32_t); - tags[0].u.mem.start = 0x10000000; - tags[0].u.mem.size = 0x80000000; - tags[1].hdr.tag = ATAG_CMDLINE; - tags[1].hdr.size = sizeof(struct uboot_tag) / sizeof(uint32_t); - strlcpy(tags[1].u.cmdline.cmdline, args, - sizeof(tags[1].u.cmdline.cmdline)); - - memcpy((void *)0x10000000, tags, sizeof(tags)); - fdt = (void *)0x10000000; - board_id = 4821; - } efi_cleanup(); |