2018-05-06 21:58:06 +00:00
|
|
|
/* SPDX-License-Identifier: Intel */
|
2014-12-12 13:05:28 +00:00
|
|
|
/*
|
|
|
|
* Copyright (C) 2013, Intel Corporation
|
|
|
|
* Copyright (C) 2014, Bin Meng <bmeng.cn@gmail.com>
|
|
|
|
*/
|
|
|
|
|
2019-08-24 20:19:05 +00:00
|
|
|
#ifndef __FSP1_SUPPORT_H__
|
|
|
|
#define __FSP1_SUPPORT_H__
|
2014-12-12 13:05:28 +00:00
|
|
|
|
2019-08-24 20:19:05 +00:00
|
|
|
#include <asm/fsp/fsp_support.h>
|
2014-12-12 13:05:28 +00:00
|
|
|
#include "fsp_ffs.h"
|
2015-01-28 05:13:37 +00:00
|
|
|
|
2014-12-17 07:50:49 +00:00
|
|
|
/**
|
2019-08-25 16:10:59 +00:00
|
|
|
* fsp_asm_continuation() - FSP Continuation assembly helper routine
|
2014-12-17 07:50:49 +00:00
|
|
|
*
|
|
|
|
* This routine jumps to the C version of FSP continuation function
|
|
|
|
*/
|
2019-09-25 14:11:25 +00:00
|
|
|
void fsp_asm_continuation(void);
|
2014-12-12 13:05:28 +00:00
|
|
|
|
2014-12-17 07:50:49 +00:00
|
|
|
/**
|
2019-08-25 16:10:59 +00:00
|
|
|
* fsp_init_done() - FSP initialization complete
|
2014-12-17 07:50:49 +00:00
|
|
|
*
|
|
|
|
* This is the function that indicates FSP initialization is complete and jumps
|
|
|
|
* back to the bootloader with HOB list pointer as the parameter.
|
|
|
|
*
|
|
|
|
* @hob_list: HOB list pointer
|
|
|
|
*/
|
2014-12-12 13:05:29 +00:00
|
|
|
void fsp_init_done(void *hob_list);
|
2014-12-12 13:05:28 +00:00
|
|
|
|
|
|
|
/**
|
2019-08-25 16:10:59 +00:00
|
|
|
* fsp_continue() - FSP Continuation function
|
2014-12-12 13:05:28 +00:00
|
|
|
*
|
|
|
|
* @status: Always 0
|
|
|
|
* @hob_list: HOB list pointer
|
|
|
|
*
|
2019-08-25 16:10:59 +00:00
|
|
|
* @return Never returns
|
2014-12-12 13:05:28 +00:00
|
|
|
*/
|
2015-12-11 06:02:56 +00:00
|
|
|
void fsp_continue(u32 status, void *hob_list);
|
2014-12-12 13:05:28 +00:00
|
|
|
|
|
|
|
/**
|
2019-08-25 16:10:59 +00:00
|
|
|
* fsp_init() - FSP initialization wrapper function
|
2014-12-12 13:05:28 +00:00
|
|
|
*
|
|
|
|
* @stack_top: bootloader stack top address
|
|
|
|
* @boot_mode: boot mode defined in fsp_bootmode.h
|
|
|
|
* @nvs_buf: Non-volatile memory buffer pointer
|
|
|
|
*/
|
|
|
|
void fsp_init(u32 stack_top, u32 boot_mode, void *nvs_buf);
|
|
|
|
|
2019-08-25 16:10:59 +00:00
|
|
|
/**
|
|
|
|
* fsp_get_bootloader_tmp_mem() - retrieves temporary stack buffer and size
|
2014-12-12 13:05:28 +00:00
|
|
|
*
|
|
|
|
* @hob_list: A HOB list pointer.
|
|
|
|
* @len: A pointer to the bootloader temporary stack length.
|
|
|
|
* If the HOB is located, the length will be updated.
|
|
|
|
*
|
2019-08-25 16:10:59 +00:00
|
|
|
* @return NULL: Failed to find the bootloader temporary stack HOB.
|
|
|
|
* @return others: Bootloader temporary stackbuffer pointer.
|
2014-12-12 13:05:28 +00:00
|
|
|
*/
|
2014-12-17 07:50:49 +00:00
|
|
|
void *fsp_get_bootloader_tmp_mem(const void *hob_list, u32 *len);
|
2014-12-12 13:05:28 +00:00
|
|
|
|
|
|
|
/**
|
2019-08-25 16:10:59 +00:00
|
|
|
* fsp_update_configs() - overrides the default configurations of FSP
|
2014-12-12 13:05:28 +00:00
|
|
|
*
|
2015-12-11 06:03:00 +00:00
|
|
|
* @config: A pointer to the FSP configuration data structure
|
2015-12-11 06:03:04 +00:00
|
|
|
* @rt_buf: A pointer to the FSP runtime buffer data structure
|
2014-12-12 13:05:28 +00:00
|
|
|
*
|
2019-08-25 16:10:59 +00:00
|
|
|
* @return None
|
2014-12-12 13:05:28 +00:00
|
|
|
*/
|
2019-09-25 14:11:25 +00:00
|
|
|
void fsp_update_configs(struct fsp_config_data *config,
|
2015-12-11 06:03:04 +00:00
|
|
|
struct fspinit_rtbuf *rt_buf);
|
2014-12-12 13:05:28 +00:00
|
|
|
|
|
|
|
#endif
|