blob: 2beaacd1f896132dee8dbf4d22676d49389acbd3 [file] [log] [blame]
David Hendricks50c0a502013-01-31 17:05:50 -08001/*
2 * This file is part of the coreboot project.
3 *
Stefan Reinauere8b08ba2013-05-24 15:09:36 -07004 * Copyright 2012 Google Inc.
David Hendricks50c0a502013-01-31 17:05:50 -08005 *
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; version 2 of the License.
9 *
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
Stefan Reinauere8b08ba2013-05-24 15:09:36 -070014 */
15
16/*
David Hendricks50c0a502013-01-31 17:05:50 -080017 * This file contains entry/exit functions for each stage during coreboot
18 * execution (bootblock entry and ramstage exit will depend on external
Julius Wernerfd9defc2014-01-21 20:11:22 -080019 * loading).
David Hendricks50c0a502013-01-31 17:05:50 -080020 *
Julius Wernerec5e5e02014-08-20 15:29:56 -070021 * Entry points should be set in the linker script and honored by CBFS,
22 * so text section layout shouldn't matter. Still, it doesn't hurt to put
23 * stage_entry first (which XXXstage.ld will do automatically through the
24 * .text.stage_entry section created by -ffunction-sections).
David Hendricks50c0a502013-01-31 17:05:50 -080025 */
26
27#include <arch/stages.h>
David Hendricksbba80902013-03-14 15:24:57 -070028#include <arch/cache.h>
David Hendricks50c0a502013-01-31 17:05:50 -080029
Daisuke Nojiri53b74f62014-12-30 08:55:30 -080030/**
31 * generic stage entry point. override this if board specific code is needed.
32 */
33__attribute__((weak)) void stage_entry(void)
David Hendricks50c0a502013-01-31 17:05:50 -080034{
35 main();
36}