Declare stack_top as u32 in struct shared_data and struct common_buf
so that we can avoid casting in fsp_init().
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Acked-by: Simon Glass <sjg@chromium.org>
Tested-by: Simon Glass <sjg@chromium.org>
* Stack top pointer used by the bootloader. The new stack frame will be
* set up at this location after FspInit API call.
*/
- u32 *stack_top;
+ u32 stack_top;
u32 boot_mode; /* Current system boot mode */
void *upd_data; /* User platform configuraiton data region */
u32 reserved[7]; /* Reserved */
struct shared_data {
struct fsp_header *fsp_hdr;
- u32 *stack_top;
+ u32 stack_top;
struct upd_region fsp_upd;
};
memset(&rt_buf, 0, sizeof(struct fspinit_rtbuf));
/* Reserve a gap in stack top */
- rt_buf.common.stack_top = (u32 *)stack_top - 32;
+ rt_buf.common.stack_top = stack_top - 32;
rt_buf.common.boot_mode = boot_mode;
rt_buf.common.upd_data = fsp_upd;
params_ptr = ¶ms;
shared_data.fsp_hdr = fsp_hdr;
- shared_data.stack_top = (u32 *)stack_top;
+ shared_data.stack_top = stack_top;
post_code(POST_PRE_MRC);