blob: ff93adbc70b8abdc4c5973e822502b900715eec3 [file] [log] [blame]
Stefan Reinauer14e22772010-04-27 06:56:47 +00001/*
Stefan Reinauer10b29d82010-04-09 10:12:18 +00002 * Copyright 2002 Eric Biederman
Patrick Georgi3c970ee2010-02-19 19:59:03 +00003 *
4 * This file is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU General Public License as
Stefan Reinauer10b29d82010-04-09 10:12:18 +00006 * published by the Free Software Foundation; version 2 of the License.
Patrick Georgi3c970ee2010-02-19 19:59:03 +00007 */
Alexandru Gagniuc5005bb062011-04-11 20:17:22 +00008#include <cpu/x86/post_code.h>
Patrick Georgi3c970ee2010-02-19 19:59:03 +00009
Patrick Georgi3c970ee2010-02-19 19:59:03 +000010__main:
Alexandru Gagniuc5005bb062011-04-11 20:17:22 +000011 post_code(POST_PREPARE_RAMSTAGE)
Stefan Reinauer10b29d82010-04-09 10:12:18 +000012 cld /* clear direction flag */
Stefan Reinauer14e22772010-04-27 06:56:47 +000013
Kyösti Mälkki1729cd82014-10-16 12:47:25 +030014 movl $CONFIG_RAMTOP, %esp
Patrick Georgi3c970ee2010-02-19 19:59:03 +000015 movl %esp, %ebp
Stefan Reinauer10b29d82010-04-09 10:12:18 +000016 call copy_and_run
Patrick Georgi3c970ee2010-02-19 19:59:03 +000017
Stefan Reinauer14e22772010-04-27 06:56:47 +000018.Lhlt:
Alexandru Gagniuc5005bb062011-04-11 20:17:22 +000019 post_code(POST_DEAD_CODE)
Patrick Georgi3c970ee2010-02-19 19:59:03 +000020 hlt
21 jmp .Lhlt