blob: 9d1e4cde5f4950f8f36a64e112dc0c00c70e0a74 [file] [log] [blame]
Stefan Reinauere8b08ba2013-05-24 15:09:36 -07001/*
2 * This file is part of the coreboot project.
3 *
Stefan Reinauere8b08ba2013-05-24 15:09:36 -07004 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation; version 2 of the License.
7 *
8 * This program is distributed in the hope that it will be useful,
9 * but WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 * GNU General Public License for more details.
Stefan Reinauere8b08ba2013-05-24 15:09:36 -070012 */
13
Gabe Blackc09cf0b2014-02-08 06:30:49 -080014#include <arch/cache.h>
Aaron Durbin04654a22015-03-17 11:43:44 -050015#include <program_loading.h>
Stefan Reinauer52db0b92012-12-07 17:15:04 -080016
Aaron Durbinb3847e62015-03-20 15:55:08 -050017void arch_prog_run(struct prog *prog)
Stefan Reinauer52db0b92012-12-07 17:15:04 -080018{
Aaron Durbin3948e532015-03-20 13:00:20 -050019 void (*doit)(void *);
Gabe Blackc09cf0b2014-02-08 06:30:49 -080020
Gabe Blackc09cf0b2014-02-08 06:30:49 -080021 cache_sync_instructions();
Aaron Durbin3948e532015-03-20 13:00:20 -050022
Aaron Durbinb3847e62015-03-20 15:55:08 -050023 doit = prog_entry(prog);
24 doit(prog_entry_arg(prog));
25}