blob: b33e9327a81d7194796471a2d938b2c4c1b0ab87 [file] [log] [blame]
Peter Stuge483b7bb2009-04-14 07:40:01 +00001/*
2 * This file is part of the coreboot project.
3 *
4 * Copyright (C) 2008 Jordan Crouse <jordan@cosmicpenguin.net>
5 *
6 * This file is dual-licensed. You can choose between:
7 * - The GNU GPL, version 2, as published by the Free Software Foundation
8 * - The revised BSD license (without advertising clause)
9 *
10 * ---------------------------------------------------------------------------
11 * This program is free software; you can redistribute it and/or modify
12 * it under the terms of the GNU General Public License as published by
13 * the Free Software Foundation; version 2 of the License.
14 *
15 * This program is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 * GNU General Public License for more details.
19 *
20 * You should have received a copy of the GNU General Public License
21 * along with this program; if not, write to the Free Software
22 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA, 02110-1301 USA
23 * ---------------------------------------------------------------------------
24 * Redistribution and use in source and binary forms, with or without
25 * modification, are permitted provided that the following conditions
26 * are met:
27 * 1. Redistributions of source code must retain the above copyright
28 * notice, this list of conditions and the following disclaimer.
29 * 2. Redistributions in binary form must reproduce the above copyright
30 * notice, this list of conditions and the following disclaimer in the
31 * documentation and/or other materials provided with the distribution.
32 * 3. The name of the author may not be used to endorse or promote products
33 * derived from this software without specific prior written permission.
34 *
35 * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
36 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
37 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
38 * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
39 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
40 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
41 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
42 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
43 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
44 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
45 * SUCH DAMAGE.
46 * ---------------------------------------------------------------------------
47 */
48
49#ifndef _CBFS_H_
50#define _CBFS_H_
51
Patrick Georgib8835152011-07-21 15:11:40 +020052#include "cbfs_core.h"
Myles Watsonfa12b672009-04-30 22:45:41 +000053#include <boot/coreboot_tables.h>
Peter Stuge483b7bb2009-04-14 07:40:01 +000054
Patrick Georgib8835152011-07-21 15:11:40 +020055void *cbfs_load_payload(struct lb_memory *lb_mem, const char *name);
56void *cbfs_load_stage(const char *name);
Peter Stuge483b7bb2009-04-14 07:40:01 +000057int cbfs_execute_stage(const char *name);
Peter Stuge483b7bb2009-04-14 07:40:01 +000058void *cbfs_load_optionrom(u16 vendor, u16 device, void * dest);
59int run_address(void *f);
Ronald G. Minnich9764d4c2012-06-12 16:29:32 -070060int selfboot(struct lb_memory *mem, struct cbfs_payload *payload);
Peter Stuge483b7bb2009-04-14 07:40:01 +000061#endif
62