-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
riscv: sophgo: milkv_duo: initial support added
Add support for Sophgo's Milk-V Duo board, only minimal device tree and serial console are enabled, and it can boot via vendor first stage bootloader. Signed-off-by: Kongyang Liu <[email protected]> Reviewed-by: Leo Yu-Chi Liang <[email protected]>
- Loading branch information
1 parent
f03d2ab
commit 0dc6ee6
Showing
7 changed files
with
87 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
if TARGET_MILKV_DUO | ||
|
||
config SYS_BOARD | ||
default "milkv_duo" | ||
|
||
config SYS_VENDOR | ||
default "sophgo" | ||
|
||
config SYS_CPU | ||
default "generic" | ||
|
||
config SYS_CONFIG_NAME | ||
default "milkv_duo" | ||
|
||
config TEXT_BASE | ||
default 0x80200000 | ||
|
||
config ENV_SIZE | ||
default 0x20000 | ||
|
||
config ENV_SECT_SIZE | ||
default 0x40000 | ||
|
||
config BOARD_SPECIFIC_OPTIONS | ||
def_bool y | ||
select GENERIC_RISCV | ||
|
||
endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
Milk-V Duo | ||
M: Kongyang Liu <[email protected]> | ||
S: Maintained | ||
F: board/sophgo/milkv_duo/ | ||
F: configs/milkv_duo_defconfig | ||
F: doc/board/sophgo/milkv_duo.rst |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
# SPDX-License-Identifier: GPL-2.0+ | ||
# | ||
# Copyright (c) 2024, Kongyang Liu <[email protected]> | ||
|
||
obj-y := board.o |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
// SPDX-License-Identifier: GPL-2.0+ | ||
/* | ||
* Copyright (c) 2024, Kongyang Liu <[email protected]> | ||
*/ | ||
|
||
int board_init(void) | ||
{ | ||
return 0; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
CONFIG_RISCV=y | ||
CONFIG_SYS_MALLOC_LEN=0x820000 | ||
CONFIG_SYS_MALLOC_F_LEN=0x2000 | ||
CONFIG_NR_DRAM_BANKS=1 | ||
CONFIG_HAS_CUSTOM_SYS_INIT_SP_ADDR=y | ||
CONFIG_CUSTOM_SYS_INIT_SP_ADDR=0x82300000 | ||
CONFIG_DEFAULT_DEVICE_TREE="cv1800b-milkv-duo" | ||
CONFIG_IDENT_STRING="milkv_duo" | ||
CONFIG_SYS_LOAD_ADDR=0x80080000 | ||
CONFIG_TARGET_MILKV_DUO=y | ||
CONFIG_ARCH_RV64I=y | ||
CONFIG_RISCV_SMODE=y | ||
CONFIG_FIT=y | ||
CONFIG_SUPPORT_RAW_INITRD=y | ||
CONFIG_HUSH_PARSER=y | ||
CONFIG_SYS_PROMPT="milkv_duo# " | ||
CONFIG_SYS_MAXARGS=64 | ||
CONFIG_SYS_CBSIZE=512 | ||
CONFIG_SYS_PBSIZE=544 | ||
CONFIG_SYS_BOOTM_LEN=0x4000000 | ||
CONFIG_ENV_OVERWRITE=y | ||
CONFIG_SYS_NS16550=y | ||
CONFIG_SYS_NS16550_MEM32=y |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
/* SPDX-License-Identifier: GPL-2.0+ */ | ||
/* | ||
* Copyright (c) 2024, Kongyang Liu <[email protected]> | ||
* | ||
*/ | ||
|
||
#ifndef __CONFIG_H | ||
#define __CONFIG_H | ||
|
||
#define CFG_SYS_SDRAM_BASE 0x80000000 | ||
|
||
#endif /* __CONFIG_H */ |