blob: 13a69ef0cc48f51a3bb19c4e68c3ead8f983da83 [file] [log] [blame]
Bin Meng8a8694d2018-09-26 06:55:21 -07001// SPDX-License-Identifier: GPL-2.0+
2/*
3 * Copyright (C) 2018, Bin Meng <bmeng.cn@gmail.com>
4 */
5
6#include <common.h>
Simon Glass8f3f7612019-11-14 12:57:42 -07007#include <irq_func.h>
Bin Meng8a8694d2018-09-26 06:55:21 -07008
9/*
10 * cleanup_before_linux() is called just before we call linux
11 * it prepares the processor for linux
12 *
13 * we disable interrupt and caches.
14 */
15int cleanup_before_linux(void)
16{
17 disable_interrupts();
18
Rick Chen842d5802018-11-07 09:34:06 +080019 cache_flush();
Bin Meng8a8694d2018-09-26 06:55:21 -070020
21 return 0;
22}