From: Zoltan HERPAI Date: Tue, 16 Oct 2018 14:27:34 +0000 (+0200) Subject: riscv64: add a very basic base-files pack X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=b26f5d2045247ec37604905ffe82efc63f724860;p=openwrt%2Fstaging%2Fwigyori.git riscv64: add a very basic base-files pack Signed-off-by: Zoltan HERPAI --- diff --git a/target/linux/riscv64/base-files/etc/board.d/02_network b/target/linux/riscv64/base-files/etc/board.d/02_network new file mode 100755 index 0000000000..df48b431af --- /dev/null +++ b/target/linux/riscv64/base-files/etc/board.d/02_network @@ -0,0 +1,18 @@ +#!/bin/sh +# +# Copyright (C) 2013-2015 OpenWrt.org +# + +. /lib/functions/uci-defaults.sh + +board_config_update + +case "$(board_name)" in +*) + ucidef_set_interface_lan 'eth0' + ;; +esac + +board_config_flush + +exit 0 diff --git a/target/linux/riscv64/base-files/etc/inittab b/target/linux/riscv64/base-files/etc/inittab new file mode 100644 index 0000000000..be81ab3e23 --- /dev/null +++ b/target/linux/riscv64/base-files/etc/inittab @@ -0,0 +1,5 @@ +::sysinit:/etc/init.d/rcS S boot +::shutdown:/etc/init.d/rcS K shutdown +tts/0::askfirst:/usr/libexec/login.sh +ttyS0::askfirst:/usr/libexec/login.sh +tty1::askfirst:/usr/libexec/login.sh diff --git a/target/linux/riscv64/base-files/lib/preinit/80_debug b/target/linux/riscv64/base-files/lib/preinit/80_debug new file mode 100644 index 0000000000..10ab6a4174 --- /dev/null +++ b/target/linux/riscv64/base-files/lib/preinit/80_debug @@ -0,0 +1,12 @@ +#!/bin/sh +# Copyright (C) 2012-2015 OpenWrt.org + +riscv_debug() { + cat /proc/cpuinfo + df + ifconfig -a + ls -l /dev +} + +boot_hook_add preinit_main riscv_debug +