blob: 4fe67ea081127044c4d21cb849e342a48f50f4d7 [file] [log] [blame]
Siew Chin Lim612ee822021-03-15 15:59:16 +08001// SPDX-License-Identifier: GPL-2.0
2/*
3 * Copyright (C) 2020 Intel Corporation. All rights reserved
4 *
5 */
6
Siew Chin Lim612ee822021-03-15 15:59:16 +08007#include <spl.h>
8
9DECLARE_GLOBAL_DATA_PTR;
10
11u32 spl_boot_device(void)
12{
13 return BOOT_DEVICE_MMC1;
14}
15
Simon Glassb58bfe02021-08-08 12:20:09 -060016#if IS_ENABLED(CONFIG_SPL_MMC)
Siew Chin Lim612ee822021-03-15 15:59:16 +080017u32 spl_boot_mode(const u32 boot_device)
18{
19 if (IS_ENABLED(CONFIG_SPL_FS_FAT) || IS_ENABLED(CONFIG_SPL_FS_EXT4))
20 return MMCSD_MODE_FS;
21 else
22 return MMCSD_MODE_RAW;
23}
24#endif