add kernel and init configs

This commit is contained in:
Alfonso Gamboa 2022-05-31 22:17:54 -07:00
parent ec4ad5e93a
commit 42a601cf32
4 changed files with 2462 additions and 0 deletions

47
src/initramfs/init_t31 Normal file
View File

@ -0,0 +1,47 @@
#!/bin/sh
# devtmpfs does not get automounted for initramfs
set -x
mount -t devtmpfs devtmpfs /dev
mount -t proc proc /proc
mount -t sysfs sysfs /sys
sleep 1
mkdir -p /sdcard
mount -t vfat /dev/mmcblk0p1 /sdcard -o rw,umask=0000,dmask=0000
mkdir /v3
mount -t squashfs /dev/mtdblock2 /v3
if [ ! -f /sdcard/wz_mini/etc/init.d/v3_init.sh ]; then
echo "v3_init not found, booting stock"
mount --move /dev /v3/dev
mount --move /sys /v3/sys
mount --move /proc /v3/proc
umount /sdcard
exec busybox switch_root /v3 /linuxrc
else
mkdir -p /v3/dev
mkdir -p /v3/sys
mount --move /dev /v3/dev
mount --move /sys /v3/sys
mount --move /proc /v3/proc
#mkdir -p /v3/media/mmc
mount --move /sdcard /v3/opt
#exec busybox switch_root /v3 /linuxrc
exec busybox switch_root /v3 /opt/wz_mini/etc/init.d/v3_init.sh
fi

53
src/initramfs/init_v2 Normal file
View File

@ -0,0 +1,53 @@
#!/bin/sh
# devtmpfs does not get automounted for initramfs
set -x
mount -t devtmpfs devtmpfs /dev
mount -t proc proc /proc
mount -t sysfs sysfs /sys
sleep 1
echo 43 > /sys/class/gpio/export
echo in > /sys/class/gpio/gpio43/direction
#wait for sd card init
sleep 3
mkdir -p /sdcard
mount -t vfat /dev/mmcblk0p1 /sdcard -o rw,umask=0000,dmask=0000
mkdir /v3
mount -t squashfs /dev/mtdblock2 /v3
if [ ! -f /sdcard/wz_mini/etc/init.d/v3_init.sh ]; then
echo "v3_init not found, booting stock"
mount --move /dev /v3/dev
mount --move /sys /v3/sys
mount --move /proc /v3/proc
umount /sdcard
exec busybox switch_root /v3 /linuxrc
else
mkdir -p /v3/dev
mkdir -p /v3/sys
mount --move /dev /v3/dev
mount --move /sys /v3/sys
mount --move /proc /v3/proc
#mkdir -p /v3/media/mmc
mount --move /sdcard /v3/opt
#exec busybox switch_root /v3 /linuxrc
exec busybox switch_root /v3 /opt/wz_mini/etc/init.d/v3_init.sh
fi

2361
src/kernel/kernel.config Normal file

File diff suppressed because it is too large Load Diff

1
v2_install/.gitignore vendored Normal file
View File

@ -0,0 +1 @@
demo.bin