summaryrefslogtreecommitdiffstats
path: root/arch/x86/boot/main_entry.c
blob: b37aa38fca20bf6422d566daaf8ff431f48bfd0e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
// SPDX-License-Identifier: GPL-2.0-or-later
// SPDX-FileCopyrightText: 2009 Juergen Beisert, Pengutronix

/**
 * @file
 * @brief Start of the 32 bit flat mode
 */

#include <string.h>
#include <asm/sections.h>

extern void x86_start_barebox(void);

/**
 * Called plainly from assembler that switches from real to flat mode
 *
 * @note The C environment isn't initialized yet
 */
void uboot_entry(void)
{
	/* clear the BSS first */
	memset(__bss_start, 0x00, __bss_stop - __bss_start);
	x86_start_barebox();
}