Compare commits
11 Commits
54977e9c4d
...
f91cf43311
| Author | SHA1 | Date | |
|---|---|---|---|
| f91cf43311 | |||
| 543e96f2aa | |||
| c49a16856c | |||
| d41cc3ed6b | |||
| 76e5db15c8 | |||
| 7ef56c7314 | |||
| 2833c24f11 | |||
| f3dd6dc9ad | |||
| 232cef1614 | |||
| 734d43fd77 | |||
| 084be3f1c5 |
44
build.sh
44
build.sh
@ -99,6 +99,15 @@ function prepare_env()
|
||||
defconfig ${MV_BOARD_LINK} > /dev/null 2>&1
|
||||
|
||||
echo "OUTPUT_DIR: ${OUTPUT_DIR}" # @build/milkvsetup.sh
|
||||
|
||||
if [ "${STORAGE_TYPE}" == "sd" ]; then
|
||||
MILKV_IMAGE_CONFIG=device/${MILKV_BOARD}/genimage.cfg
|
||||
|
||||
if [ ! -f ${MILKV_IMAGE_CONFIG} ]; then
|
||||
print_err "${MILKV_IMAGE_CONFIG} not found!"
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
function milkv_build()
|
||||
@ -133,7 +142,7 @@ function milkv_pack_sd()
|
||||
[ ! -d out ] && mkdir out
|
||||
|
||||
img_in="${OUTPUT_DIR}/${MILKV_BOARD}.img"
|
||||
img_out="${MILKV_BOARD}-sd-`date +%Y%m%d-%H%M`.img"
|
||||
img_out="${MILKV_BOARD}-`date +%Y%m%d-%H%M`.img"
|
||||
|
||||
if [ -f "${img_in}" ]; then
|
||||
mv ${img_in} out/${img_out}
|
||||
@ -149,7 +158,7 @@ function milkv_pack_emmc()
|
||||
[ ! -d out ] && mkdir out
|
||||
|
||||
img_in="${OUTPUT_DIR}/upgrade.zip"
|
||||
img_out="${MILKV_BOARD}-emmc-`date +%Y%m%d-%H%M`.zip"
|
||||
img_out="${MILKV_BOARD}-`date +%Y%m%d-%H%M`.zip"
|
||||
|
||||
if [ -f "${img_in}" ]; then
|
||||
mv ${img_in} out/${img_out}
|
||||
@ -165,22 +174,22 @@ function milkv_pack_nor_nand()
|
||||
[ ! -d out ] && mkdir out
|
||||
|
||||
if [ -f "${OUTPUT_DIR}/upgrade.zip" ]; then
|
||||
nor_out_name=${MILKV_BOARD}-`date +%Y%m%d-%H%M`
|
||||
mkdir -p out/$nor_out_name
|
||||
img_out_patch=${MILKV_BOARD}-`date +%Y%m%d-%H%M`
|
||||
mkdir -p out/$img_out_patch
|
||||
|
||||
if [ "${STORAGE_TYPE}" == "spinor" ]; then
|
||||
cp ${OUTPUT_DIR}/fip.bin out/$nor_out_name
|
||||
cp ${OUTPUT_DIR}/*.spinor out/$nor_out_name
|
||||
cp ${OUTPUT_DIR}/fip.bin out/$img_out_patch
|
||||
cp ${OUTPUT_DIR}/*.spinor out/$img_out_patch
|
||||
else
|
||||
cp ${OUTPUT_DIR}/fip.bin out/$nor_out_name
|
||||
cp ${OUTPUT_DIR}/*.spinand out/$nor_out_name
|
||||
cp ${OUTPUT_DIR}/fip.bin out/$img_out_patch
|
||||
cp ${OUTPUT_DIR}/*.spinand out/$img_out_patch
|
||||
fi
|
||||
|
||||
touch ${OUTPUT_DIR}/how_to_download.txt
|
||||
echo "Copy all to a blank tf card, power on and automatically download firmware to NOR or NAND in U-bOOT." >> out/$nor_out_name/how_to_download.txt
|
||||
print_info "Create spinor img successful: ${nor_out_name}"
|
||||
echo "Copy all to a blank tf card, power on and automatically download firmware to NOR or NAND in U-boot." >> out/$img_out_patch/how_to_download.txt
|
||||
print_info "Create spinor/nand img successful: ${img_out_patch}"
|
||||
else
|
||||
print_err "Create spinor img failed!"
|
||||
print_err "Create spinor/nand img failed!"
|
||||
exit 1
|
||||
fi
|
||||
}
|
||||
@ -199,8 +208,11 @@ function milkv_pack()
|
||||
function build_info()
|
||||
{
|
||||
print_info "Target Board: ${MILKV_BOARD}"
|
||||
print_info "Target Board Storage: ${STORAGE_TYPE}"
|
||||
print_info "Target Board Config: ${MILKV_BOARD_CONFIG}"
|
||||
if [ "${STORAGE_TYPE}" == "sd" ]; then
|
||||
print_info "Target Image Config: ${MILKV_IMAGE_CONFIG}"
|
||||
fi
|
||||
}
|
||||
|
||||
get_available_board
|
||||
@ -240,25 +252,19 @@ if [ -z "${MILKV_BOARD// }" ]; then
|
||||
fi
|
||||
|
||||
MILKV_BOARD_CONFIG=device/${MILKV_BOARD}/boardconfig.sh
|
||||
MILKV_IMAGE_CONFIG=device/${MILKV_BOARD}/genimage.cfg
|
||||
|
||||
if [ ! -f ${MILKV_BOARD_CONFIG} ]; then
|
||||
print_err "${MILKV_BOARD_CONFIG} not found!"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ ! -f ${MILKV_IMAGE_CONFIG} ]; then
|
||||
print_err "${MILKV_IMAGE_CONFIG} not found!"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
get_toolchain
|
||||
|
||||
build_info
|
||||
|
||||
export MILKV_BOARD="${MILKV_BOARD}"
|
||||
|
||||
prepare_env
|
||||
|
||||
build_info
|
||||
|
||||
milkv_build
|
||||
milkv_pack
|
||||
|
||||
@ -562,7 +562,7 @@ br-rootfs-prepare:export CROSS_COMPILE_KERNEL=$(patsubst "%",%,$(CONFIG_CROSS_CO
|
||||
br-rootfs-prepare:export CROSS_COMPILE_SDK=$(patsubst "%",%,$(CONFIG_CROSS_COMPILE_SDK))
|
||||
br-rootfs-prepare:
|
||||
$(call print_target)
|
||||
ifneq ($(STORAGE_TYPE), sd)
|
||||
ifeq ($(STORAGE_TYPE),$(filter $(STORAGE_TYPE),spinor spinand))
|
||||
#${Q}cp -r ${RAMDISK_PATH}/rootfs/buildroot_fs/arm/* $(BR_ROOTFS_DIR)
|
||||
$(call TARGET_PACKAGE_INSTALL_BR_ROOTFS)
|
||||
${Q}mkdir -p $(BR_ROOTFS_DIR)/etc/init.d/
|
||||
|
||||
@ -32,7 +32,17 @@
|
||||
sd-uhs-ddr50;
|
||||
sd-uhs-sdr104;
|
||||
min-frequency = <400000>;
|
||||
max-frequency = <100000000>;
|
||||
max-frequency = <187500000>;
|
||||
};
|
||||
|
||||
&wifi_pin {
|
||||
compatible = "cvitek,wifi-pin";
|
||||
poweron-gpio = <&porta 15 GPIO_ACTIVE_HIGH>;
|
||||
wakeup-gpio = <&porte 7 GPIO_ACTIVE_HIGH>;
|
||||
};
|
||||
|
||||
&uart4 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
/ {
|
||||
|
||||
@ -428,6 +428,7 @@ CONFIG_ION_CARVEOUT_HEAP=y
|
||||
CONFIG_ION_CMA_HEAP=y
|
||||
# CONFIG_IOMMU_SUPPORT is not set
|
||||
CONFIG_CV1835_SYSDMA_REMAP=y
|
||||
CONFIG_CVI_WIFI_PIN=y
|
||||
CONFIG_PWM=y
|
||||
CONFIG_SIFIVE_PLIC=y
|
||||
CONFIG_ANDROID=y
|
||||
@ -495,3 +496,35 @@ CONFIG_EPOLL=n
|
||||
CONFIG_ELF_CORE=y
|
||||
CONFIG_COREDUMP=y
|
||||
CONFIG_PROC_SYSCTL=y
|
||||
|
||||
CONFIG_BT=y
|
||||
CONFIG_BT_BREDR=y
|
||||
CONFIG_BT_RFCOMM=y
|
||||
CONFIG_BT_RFCOMM_TTY=y
|
||||
CONFIG_BT_BNEP=y
|
||||
CONFIG_BT_BNEP_MC_FILTER=y
|
||||
CONFIG_BT_BNEP_PROTO_FILTER=y
|
||||
CONFIG_BT_HIDP=y
|
||||
CONFIG_BT_HS=y
|
||||
CONFIG_BT_LE=y
|
||||
# CONFIG_BT_MSFTEXT is not set
|
||||
CONFIG_BT_DEBUGFS=y
|
||||
# CONFIG_BT_SELFTEST is not set
|
||||
|
||||
#
|
||||
# Bluetooth device drivers
|
||||
#
|
||||
# CONFIG_BT_HCIBTUSB is not set
|
||||
# CONFIG_BT_HCIBTSDIO is not set
|
||||
CONFIG_BT_HCIUART=y
|
||||
CONFIG_BT_HCIUART_H4=y
|
||||
# CONFIG_BT_HCIUART_BCSP is not set
|
||||
# CONFIG_BT_HCIUART_ATH3K is not set
|
||||
# CONFIG_BT_HCIUART_INTEL is not set
|
||||
# CONFIG_BT_HCIUART_AG6XX is not set
|
||||
# CONFIG_BT_HCIBCM203X is not set
|
||||
# CONFIG_BT_HCIBPA10X is not set
|
||||
# CONFIG_BT_HCIBFUSB is not set
|
||||
# CONFIG_BT_HCIVHCI is not set
|
||||
# CONFIG_BT_MRVL is not set
|
||||
# CONFIG_BT_MTKSDIO is not set
|
||||
|
||||
@ -1,11 +1,7 @@
|
||||
<physical_partition type="emmc">
|
||||
<partition label="BOOT" size_in_kb="8192" file="boot.emmc" />
|
||||
<partition label="MISC" size_in_kb="512" file="logo.jpg" />
|
||||
<!-- Beware that in emmc u-boot environment should be 0x40000 alignment -->
|
||||
<partition label="ENV" size_in_kb="128" file="" />
|
||||
<partition label="ROOTFS" size_in_kb="786432" file="rootfs_ext4.emmc" type="ext4"/>
|
||||
<partition label="SYSTEM" size_in_kb="40960" file="system.emmc" type="ext4" />
|
||||
<partition label="CFG" size_in_kb="15240" file="cfg.emmc" mountpoint="/mnt/cfg" type="ext4" />
|
||||
<partition label="DATA" size_in_kb="3145728" file="" mountpoint="/mnt/data" type="ext4"/>
|
||||
</physical_partition>
|
||||
|
||||
|
||||
@ -19,6 +19,10 @@ int cvi_board_init(void)
|
||||
|
||||
// WIFI/BT
|
||||
PINMUX_CONFIG(CLK32K, PWR_GPIO_10);
|
||||
PINMUX_CONFIG(UART2_RX, UART4_RX);
|
||||
PINMUX_CONFIG(UART2_TX, UART4_TX);
|
||||
PINMUX_CONFIG(UART2_CTS, UART4_CTS);
|
||||
PINMUX_CONFIG(UART2_RTS, UART4_RTS);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
Binary file not shown.
@ -32,7 +32,17 @@
|
||||
sd-uhs-ddr50;
|
||||
sd-uhs-sdr104;
|
||||
min-frequency = <400000>;
|
||||
max-frequency = <100000000>;
|
||||
max-frequency = <187500000>;
|
||||
};
|
||||
|
||||
&wifi_pin {
|
||||
compatible = "cvitek,wifi-pin";
|
||||
poweron-gpio = <&porta 15 GPIO_ACTIVE_HIGH>;
|
||||
wakeup-gpio = <&porte 7 GPIO_ACTIVE_HIGH>;
|
||||
};
|
||||
|
||||
&uart4 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
/ {
|
||||
|
||||
@ -428,6 +428,7 @@ CONFIG_ION_CARVEOUT_HEAP=y
|
||||
CONFIG_ION_CMA_HEAP=y
|
||||
# CONFIG_IOMMU_SUPPORT is not set
|
||||
CONFIG_CV1835_SYSDMA_REMAP=y
|
||||
CONFIG_CVI_WIFI_PIN=y
|
||||
CONFIG_PWM=y
|
||||
CONFIG_SIFIVE_PLIC=y
|
||||
CONFIG_ANDROID=y
|
||||
@ -495,3 +496,35 @@ CONFIG_EPOLL=n
|
||||
CONFIG_ELF_CORE=y
|
||||
CONFIG_COREDUMP=y
|
||||
CONFIG_PROC_SYSCTL=y
|
||||
|
||||
CONFIG_BT=y
|
||||
CONFIG_BT_BREDR=y
|
||||
CONFIG_BT_RFCOMM=y
|
||||
CONFIG_BT_RFCOMM_TTY=y
|
||||
CONFIG_BT_BNEP=y
|
||||
CONFIG_BT_BNEP_MC_FILTER=y
|
||||
CONFIG_BT_BNEP_PROTO_FILTER=y
|
||||
CONFIG_BT_HIDP=y
|
||||
CONFIG_BT_HS=y
|
||||
CONFIG_BT_LE=y
|
||||
# CONFIG_BT_MSFTEXT is not set
|
||||
CONFIG_BT_DEBUGFS=y
|
||||
# CONFIG_BT_SELFTEST is not set
|
||||
|
||||
#
|
||||
# Bluetooth device drivers
|
||||
#
|
||||
# CONFIG_BT_HCIBTUSB is not set
|
||||
# CONFIG_BT_HCIBTSDIO is not set
|
||||
CONFIG_BT_HCIUART=y
|
||||
CONFIG_BT_HCIUART_H4=y
|
||||
# CONFIG_BT_HCIUART_BCSP is not set
|
||||
# CONFIG_BT_HCIUART_ATH3K is not set
|
||||
# CONFIG_BT_HCIUART_INTEL is not set
|
||||
# CONFIG_BT_HCIUART_AG6XX is not set
|
||||
# CONFIG_BT_HCIBCM203X is not set
|
||||
# CONFIG_BT_HCIBPA10X is not set
|
||||
# CONFIG_BT_HCIBFUSB is not set
|
||||
# CONFIG_BT_HCIVHCI is not set
|
||||
# CONFIG_BT_MRVL is not set
|
||||
# CONFIG_BT_MTKSDIO is not set
|
||||
|
||||
@ -19,6 +19,10 @@ int cvi_board_init(void)
|
||||
|
||||
// WIFI/BT
|
||||
PINMUX_CONFIG(CLK32K, PWR_GPIO_10);
|
||||
PINMUX_CONFIG(UART2_RX, UART4_RX);
|
||||
PINMUX_CONFIG(UART2_TX, UART4_TX);
|
||||
PINMUX_CONFIG(UART2_CTS, UART4_CTS);
|
||||
PINMUX_CONFIG(UART2_RTS, UART4_RTS);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
@ -653,7 +653,7 @@
|
||||
cvi,card_name = "cv182x_internal_PDM";
|
||||
};
|
||||
|
||||
wifi_pin {
|
||||
wifi_pin: wifi_pin {
|
||||
compatible = "cvitek,wifi-pin";
|
||||
poweron-gpio = <&porta 18 GPIO_ACTIVE_HIGH>;
|
||||
wakeup-gpio = <&porte 7 GPIO_ACTIVE_HIGH>;
|
||||
|
||||
@ -59,7 +59,7 @@ BR2_BZCAT="bzcat"
|
||||
BR2_XZCAT="xzcat"
|
||||
BR2_LZCAT="lzip -d -c"
|
||||
BR2_TAR_OPTIONS=""
|
||||
BR2_DEFCONFIG="./configs/milkv-duos_musl_riscv64_defconfig"
|
||||
BR2_DEFCONFIG="./configs/milkv-duos-emmc_musl_riscv64_defconfig"
|
||||
BR2_DL_DIR="$(TOPDIR)/dl"
|
||||
BR2_HOST_DIR="$(BASE_DIR)/host"
|
||||
|
||||
@ -227,7 +227,7 @@ BR2_ENABLE_LOCALE_WHITELIST="C en_US"
|
||||
# BR2_SYSTEM_ENABLE_NLS is not set
|
||||
# BR2_TARGET_TZ_INFO is not set
|
||||
BR2_ROOTFS_USERS_TABLES=""
|
||||
BR2_ROOTFS_OVERLAY="board/milkv/milkv-duos/overlay"
|
||||
BR2_ROOTFS_OVERLAY="board/milkv/milkv-duos-emmc/overlay"
|
||||
BR2_ROOTFS_POST_BUILD_SCRIPT=""
|
||||
BR2_ROOTFS_POST_FAKEROOT_SCRIPT=""
|
||||
BR2_ROOTFS_POST_IMAGE_SCRIPT=""
|
||||
@ -470,3 +470,17 @@ BR2_PACKAGE_IPERF3=y
|
||||
BR2_PACKAGE_NTP=y
|
||||
BR2_PACKAGE_NTP_NTPDATE=y
|
||||
BR2_PACKAGE_NTP_NTPTIME=y
|
||||
|
||||
BR2_PACKAGE_BLUEZ5_UTILS=y
|
||||
BR2_PACKAGE_BLUEZ5_UTILS_OBEX=y
|
||||
BR2_PACKAGE_BLUEZ5_UTILS_CLIENT=y
|
||||
BR2_PACKAGE_BLUEZ5_UTILS_DEPRECATED=y
|
||||
BR2_PACKAGE_BLUEZ5_UTILS_EXPERIMENTAL=y
|
||||
BR2_PACKAGE_BLUEZ5_UTILS_PLUGINS_HEALTH=y
|
||||
# BR2_PACKAGE_BLUEZ5_UTILS_PLUGINS_MESH is not set
|
||||
# BR2_PACKAGE_BLUEZ5_UTILS_PLUGINS_MIDI is not set
|
||||
# BR2_PACKAGE_BLUEZ5_UTILS_PLUGINS_NFC is not set
|
||||
# BR2_PACKAGE_BLUEZ5_UTILS_PLUGINS_SAP is not set
|
||||
# BR2_PACKAGE_BLUEZ5_UTILS_PLUGINS_SIXAXIS is not set
|
||||
BR2_PACKAGE_BLUEZ5_UTILS_TEST=y
|
||||
BR2_PACKAGE_BLUEZ5_UTILS_TOOLS_HID2HCI=y
|
||||
@ -470,3 +470,17 @@ BR2_PACKAGE_IPERF3=y
|
||||
BR2_PACKAGE_NTP=y
|
||||
BR2_PACKAGE_NTP_NTPDATE=y
|
||||
BR2_PACKAGE_NTP_NTPTIME=y
|
||||
|
||||
BR2_PACKAGE_BLUEZ5_UTILS=y
|
||||
BR2_PACKAGE_BLUEZ5_UTILS_OBEX=y
|
||||
BR2_PACKAGE_BLUEZ5_UTILS_CLIENT=y
|
||||
BR2_PACKAGE_BLUEZ5_UTILS_DEPRECATED=y
|
||||
BR2_PACKAGE_BLUEZ5_UTILS_EXPERIMENTAL=y
|
||||
BR2_PACKAGE_BLUEZ5_UTILS_PLUGINS_HEALTH=y
|
||||
# BR2_PACKAGE_BLUEZ5_UTILS_PLUGINS_MESH is not set
|
||||
# BR2_PACKAGE_BLUEZ5_UTILS_PLUGINS_MIDI is not set
|
||||
# BR2_PACKAGE_BLUEZ5_UTILS_PLUGINS_NFC is not set
|
||||
# BR2_PACKAGE_BLUEZ5_UTILS_PLUGINS_SAP is not set
|
||||
# BR2_PACKAGE_BLUEZ5_UTILS_PLUGINS_SIXAXIS is not set
|
||||
BR2_PACKAGE_BLUEZ5_UTILS_TEST=y
|
||||
BR2_PACKAGE_BLUEZ5_UTILS_TOOLS_HID2HCI=y
|
||||
|
||||
0
buildroot-2021.05/dl/bluez5_utils/.lock
Normal file
0
buildroot-2021.05/dl/bluez5_utils/.lock
Normal file
BIN
buildroot-2021.05/dl/bluez5_utils/bluez-5.58.tar.xz
Normal file
BIN
buildroot-2021.05/dl/bluez5_utils/bluez-5.58.tar.xz
Normal file
Binary file not shown.
0
buildroot-2021.05/dl/dbus/.lock
Normal file
0
buildroot-2021.05/dl/dbus/.lock
Normal file
BIN
buildroot-2021.05/dl/dbus/dbus-1.12.20.tar.gz
Normal file
BIN
buildroot-2021.05/dl/dbus/dbus-1.12.20.tar.gz
Normal file
Binary file not shown.
0
buildroot-2021.05/dl/libglib2/.lock
Normal file
0
buildroot-2021.05/dl/libglib2/.lock
Normal file
BIN
buildroot-2021.05/dl/libglib2/glib-2.66.8.tar.xz
Normal file
BIN
buildroot-2021.05/dl/libglib2/glib-2.66.8.tar.xz
Normal file
Binary file not shown.
0
buildroot-2021.05/dl/libical/.lock
Normal file
0
buildroot-2021.05/dl/libical/.lock
Normal file
BIN
buildroot-2021.05/dl/libical/libical-1.0.1.tar.gz
Normal file
BIN
buildroot-2021.05/dl/libical/libical-1.0.1.tar.gz
Normal file
Binary file not shown.
0
buildroot-2021.05/dl/meson/.lock
Normal file
0
buildroot-2021.05/dl/meson/.lock
Normal file
BIN
buildroot-2021.05/dl/meson/meson-0.57.2.tar.gz
Normal file
BIN
buildroot-2021.05/dl/meson/meson-0.57.2.tar.gz
Normal file
Binary file not shown.
0
buildroot-2021.05/dl/ninja/.lock
Normal file
0
buildroot-2021.05/dl/ninja/.lock
Normal file
BIN
buildroot-2021.05/dl/ninja/ninja-1.10.2.tar.gz
Normal file
BIN
buildroot-2021.05/dl/ninja/ninja-1.10.2.tar.gz
Normal file
Binary file not shown.
0
buildroot-2021.05/dl/pcre/.lock
Normal file
0
buildroot-2021.05/dl/pcre/.lock
Normal file
BIN
buildroot-2021.05/dl/pcre/pcre-8.44.tar.bz2
Normal file
BIN
buildroot-2021.05/dl/pcre/pcre-8.44.tar.bz2
Normal file
Binary file not shown.
0
buildroot-2021.05/dl/tzdata/.lock
Normal file
0
buildroot-2021.05/dl/tzdata/.lock
Normal file
BIN
buildroot-2021.05/dl/tzdata/tzdata2021a.tar.gz
Normal file
BIN
buildroot-2021.05/dl/tzdata/tzdata2021a.tar.gz
Normal file
Binary file not shown.
0
buildroot-2021.05/dl/zic/.lock
Normal file
0
buildroot-2021.05/dl/zic/.lock
Normal file
BIN
buildroot-2021.05/dl/zic/tzcode2020f.tar.gz
Normal file
BIN
buildroot-2021.05/dl/zic/tzcode2020f.tar.gz
Normal file
Binary file not shown.
@ -304,7 +304,7 @@ CONFIG_TEST=y
|
||||
CONFIG_TEST1=y
|
||||
CONFIG_TEST2=y
|
||||
CONFIG_FEATURE_TEST_64=y
|
||||
# CONFIG_TIMEOUT is not set
|
||||
CONFIG_TIMEOUT=y
|
||||
CONFIG_TOUCH=y
|
||||
# CONFIG_FEATURE_TOUCH_NODEREF is not set
|
||||
CONFIG_FEATURE_TOUCH_SUSV3=y
|
||||
|
||||
BIN
device/milkv-duo-spinand/overlay/mnt/system/nandutils/cimg2raw
Executable file
BIN
device/milkv-duo-spinand/overlay/mnt/system/nandutils/cimg2raw
Executable file
Binary file not shown.
BIN
device/milkv-duo-spinand/overlay/mnt/system/nandutils/nandwrite
Executable file
BIN
device/milkv-duo-spinand/overlay/mnt/system/nandutils/nandwrite
Executable file
Binary file not shown.
@ -10,8 +10,3 @@ duo-pinmux -w GP14/GP14 > /dev/null
|
||||
# Insmod PWM Module
|
||||
insmod /mnt/system/ko/cv180x_pwm.ko
|
||||
|
||||
# Init Zram
|
||||
insmod /mnt/system/ko/zram.ko
|
||||
echo "128M" | tee /sys/block/zram0/disksize
|
||||
/sbin/mkswap /dev/zram0
|
||||
/sbin/swapon /dev/zram0
|
||||
@ -10,8 +10,3 @@ duo-pinmux -w GP14/GP14 > /dev/null
|
||||
# Insmod PWM Module
|
||||
insmod /mnt/system/ko/cv181x_pwm.ko
|
||||
|
||||
# Init Zram
|
||||
insmod /mnt/system/ko/zram.ko
|
||||
echo "128M" | tee /sys/block/zram0/disksize
|
||||
/sbin/mkswap /dev/zram0
|
||||
/sbin/swapon /dev/zram0
|
||||
@ -1,6 +1,6 @@
|
||||
#!/bin/bash
|
||||
|
||||
export MV_BOARD=milkv-duos
|
||||
export MV_BOARD=milkv-duos-emmc
|
||||
export MV_BOARD_CPU=cv1813h
|
||||
export MV_VENDOR=milkv
|
||||
export MV_BUILD_ENV=milkvsetup.sh
|
||||
@ -17,10 +17,11 @@ function set_gpio()
|
||||
echo ${gpio_val} > ${gpio_path}/value
|
||||
}
|
||||
|
||||
# WIFI Power ON
|
||||
wifi_power=495
|
||||
set_gpio ${wifi_power} 1
|
||||
# Host Wake BT
|
||||
host_wake_bt=362
|
||||
set_gpio ${host_wake_bt} 1
|
||||
|
||||
# WIFI/BT Module
|
||||
insmod /mnt/system/ko/aic8800_bsp.ko
|
||||
sleep 0.5
|
||||
insmod /mnt/system/ko/aic8800_fdrv.ko
|
||||
|
||||
BIN
device/milkv-duos-sd/overlay/usr/bin/bt_test
Executable file
BIN
device/milkv-duos-sd/overlay/usr/bin/bt_test
Executable file
Binary file not shown.
@ -1,33 +0,0 @@
|
||||
image boot.vfat {
|
||||
vfat {
|
||||
label = "boot"
|
||||
files = {
|
||||
"fip.bin",
|
||||
"rawimages/boot.sd",
|
||||
}
|
||||
}
|
||||
size = 128M
|
||||
}
|
||||
|
||||
image rootfs.ext4 {
|
||||
ext4 {
|
||||
label = "rootfs"
|
||||
}
|
||||
size = 768M
|
||||
}
|
||||
|
||||
image milkv-duos.img {
|
||||
hdimage {
|
||||
}
|
||||
|
||||
partition boot {
|
||||
partition-type = 0xC
|
||||
bootable = "true"
|
||||
image = "boot.vfat"
|
||||
}
|
||||
|
||||
partition rootfs {
|
||||
partition-type = 0x83
|
||||
image = "rootfs.ext4"
|
||||
}
|
||||
}
|
||||
@ -15,6 +15,7 @@
|
||||
#include <linux/semaphore.h>
|
||||
#include <linux/debugfs.h>
|
||||
#include <linux/kthread.h>
|
||||
#include <linux/gpio.h>
|
||||
#include "aicsdio_txrxif.h"
|
||||
#include "aicsdio.h"
|
||||
#include "aic_bsp_driver.h"
|
||||
@ -42,6 +43,11 @@ extern void extern_wifi_set_enable(int is_on);
|
||||
extern void set_power_control_lock(int lock);
|
||||
#endif//for AML
|
||||
|
||||
#ifdef CONFIG_PLATFORM_CVITEK
|
||||
extern int cvi_get_wifi_pwr_on_gpio(void);
|
||||
extern int cvi_sdio_rescan(void);
|
||||
static int cvi_wifi_power_gpio = -1;
|
||||
#endif //CONFIG_PLATFORM_CVITEK
|
||||
|
||||
static int aicbsp_platform_power_on(void);
|
||||
static void aicbsp_platform_power_off(void);
|
||||
@ -67,10 +73,6 @@ module_param_string(saved_sdk_ver, saved_sdk_ver,64, 0660);
|
||||
|
||||
extern int testmode;
|
||||
|
||||
#ifdef CONFIG_PLATFORM_CVITEK
|
||||
extern int cvi_sdio_rescan(void);
|
||||
#endif
|
||||
|
||||
#define SDIO_DEVICE_ID_AIC8801_FUNC2 0x0146
|
||||
#define SDIO_DEVICE_ID_AIC8800D80_FUNC2 0x0182
|
||||
|
||||
@ -508,6 +510,28 @@ static int aicbsp_platform_power_on(void)
|
||||
rockchip_wifi_set_carddetect(1);
|
||||
#endif /*CONFIG_PLATFORM_ROCKCHIP2*/
|
||||
|
||||
#ifdef CONFIG_PLATFORM_CVITEK
|
||||
printk("======== CVITEK WLAN_POWER_ON ========\n");
|
||||
cvi_wifi_power_gpio = cvi_get_wifi_pwr_on_gpio();
|
||||
if (cvi_wifi_power_gpio >= 0) {
|
||||
ret = gpio_request(cvi_wifi_power_gpio, "WLAN_POWER");
|
||||
if (ret < 0) {
|
||||
printk("%s: gpio_request(%d) for WLAN_POWER failed\n",
|
||||
__func__, cvi_wifi_power_gpio);
|
||||
cvi_wifi_power_gpio = -1;
|
||||
}
|
||||
}
|
||||
|
||||
if (cvi_wifi_power_gpio >= 0) {
|
||||
ret = gpio_direction_output(cvi_wifi_power_gpio, 1);
|
||||
if (ret) {
|
||||
printk("%s: WLAN_POWER output high failed!\n", __func__);
|
||||
return -EIO;
|
||||
}
|
||||
mdelay(50);
|
||||
}
|
||||
#endif //CONFIG_PLATFORM_CVITEK
|
||||
|
||||
sema_init(&aic_chipup_sem, 0);
|
||||
ret = aicbsp_reg_sdio_notify(&aic_chipup_sem);
|
||||
if (ret) {
|
||||
@ -521,10 +545,11 @@ static int aicbsp_platform_power_on(void)
|
||||
sunxi_wlan_set_power(1);
|
||||
mdelay(50);
|
||||
sunxi_mmc_rescan_card(aicbsp_bus_index);
|
||||
|
||||
#endif //CONFIG_PLATFORM_ALLWINNER
|
||||
|
||||
#ifdef CONFIG_PLATFORM_CVITEK
|
||||
printk("---aic,%s,%d: cvi_sdio_rescan\n", __func__, __LINE__);
|
||||
printk("%s,%d: cvi_sdio_rescan\n", __func__, __LINE__);
|
||||
cvi_sdio_rescan();
|
||||
//udelay(1000);
|
||||
#endif
|
||||
@ -547,11 +572,19 @@ static int aicbsp_platform_power_on(void)
|
||||
extern_wifi_set_enable(0);
|
||||
#endif
|
||||
|
||||
|
||||
#ifdef CONFIG_PLATFORM_ROCKCHIP2
|
||||
rockchip_wifi_power(0);
|
||||
#endif /*CONFIG_PLATFORM_ROCKCHIP2*/
|
||||
|
||||
#ifdef CONFIG_PLATFORM_CVITEK
|
||||
if (cvi_wifi_power_gpio >= 0) {
|
||||
ret = gpio_direction_output(cvi_wifi_power_gpio, 0);
|
||||
if (ret) {
|
||||
printk("%s: WLAN_POWER output low failed!\n", __func__);
|
||||
}
|
||||
}
|
||||
#endif //CONFIG_PLATFORM_CVITEK
|
||||
|
||||
return -1;
|
||||
}
|
||||
|
||||
@ -580,6 +613,14 @@ static void aicbsp_platform_power_off(void)
|
||||
extern_wifi_set_enable(0);
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_PLATFORM_CVITEK
|
||||
printk("======== CVITEK WLAN_POWER_OFF ========\n");
|
||||
if (cvi_wifi_power_gpio >= 0) {
|
||||
if(gpio_direction_output(cvi_wifi_power_gpio, 0)) {
|
||||
printk("%s: WLAN_POWER output low failed!\n", __func__);
|
||||
}
|
||||
}
|
||||
#endif //CONFIG_PLATFORM_CVITEK
|
||||
|
||||
sdio_dbg("%s\n", __func__);
|
||||
}
|
||||
|
||||
@ -294,7 +294,8 @@ CONFIG_PLATFORM_ROCKCHIP2 ?= n
|
||||
CONFIG_PLATFORM_ALLWINNER ?= n
|
||||
CONFIG_PLATFORM_INGENIC_T20 ?= n
|
||||
CONFIG_PLATFORM_AMLOGIC ?= n
|
||||
CONFIG_PLATFORM_UBUNTU ?= y
|
||||
CONFIG_PLATFORM_UBUNTU ?= n
|
||||
CONFIG_PLATFORM_CVITEK ?= y
|
||||
|
||||
ccflags-y += -DAIC_TRACE_INCLUDE_PATH=$(src)
|
||||
|
||||
@ -364,6 +365,11 @@ ARCH ?= x86_64
|
||||
CROSS_COMPILE ?=
|
||||
endif
|
||||
|
||||
ifeq ($(CONFIG_PLATFORM_CVITEK), y)
|
||||
ARCH ?= riscv
|
||||
#CROSS_COMPILE ?=
|
||||
ccflags-$(CONFIG_PLATFORM_CVITEK) += -DCONFIG_PLATFORM_CVITEK
|
||||
endif
|
||||
|
||||
all: modules
|
||||
modules:
|
||||
|
||||
Reference in New Issue
Block a user