Bump to Rust nightly-2022-04-11 rustsbi-qemu=5992db7 rustsbi-k210=1937341 default-mode=debug
This commit is contained in:
parent
676fdd86b7
commit
9decf93cff
5 changed files with 16 additions and 4 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -5,6 +5,7 @@ os/src/link_app.S
|
||||||
os/src/linker.ld
|
os/src/linker.ld
|
||||||
os/last-*
|
os/last-*
|
||||||
os/Cargo.lock
|
os/Cargo.lock
|
||||||
|
os/.gdb_history
|
||||||
user/build
|
user/build
|
||||||
user/target/*
|
user/target/*
|
||||||
user/.idea/*
|
user/.idea/*
|
||||||
|
|
Binary file not shown.
Binary file not shown.
17
os/Makefile
17
os/Makefile
|
@ -1,6 +1,6 @@
|
||||||
# Building
|
# Building
|
||||||
TARGET := riscv64gc-unknown-none-elf
|
TARGET := riscv64gc-unknown-none-elf
|
||||||
MODE := release
|
MODE := debug
|
||||||
KERNEL_ELF := target/$(TARGET)/$(MODE)/os
|
KERNEL_ELF := target/$(TARGET)/$(MODE)/os
|
||||||
KERNEL_BIN := $(KERNEL_ELF).bin
|
KERNEL_BIN := $(KERNEL_ELF).bin
|
||||||
DISASM_TMP := target/$(TARGET)/$(MODE)/asm
|
DISASM_TMP := target/$(TARGET)/$(MODE)/asm
|
||||||
|
@ -11,6 +11,11 @@ SBI ?= rustsbi
|
||||||
BOOTLOADER := ../bootloader/$(SBI)-$(BOARD).bin
|
BOOTLOADER := ../bootloader/$(SBI)-$(BOARD).bin
|
||||||
K210_BOOTLOADER_SIZE := 131072
|
K210_BOOTLOADER_SIZE := 131072
|
||||||
|
|
||||||
|
# Building mode argument
|
||||||
|
ifeq ($(MODE), release)
|
||||||
|
MODE_ARG := --release
|
||||||
|
endif
|
||||||
|
|
||||||
# KERNEL ENTRY
|
# KERNEL ENTRY
|
||||||
ifeq ($(BOARD), qemu)
|
ifeq ($(BOARD), qemu)
|
||||||
KERNEL_ENTRY_PA := 0x80200000
|
KERNEL_ENTRY_PA := 0x80200000
|
||||||
|
@ -51,7 +56,7 @@ kernel:
|
||||||
@cd ../user && make build
|
@cd ../user && make build
|
||||||
@echo Platform: $(BOARD)
|
@echo Platform: $(BOARD)
|
||||||
@cp src/linker-$(BOARD).ld src/linker.ld
|
@cp src/linker-$(BOARD).ld src/linker.ld
|
||||||
@cargo build --release --features "board_$(BOARD)"
|
@cargo build $(MODE_ARG) --features "board_$(BOARD)"
|
||||||
@rm src/linker.ld
|
@rm src/linker.ld
|
||||||
|
|
||||||
clean:
|
clean:
|
||||||
|
@ -92,4 +97,10 @@ debug: build
|
||||||
tmux split-window -h "riscv64-unknown-elf-gdb -ex 'file $(KERNEL_ELF)' -ex 'set arch riscv:rv64' -ex 'target remote localhost:1234'" && \
|
tmux split-window -h "riscv64-unknown-elf-gdb -ex 'file $(KERNEL_ELF)' -ex 'set arch riscv:rv64' -ex 'target remote localhost:1234'" && \
|
||||||
tmux -2 attach-session -d
|
tmux -2 attach-session -d
|
||||||
|
|
||||||
.PHONY: build env kernel clean disasm disasm-vim run-inner switch-check
|
gdbserver: build
|
||||||
|
@qemu-system-riscv64 -machine virt -nographic -bios $(BOOTLOADER) -device loader,file=$(KERNEL_BIN),addr=$(KERNEL_ENTRY_PA) -s -S
|
||||||
|
|
||||||
|
gdbclient:
|
||||||
|
@riscv64-unknown-elf-gdb -ex 'file $(KERNEL_ELF)' -ex 'set arch riscv:rv64' -ex 'target remote localhost:1234'
|
||||||
|
|
||||||
|
.PHONY: build env kernel clean disasm disasm-vim run-inner switch-check gdbserver
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
nightly-2022-01-19
|
nightly-2022-04-11
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue