diff --git a/README.md b/README.md index f5b3cf8c..ee56f31a 100644 --- a/README.md +++ b/README.md @@ -74,7 +74,11 @@ phytium_e2000_debian_desktop_defconfig (2)编译 `$ make` (3)镜像的输出位置 -生成的根文件系统、内核位于output/images目录。 +生成的根文件系统、内核、e2000 img 镜像位于output/images目录。 + +#### e2000 img 镜像 +目前buildroot支持编译e2000 img 镜像(disk.img),生成的e2000 img 镜像位于output/images目录。e2000 img 镜像包含了根文件系统、内核、设备树。 +使用e2000 img 镜像安装系统,不需要像之前那样将存储设备手动分区再拷贝文件,只需要将disk.img文件写入存储设备即可。 ### 更换文件系统的linux内核版本 defconfig中的内核版本默认是linux 5.10。我们支持在编译文件系统时将内核版本更换为linux 4.19,linux 4.19 rt,linux 5.10 rt。 @@ -92,7 +96,7 @@ configs/phytium_e2000_linux_5.10_rt.config (2)编译 `$ make` (3)镜像的输出位置 -生成的根文件系统、内核位于output/images目录。 +生成的根文件系统、内核、e2000 img 镜像位于output/images目录。 ### 支持Phytium-optee 本项目还支持编译Phytium-optee,关于Phytium-optee的信息请参考:`https://gitee.com/phytium_embedded/phytium-optee` @@ -105,9 +109,9 @@ defconfig默认不编译Phytium-optee,如果需要编译Phytium-optee请执行 在执行编译之前需要额外安装依赖: ``` sudo apt install python3-pip -pip install pycryptodome -pip install pyelftools -pip install cryptography +pip3 install pycryptodome +pip3 install pyelftools +pip3 install cryptography ``` (2)编译 `$ make` @@ -115,6 +119,69 @@ pip install cryptography 生成的根文件系统、内核、TEE OS位于output/images目录。 后续部署及使用方法,请参考`https://gitee.com/phytium_embedded/phytium-embedded-docs/tree/master/optee` +### 支持xenomai +本项目还支持编译xenomai,关于xenomai的信息请参考:`https://gitee.com/phytium_embedded/linux-kernel-xenomai` +支持将xenomai内核及用户态的库、工具编译安装到debian系统上。如果需要编译xenomai请执行: +(1)使用phytium_e2000_debian_xxx_defconfig作为基础配置项,合并支持xenomai的配置: +`$ ./support/kconfig/merge_config.sh configs/phytium_e2000_debian_xxx_defconfig configs/phytium_e2000_xenomai_xxx.config` +其中,`phytium_e2000_debian_xxx_defconfig`为`phytium_e2000_debian_defconfig`或`phytium_e2000_debian_desktop_defconfig`; +`phytium_e2000_xenomai_xxx.config`为以下配置片段文件之一: +``` +phytium_e2000_xenomai_cobalt_4.19.config (xenomai cobalt 4.19内核+xenomai-v3.1.3.tar.gz) +phytium_e2000_xenomai_cobalt_5.10.config (xenomai cobalt 5.10内核+xenomai-v3.2.2.tar.gz) +phytium_e2000_xenomai_mercury_4.19.config (linux 4.19 rt内核+xenomai-v3.1.3.tar.gz) +phytium_e2000_xenomai_mercury_5.10.config (linux 5.10 rt内核+xenomai-v3.2.2.tar.gz) +``` +(2)编译 +`$ make` +(3)镜像的输出位置 +生成的根文件系统、内核、e2000 img 镜像位于output/images目录。 +(4)文件的安装路径 +xenomai用户态的库、工具被安装到根文件系统: +头文件安装到/usr/include/xenomai,配置文件安装到/etc,其它内容分别被安装到/usr目录下的bin,demo,lib,sbin,share。 +关于xenomai的启动及测试工具等更多信息,请参考`https://gitee.com/phytium_embedded/phytium-embedded-docs/tree/master/xenomai` + +### 支持ethercat +本项目还支持编译ethercat,关于ethercat的信息请参考:`https://gitee.com/phytium_embedded/ether-cat` +支持将ethercat驱动及用户态的库、工具编译安装到debian系统上,ethercat只支持linux 4.19 rt,linux 5.10 rt内核。如果需要编译ethercat请执行: +(1)使用phytium_e2000_debian_xxx_defconfig作为基础配置项,合并支持rt内核,及ethercat的配置: +`./support/kconfig/merge_config.sh configs/phytium_e2000_debian_xxx_defconfig configs/phytium_e2000_linux_xxx_rt.config configs/phytium_e2000_ethercat.config` +其中,`phytium_e2000_debian_xxx_defconfig`为`phytium_e2000_debian_defconfig`或`phytium_e2000_debian_desktop_defconfig`; +`phytium_e2000_linux_xxx_rt.config`为`phytium_e2000_linux_4.19_rt.config`或`phytium_e2000_linux_5.10_rt.config`。 +(2)编译 +`$ make` +(3)镜像的输出位置 +生成的根文件系统、内核、e2000 img 镜像位于output/images目录。 +(4)文件的安装路径 +将ethercat的驱动模块安装到根文件系统的/lib/modules/version/ethercat/目录,并且通过将ec_macb加入/etc/modprobe.d/blacklist.conf +黑名单的方式,使得开机时不自动加载ec_macb模块,而是让用户手动加载。 +ethercat用户态的库、工具被安装到根文件系统: +配置文件安装到/etc,其它内容分别被安装到/usr目录下的bin,include,lib,sbin,share。 +关于ethercat的使用方法等更多信息,请参考`https://gitee.com/phytium_embedded/phytium-embedded-docs/tree/master/ethercat` + +### 支持jailhouse(e2000) +本项目还支持为e2000编译jailhouse,关于jailhouse的信息请参考:`https://gitee.com/phytium_embedded/phytium-jailhouse` +支持将jailhouse编译安装到ubuntu系统,如果需要编译jailhouse请执行: +(1)使用phytium_e2000_ubuntu_xxx_defconfig作为基础配置项,合并支持jailhouse的配置: +`./support/kconfig/merge_config.sh configs/phytium_e2000_ubuntu_xxx_defconfig configs/phytium_e2000_jailhouse_xxx.config` +其中,`phytium_e2000_ubuntu_xxx_defconfig`为`phytium_e2000_ubuntu_defconfig`或`phytium_e2000_ubuntu_desktop_defconfig`; +`phytium_e2000_jailhouse_xxx.config`为`phytium_e2000_jailhouse_4.19.config`或`phytium_e2000_jailhouse_5.10.config`。 +(2)编译 +`$ make` +(3)镜像的输出位置 +生成的根文件系统、内核、e2000 img 镜像位于output/images目录。 +(4)文件的安装路径 +jailhouse相关的文件被安装到根文件系统: +``` +按照Makefile中的规则,将jailhouse的驱动jailhouse.ko安装到/lib/modules/version/jailhouse/driver;jailhouse.bin安装到/lib/firmware; +linux-loader.bin安装到/usr/local/libexec/jailhouse;jailhouse和ivshmem-demo安装到/usr/local/sbin; +python helper脚本安装到/usr/local/libexec/jailhouse;jailhouse-config-collect.tmpl和root-cell-config.c.tmpl +安装到/usr/local/share/jailhouse;jailhouse-completion.bash安装到/usr/share/bash-completion/completions/并改名为jailhouse; +另外,还将configs/*/*.cell安装到/etc/jailhouse;inmates/demos/*/*.bin安装到/usr/local/libexec/jailhouse/demos; +pyjailhouse安装到/usr/lib/python3.10/site-packages。 +``` +关于jailhouse的使用方法等更多信息,请参考`https://gitee.com/phytium_embedded/phytium-jailhouse/blob/master/Readme.md` + ## 清理编译结果 (1)`$ make clean` 删除所有编译结果,包括output目录下的所有内容。当编译完一个文件系统后,编译另一个文件系统前,需要执行此命令。 @@ -122,6 +189,8 @@ pip install cryptography 重置buildroot,删除所有编译结果、下载目录以及配置。 ## 为d2000编译文件系统 +与“为e2000编译文件系统”相比,“为d2000编译文件系统”还需要“准备内核源码”和“编译initrd”。 +### 准备内核源码 (1)在phytium-linux-buildroot的根目录下创建files目录,将内核源码拷贝到files目录并重命名为linux-4.19.tar.gz `$ mkdir files` `$ cp xxx/linux-4.19-master.tar.gz files/linux-4.19.tar.gz` @@ -133,28 +202,56 @@ $ sha256sum files/linux-4.19.tar.gz 编辑linux/linux.hash文件,将linux-4.19.tar.gz对应行的哈希值修改为刚刚计算的哈希值,如下所示: `sha256 22a2345f656b0624790dcbb4b5884827c915aef00986052fd8d9677b9ee6b50e linux-4.19.tar.gz` 注意:每次更新files目录里面的内核源码,都需要同时修改linux/linux.hash里面内核源码对应的哈希值,这是为了验证files目录中的文件与dl目录中的文件一致。 -(3)配置及编译initrd + +### 编译initrd +(1)配置及编译initrd ``` $ make phytium_initrd_defconfig $ make ``` -(4)将编译好的initrd备份保存 +(2)将编译好的initrd备份保存 `$ cp xxx/phytium-linux-buildroot/output/images/rootfs.cpio.gz ~/initrd` -(5)清理编译结果 +(3)清理编译结果 `$ make clean` -(6)配置以下文件系统之一: -`$ make phytium_d2000_ubuntu_defconfig` -`$ make phytium_d2000_defconfig` -`$ make phytium_d2000_debian_defconfig` -`$ make phytium_d2000_debian_desktop_defconfig` -(7)编译文件系统 + +### 编译默认配置的文件系统 +(1)加载defconfig +`$ make phytium_d2000_xxx_defconfig` +其中`phytium_d2000_xxx_defconfig`为以下文件系统之一: +``` +phytium_d2000_ubuntu_defconfig +phytium_d2000_defconfig +phytium_d2000_debian_defconfig +phytium_d2000_debian_desktop_defconfig +``` +(2)编译文件系统 `$ make` -(8)镜像的输出位置 +(3)镜像的输出位置 生成的根文件系统、内核位于output/images目录。 +### 支持无桌面qt5 eglfs +本项目还支持将qt5 eglfs编译安装到无桌面的ubuntu系统,对应的配置文件为`phytium_d2000_ubuntu_qt5_defconfig`,用来运行在d2000+x100上。 +如果需要编译qt5 eglfs请执行: +(1)加载defconfig +`$ make phytium_d2000_ubuntu_qt5_defconfig` +(2)编译文件系统 +`$ make` +(3)镜像的输出位置 +生成的根文件系统、内核位于output/images目录。 +(4)文件的安装路径 +qt5相关的文件被安装到根文件系统的/usr目录: +头文件安装到/usr/include/qt5,库安装到/usr/lib,plugins安装到/usr/lib/qt/plugins,examples安装到/usr/lib/qt/examples。 + +### 支持jailhouse(d2000/ft2004) +本项目还支持为d2000/ft2004编译jailhouse,编译步骤与为e2000编译jailhouse的步骤类似,请参考“为e2000编译文件系统>支持jailhouse(e2000)”。 +除了将第(1)步,修改为: +(1)使用phytium_d2000_ubuntu_defconfig作为基础配置项,合并支持jailhouse的配置: +`./support/kconfig/merge_config.sh configs/phytium_d2000_ubuntu_defconfig configs/phytium_d2000_jailhouse.config` +其余步骤与为e2000编译jailhouse的步骤相同。 + # 在开发板上启动文件系统 ## 在e2000开发板上启动文件系统 -### 使用U-Boot启动文件系统 +### 使用U-Boot启动文件系统(手动分区) (1)主机端将SATA盘或U盘分成两个分区(以主机识别设备名为/dev/sdb 为例,请按实际识别设备名更改) `$ sudo fdisk /dev/sdb` @@ -193,6 +290,27 @@ U盘: =>booti 0x90100000 - 0x90000000 ``` +### 使用U-Boot启动文件系统(使用e2000 img 镜像) +(1)将e2000 img 镜像(disk.img)写入SATA盘或U盘: +`$ sudo dd if=xxx/phytium-linux-buildroot/output/images/disk.img of=/dev/sdb bs=1M` + +(2)SATA盘或U盘接到开发板,启动开发板电源,串口输出U-Boot命令行,设置U-Boot环境变量,启动文件系统 +SATA盘: +``` +=>setenv bootargs console=ttyAMA1,115200 audit=0 earlycon=pl011,0x2800d000 root=/dev/sda2 rw; +=>fatload scsi 0:1 0x90100000 Image; +=>fatload scsi 0:1 0x90000000 e2000q-demo-board.dtb; +=>booti 0x90100000 - 0x90000000 +``` +U盘: +``` +=>setenv bootargs console=ttyAMA1,115200 audit=0 earlycon=pl011,0x2800d000 root=/dev/sda2 rootdelay=5 rw; +=>usb start +=>fatload usb 0:1 0x90100000 Image; +=>fatload usb 0:1 0x90000000 e2000q-demo-board.dtb; +=>booti 0x90100000 - 0x90000000 +``` + ## 在d2000开发板上启动文件系统 ### 使用U-Boot启动文件系统 (1)主机端将SATA盘或U盘分成两个分区(以主机识别设备名为/dev/sdb 为例,请按实际识别设备名更改) @@ -380,3 +498,5 @@ rm -rf dl/linux/ make linux-dirclean make ``` + +5、关于e2000 vpu的包请咨询飞腾技术支持或FAE。 diff --git a/board/phytium/common/debian-package-installer b/board/phytium/common/debian-package-installer index c89b7b0a..d2e8ce06 100755 --- a/board/phytium/common/debian-package-installer +++ b/board/phytium/common/debian-package-installer @@ -78,6 +78,7 @@ do_distrorfs_second_stage() { if [ $5 = E2000 ]; then echo 'defaults.pcm.!card phytiumpe220xi2' >> /etc/asound.conf echo 'defaults.ctl.!card phytiumpe220xi2' >> /etc/asound.conf + echo 'default-sink = alsa_output.platform-sound.stereo-fallback' >> /etc/pulse/client.conf fi # clean cached packages diff --git a/board/phytium/common/post-custom-skeleton-debian-base-11.sh b/board/phytium/common/post-custom-skeleton-debian-base-11.sh index f51d15f7..ac79cd4b 100755 --- a/board/phytium/common/post-custom-skeleton-debian-base-11.sh +++ b/board/phytium/common/post-custom-skeleton-debian-base-11.sh @@ -327,6 +327,24 @@ main() ln -sf /lib/systemd/system/phytium-tee-supplicant.service $RFSDIR/etc/systemd/system/sysinit.target.wants/phytium-tee-supplicant.service fi + if grep -Eq "^BR2_PACKAGE_XENOMAI=y$" ${BR2_CONFIG}; then + make xenomai-rebuild ${O:+O=$O} + fi + + if grep -Eq "^BR2_PACKAGE_IGH_ETHERCAT=y$" ${BR2_CONFIG}; then + make igh-ethercat-rebuild ${O:+O=$O} + fi + + if grep -Eq "^BR2_PACKAGE_OPEN62541=y$" ${BR2_CONFIG}; then + make open62541-rebuild ${O:+O=$O} + fi + + # change the priority order of the shared library directories + sed -i '1 i /usr/local/lib' $1/etc/ld.so.conf + sudo chroot $1 ldconfig + sudo chown -R $USER:$GROUPS $1/etc/ld.so.cache + sudo chown -R $USER:$GROUPS $1/var/cache/ldconfig/aux-cache + exit $? } diff --git a/board/phytium/common/post-custom-skeleton-ubuntu-base-20.04.sh b/board/phytium/common/post-custom-skeleton-ubuntu-base-20.04.sh index 6357e89e..2bca1954 100755 --- a/board/phytium/common/post-custom-skeleton-ubuntu-base-20.04.sh +++ b/board/phytium/common/post-custom-skeleton-ubuntu-base-20.04.sh @@ -329,6 +329,34 @@ main() ln -sf /lib/systemd/system/phytium-tee-supplicant.service $RFSDIR/etc/systemd/system/sysinit.target.wants/phytium-tee-supplicant.service fi + if grep -Eq "^BR2_PACKAGE_QT5BASE=y$" ${BR2_CONFIG}; then + make pcre2-rebuild ${O:+O=$O} + make qt5base-rebuild ${O:+O=$O} + fi + + if grep -Eq "^BR2_PACKAGE_QT5DECLARATIVE=y$" ${BR2_CONFIG}; then + make qt5declarative-rebuild ${O:+O=$O} + fi + + if grep -Eq "^BR2_PACKAGE_QT53D=y$" ${BR2_CONFIG}; then + make qt53d-rebuild ${O:+O=$O} + fi + + if grep -Eq "^BR2_PACKAGE_JAILHOUSE=y$" ${BR2_CONFIG}; then + make jailhouse-rebuild ${O:+O=$O} + fi + + if grep -Eq "^BR2_PACKAGE_PYTHON3=y$" ${BR2_CONFIG}; then + make libffi-rebuild ${O:+O=$O} + make python3-rebuild ${O:+O=$O} + fi + + # change the priority order of the shared library directories + sed -i '1 i /usr/local/lib' $1/etc/ld.so.conf + sudo chroot $1 ldconfig + sudo chown -R $USER:$GROUPS $1/etc/ld.so.cache + sudo chown -R $USER:$GROUPS $1/var/cache/ldconfig/aux-cache + exit $? } diff --git a/board/phytium/common/ubuntu-additional_packages_list b/board/phytium/common/ubuntu-additional_packages_list index 929bee45..22e00010 100644 --- a/board/phytium/common/ubuntu-additional_packages_list +++ b/board/phytium/common/ubuntu-additional_packages_list @@ -2,5 +2,5 @@ additional_full_packages_list=" " # for Lite userland gathered from main repo -additional_base_packages_list="net-tools iputils-ping gcc vim make autoconf automake bison bc flex libssl-dev \ -libgstreamer1.0-0 gstreamer1.0-plugins-base gstreamer1.0-plugins-good gstreamer1.0-plugins-bad gstreamer1.0-plugins-ugly gstreamer1.0-libav gstreamer1.0-tools gstreamer1.0-x gstreamer1.0-alsa gstreamer1.0-gl gstreamer1.0-gtk3 gstreamer1.0-qt5 gstreamer1.0-pulseaudio " +additional_base_packages_list="net-tools iputils-ping gcc g++ vim make autoconf automake libtool pkg-config bison bc flex libssl-dev openssh-server \ +libgstreamer1.0-0 gstreamer1.0-plugins-base gstreamer1.0-plugins-good gstreamer1.0-plugins-bad gstreamer1.0-plugins-ugly gstreamer1.0-libav gstreamer1.0-tools gstreamer1.0-x gstreamer1.0-alsa gstreamer1.0-gl gstreamer1.0-gtk3 gstreamer1.0-pulseaudio " diff --git a/board/phytium/genimage-e2000.cfg b/board/phytium/genimage-e2000.cfg index 7544758c..0d5b0ffc 100644 --- a/board/phytium/genimage-e2000.cfg +++ b/board/phytium/genimage-e2000.cfg @@ -31,14 +31,15 @@ image disk.img { partition boot { image = "efi-part.vfat" - partition-type-uuid = 0FC63DAF-8483-4772-8E79-3D69D8477DE4 + partition-type-uuid = c12a7328-f81f-11d2-ba4b-00a0c93ec93b offset = 32K bootable = true } partition root { partition-type-uuid = 0FC63DAF-8483-4772-8E79-3D69D8477DE4 + partition-uuid = "0a52c129-7e0f-43ad-989f-d96b07ccdbb2" image = "rootfs.ext2" - size = 3G + size = 6G } } diff --git a/board/phytium/grub.cfg b/board/phytium/grub.cfg index b3c3299b..04506814 100644 --- a/board/phytium/grub.cfg +++ b/board/phytium/grub.cfg @@ -2,6 +2,5 @@ set default="0" set timeout="5" menuentry "Buildroot" { - linux /Image root=/dev/sdb2 rootdelay=10 rw - initrd /initrd + linux /Image root=PARTUUID="0a52c129-7e0f-43ad-989f-d96b07ccdbb2" rootdelay=10 rw console=ttyAMA0,115200 } diff --git a/boot/grub2/grub.cfg b/boot/grub2/grub.cfg index bd3e3f00..4006eb94 100644 --- a/boot/grub2/grub.cfg +++ b/boot/grub2/grub.cfg @@ -2,5 +2,6 @@ set default="0" set timeout="5" menuentry "Buildroot" { - linux /boot/bzImage root=/dev/sda1 rootwait console=tty1 + linux /Image root=/dev/sda2 rw + initrd /initrd } diff --git a/configs/phytium_d2000_debian_defconfig b/configs/phytium_d2000_debian_defconfig index 7588dc63..2dbc9eb2 100644 --- a/configs/phytium_d2000_debian_defconfig +++ b/configs/phytium_d2000_debian_defconfig @@ -5,11 +5,7 @@ BR2_cortex_a53=y # Filesystem BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y -#BR2_TARGET_ROOTFS_EXT2_SIZE="600M" -#BR2_TARGET_ROOTFS_INITRAMFS=y -#BR2_ROOTFS_RESIZE=y -#BR2_ROOTFS_POST_IMAGE_SCRIPT="board/phytium/post-image.sh support/scripts/genimage.sh" -#BR2_ROOTFS_POST_SCRIPT_ARGS="-c board/phytium/genimage-efi.cfg" +BR2_TARGET_ROOTFS_EXT2_SIZE="5G" # custom skeleton BR2_ROOTFS_SKELETON_UBUNTU=y @@ -42,7 +38,7 @@ BR2_LINUX_KERNEL_USE_ARCH_DEFAULT_CONFIG=y BR2_LINUX_KERNEL_CUSTOM_TARBALL_LOCATION="file://$(TOPDIR)/files/linux-4.19.tar.gz" BR2_LINUX_KERNEL_CONFIG_FRAGMENT_FILES="$(LINUX_DIR)/arch/arm64/configs/sdk.config" BR2_LINUX_KERNEL_DTS_SUPPORT=y -BR2_LINUX_KERNEL_INTREE_DTS_NAME="phytium/d2000-devboard-dsk" +BR2_LINUX_KERNEL_INTREE_DTS_NAME="phytium/d2000-devboard-dsk phytium/ft2004-devboard-d4-dsk" BR2_LINUX_KERNEL_IMAGE_TARGET_CUSTOM=y BR2_LINUX_KERNEL_IMAGE_TARGET_NAME="Image" BR2_LINUX_KERNEL_NEEDS_HOST_OPENSSL=y diff --git a/configs/phytium_d2000_debian_desktop_defconfig b/configs/phytium_d2000_debian_desktop_defconfig index cac7452e..762eb8c1 100644 --- a/configs/phytium_d2000_debian_desktop_defconfig +++ b/configs/phytium_d2000_debian_desktop_defconfig @@ -5,11 +5,8 @@ BR2_cortex_a53=y # Filesystem BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y -#BR2_TARGET_ROOTFS_EXT2_SIZE="600M" -#BR2_TARGET_ROOTFS_INITRAMFS=y +BR2_TARGET_ROOTFS_EXT2_SIZE="5G" BR2_ROOTFS_CHOWN=y -#BR2_ROOTFS_POST_IMAGE_SCRIPT="board/phytium/post-image.sh support/scripts/genimage.sh" -#BR2_ROOTFS_POST_SCRIPT_ARGS="-c board/phytium/genimage-efi.cfg" # custom skeleton BR2_ROOTFS_SKELETON_UBUNTU=y @@ -42,7 +39,7 @@ BR2_LINUX_KERNEL_USE_ARCH_DEFAULT_CONFIG=y BR2_LINUX_KERNEL_CUSTOM_TARBALL_LOCATION="file://$(TOPDIR)/files/linux-4.19.tar.gz" BR2_LINUX_KERNEL_CONFIG_FRAGMENT_FILES="$(LINUX_DIR)/arch/arm64/configs/sdk.config" BR2_LINUX_KERNEL_DTS_SUPPORT=y -BR2_LINUX_KERNEL_INTREE_DTS_NAME="phytium/d2000-devboard-dsk" +BR2_LINUX_KERNEL_INTREE_DTS_NAME="phytium/d2000-devboard-dsk phytium/ft2004-devboard-d4-dsk" BR2_LINUX_KERNEL_IMAGE_TARGET_CUSTOM=y BR2_LINUX_KERNEL_IMAGE_TARGET_NAME="Image" BR2_LINUX_KERNEL_NEEDS_HOST_OPENSSL=y diff --git a/configs/phytium_d2000_defconfig b/configs/phytium_d2000_defconfig index f986589c..1b8b58c9 100644 --- a/configs/phytium_d2000_defconfig +++ b/configs/phytium_d2000_defconfig @@ -6,10 +6,6 @@ BR2_cortex_a53=y BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y BR2_TARGET_ROOTFS_EXT2_SIZE="200M" -BR2_TARGET_ROOTFS_INITRAMFS=y -BR2_ROOTFS_RESIZE=y -BR2_ROOTFS_POST_IMAGE_SCRIPT="board/phytium/post-image.sh support/scripts/genimage.sh" -BR2_ROOTFS_POST_SCRIPT_ARGS="-c board/phytium/genimage-efi.cfg" # Hostname and issue BR2_TARGET_GENERIC_HOSTNAME="D2000" @@ -31,7 +27,7 @@ BR2_LINUX_KERNEL_USE_ARCH_DEFAULT_CONFIG=y BR2_LINUX_KERNEL_CUSTOM_TARBALL_LOCATION="file://$(TOPDIR)/files/linux-4.19.tar.gz" BR2_LINUX_KERNEL_CONFIG_FRAGMENT_FILES="$(LINUX_DIR)/arch/arm64/configs/sdk.config" BR2_LINUX_KERNEL_DTS_SUPPORT=y -BR2_LINUX_KERNEL_INTREE_DTS_NAME="phytium/d2000-devboard-dsk" +BR2_LINUX_KERNEL_INTREE_DTS_NAME="phytium/d2000-devboard-dsk phytium/ft2004-devboard-d4-dsk" BR2_LINUX_KERNEL_IMAGE_TARGET_CUSTOM=y BR2_LINUX_KERNEL_IMAGE_TARGET_NAME="Image" BR2_LINUX_KERNEL_NEEDS_HOST_OPENSSL=y diff --git a/configs/phytium_d2000_jailhouse.config b/configs/phytium_d2000_jailhouse.config new file mode 100644 index 00000000..84f18c14 --- /dev/null +++ b/configs/phytium_d2000_jailhouse.config @@ -0,0 +1,10 @@ +# jailhouse +BR2_PACKAGE_JAILHOUSE=y + +# jailhouse helper scripts +BR2_PACKAGE_PYTHON3=y +BR2_PACKAGE_PYTHON3_ZLIB=y +BR2_PACKAGE_JAILHOUSE_HELPER_SCRIPTS=y + +# kernel patch for d2000 and ft2004 +BR2_LINUX_KERNEL_PATCH="$(LINUX_PKGDIR)/kernel-patches/jailhouse/0001-modify-the-dts-of-d2000-and-ft2004-linux-kernel-to-r.patch" diff --git a/configs/phytium_d2000_ubuntu_defconfig b/configs/phytium_d2000_ubuntu_defconfig index 4b751cb7..7715de6f 100644 --- a/configs/phytium_d2000_ubuntu_defconfig +++ b/configs/phytium_d2000_ubuntu_defconfig @@ -5,11 +5,8 @@ BR2_cortex_a53=y # Filesystem BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y -#BR2_TARGET_ROOTFS_EXT2_SIZE="600M" -#BR2_TARGET_ROOTFS_INITRAMFS=y +BR2_TARGET_ROOTFS_EXT2_SIZE="5G" BR2_ROOTFS_CHOWN=y -#BR2_ROOTFS_POST_IMAGE_SCRIPT="board/phytium/post-image.sh support/scripts/genimage.sh" -#BR2_ROOTFS_POST_SCRIPT_ARGS="-c board/phytium/genimage-efi.cfg" # custom skeleton BR2_ROOTFS_SKELETON_UBUNTU=y @@ -42,7 +39,7 @@ BR2_LINUX_KERNEL_USE_ARCH_DEFAULT_CONFIG=y BR2_LINUX_KERNEL_CUSTOM_TARBALL_LOCATION="file://$(TOPDIR)/files/linux-4.19.tar.gz" BR2_LINUX_KERNEL_CONFIG_FRAGMENT_FILES="$(LINUX_DIR)/arch/arm64/configs/sdk.config" BR2_LINUX_KERNEL_DTS_SUPPORT=y -BR2_LINUX_KERNEL_INTREE_DTS_NAME="phytium/d2000-devboard-dsk" +BR2_LINUX_KERNEL_INTREE_DTS_NAME="phytium/d2000-devboard-dsk phytium/ft2004-devboard-d4-dsk" BR2_LINUX_KERNEL_IMAGE_TARGET_CUSTOM=y BR2_LINUX_KERNEL_IMAGE_TARGET_NAME="Image" BR2_LINUX_KERNEL_NEEDS_HOST_OPENSSL=y diff --git a/configs/phytium_e2000_xenomai_defconfig b/configs/phytium_d2000_ubuntu_qt5_defconfig similarity index 59% rename from configs/phytium_e2000_xenomai_defconfig rename to configs/phytium_d2000_ubuntu_qt5_defconfig index 058d4ae1..b68a2cf1 100644 --- a/configs/phytium_e2000_xenomai_defconfig +++ b/configs/phytium_d2000_ubuntu_qt5_defconfig @@ -5,6 +5,8 @@ BR2_cortex_a53=y # Filesystem BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y +BR2_TARGET_ROOTFS_EXT2_SIZE="5G" +BR2_ROOTFS_CHOWN=y # custom skeleton BR2_ROOTFS_SKELETON_UBUNTU=y @@ -16,11 +18,9 @@ BR2_ROOTFS_SKELETON_CUSTOM_EXTRACT="tar zxvf" BR2_ROOTFS_SKELETON_CUSTOM_EXTRACT_IGNORE_ERROR=y BR2_ROOTFS_POST_BUILD_SCRIPT="board/phytium/common/post-custom-skeleton-ubuntu-base-20.04.sh" BR2_INIT_NONE=y -BR2_ROOTFS_CHOWN=y # Hostname and issue -BR2_TARGET_GENERIC_HOSTNAME="E2000" -BR2_TARGET_GENERIC_ISSUE="Welcome to Phytium Buildroot" +BR2_TARGET_GENERIC_HOSTNAME="D2000" # toolchain BR2_TOOLCHAIN_EXTERNAL=y @@ -28,18 +28,14 @@ BR2_TOOLCHAIN_EXTERNAL_ARM_AARCH64=y BR2_TOOLCHAIN_USES_GLIBC=y BR2_TOOLCHAIN_EXTERNAL_GLIBC=y -# Linux headers same as kernel -BR2_PACKAGE_HOST_LINUX_HEADERS_CUSTOM_4_19=y - # Kernel BR2_LINUX_KERNEL=y -BR2_LINUX_KERNEL_CUSTOM_GIT=y -BR2_LINUX_KERNEL_CUSTOM_REPO_URL="https://gitee.com/phytium_embedded/linux-kernel-xenomai.git" -BR2_LINUX_KERNEL_CUSTOM_REPO_VERSION="kernel_5.10.153-dovetail3_2023-v1.0-RC1" -BR2_LINUX_KERNEL_INTREE_DTS_NAME="phytium/e2000d-demo-board phytium/e2000d-miniitx-board phytium/e2000d-power-board phytium/e2000q-come-board phytium/e2000q-demo-board phytium/e2000q-edu-board phytium/e2000q-hanwei-board phytium/e2000q-miniitx-board phytium/e2000q-vpx-board phytium/e2000s-demo-board" +BR2_LINUX_KERNEL_CUSTOM_TARBALL=y +BR2_LINUX_KERNEL_USE_ARCH_DEFAULT_CONFIG=y +BR2_LINUX_KERNEL_CUSTOM_TARBALL_LOCATION="file://$(TOPDIR)/files/linux-4.19.tar.gz" +BR2_LINUX_KERNEL_CONFIG_FRAGMENT_FILES="$(LINUX_DIR)/arch/arm64/configs/sdk.config" BR2_LINUX_KERNEL_DTS_SUPPORT=y -BR2_LINUX_KERNEL_DEFCONFIG="phytium" -BR2_LINUX_KERNEL_CONFIG_FRAGMENT_FILES="$(LINUX_DIR)/arch/arm64/configs/cobalt.config" +BR2_LINUX_KERNEL_INTREE_DTS_NAME="phytium/d2000-devboard-dsk phytium/ft2004-devboard-d4-dsk" BR2_LINUX_KERNEL_IMAGE_TARGET_CUSTOM=y BR2_LINUX_KERNEL_IMAGE_TARGET_NAME="Image" BR2_LINUX_KERNEL_NEEDS_HOST_OPENSSL=y @@ -49,15 +45,30 @@ BR2_ROOTFS_LINUX_HEADERS=y BR2_TARGET_GRUB2=y BR2_TARGET_GRUB2_ARM64_EFI=y - -# Serial port config -BR2_TARGET_GENERIC_GETTY=y -BR2_TARGET_GENERIC_GETTY_PORT="ttyAMA0" - # required tools to create the microSD image BR2_PACKAGE_HOST_DOSFSTOOLS=y BR2_PACKAGE_HOST_GENIMAGE=y BR2_PACKAGE_HOST_MTOOLS=y -BR2_PACKAGE_ROOTFS_DESKTOP=y BR2_PACKAGE_BUSYBOX=n + +# X100 +BR2_PACKAGE_XORG_ROGUE_UMLIBS=y + +# Vpu-lib +BR2_PACKAGE_VPU_LIB=y +BR2_PACKAGE_VPU_LIB_CPU_MODEL="d2000" + +# FFmpeg +BR2_PACKAGE_FFMPEG=y + +# Qt5 +BR2_PACKAGE_QT5=y +BR2_PACKAGE_QT5BASE_EXAMPLES=y +BR2_PACKAGE_QT5BASE_GUI=y +BR2_PACKAGE_QT5BASE_EGLFS=y +BR2_PACKAGE_QT5BASE_DEFAULT_QPA="eglfs" +BR2_PACKAGE_QT5BASE_OPENGL=y +BR2_PACKAGE_QT5BASE_OPENGL_ES2=y +BR2_PACKAGE_QT53D=y +BR2_PACKAGE_LIBDRM=y diff --git a/configs/phytium_e2000_debian_defconfig b/configs/phytium_e2000_debian_defconfig index e7131e32..809bd7e3 100644 --- a/configs/phytium_e2000_debian_defconfig +++ b/configs/phytium_e2000_debian_defconfig @@ -5,6 +5,9 @@ BR2_cortex_a53=y # Filesystem BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y +BR2_TARGET_ROOTFS_EXT2_SIZE="5G" +BR2_ROOTFS_POST_IMAGE_SCRIPT="board/phytium/post-image.sh support/scripts/genimage.sh" +BR2_ROOTFS_POST_SCRIPT_ARGS="-c board/phytium/genimage-e2000.cfg" # custom skeleton BR2_ROOTFS_SKELETON_UBUNTU=y @@ -36,7 +39,7 @@ BR2_LINUX_KERNEL=y BR2_LINUX_KERNEL_CUSTOM_GIT=y BR2_LINUX_KERNEL_CUSTOM_REPO_URL="https://gitee.com/phytium_embedded/phytium-linux-kernel.git" # kernel 5.10 -BR2_LINUX_KERNEL_CUSTOM_REPO_VERSION="kernel_5.10_2023-v1.0-RC1" +BR2_LINUX_KERNEL_CUSTOM_REPO_VERSION="kernel_5.10_2023-v1.0-GA" BR2_LINUX_KERNEL_INTREE_DTS_NAME="phytium/e2000d-demo-board phytium/e2000d-miniitx-board phytium/e2000d-power-board phytium/e2000q-come-board phytium/e2000q-demo-board phytium/e2000q-edu-board phytium/e2000q-hanwei-board phytium/e2000q-miniitx-board phytium/e2000q-vpx-board phytium/e2000s-demo-board" BR2_LINUX_KERNEL_DTS_SUPPORT=y BR2_LINUX_KERNEL_DEFCONFIG="phytium" diff --git a/configs/phytium_e2000_debian_desktop_defconfig b/configs/phytium_e2000_debian_desktop_defconfig index 9b4f1b9d..cc3369c4 100644 --- a/configs/phytium_e2000_debian_desktop_defconfig +++ b/configs/phytium_e2000_debian_desktop_defconfig @@ -5,6 +5,9 @@ BR2_cortex_a53=y # Filesystem BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y +BR2_TARGET_ROOTFS_EXT2_SIZE="5G" +BR2_ROOTFS_POST_IMAGE_SCRIPT="board/phytium/post-image.sh support/scripts/genimage.sh" +BR2_ROOTFS_POST_SCRIPT_ARGS="-c board/phytium/genimage-e2000.cfg" # custom skeleton BR2_ROOTFS_SKELETON_UBUNTU=y @@ -36,7 +39,7 @@ BR2_LINUX_KERNEL=y BR2_LINUX_KERNEL_CUSTOM_GIT=y BR2_LINUX_KERNEL_CUSTOM_REPO_URL="https://gitee.com/phytium_embedded/phytium-linux-kernel.git" # kernel 5.10 -BR2_LINUX_KERNEL_CUSTOM_REPO_VERSION="kernel_5.10_2023-v1.0-RC1" +BR2_LINUX_KERNEL_CUSTOM_REPO_VERSION="kernel_5.10_2023-v1.0-GA" BR2_LINUX_KERNEL_INTREE_DTS_NAME="phytium/e2000d-demo-board phytium/e2000d-miniitx-board phytium/e2000d-power-board phytium/e2000q-come-board phytium/e2000q-demo-board phytium/e2000q-edu-board phytium/e2000q-hanwei-board phytium/e2000q-miniitx-board phytium/e2000q-vpx-board phytium/e2000s-demo-board" BR2_LINUX_KERNEL_DTS_SUPPORT=y BR2_LINUX_KERNEL_DEFCONFIG="phytium" diff --git a/configs/phytium_e2000_defconfig b/configs/phytium_e2000_defconfig index ea6f3e0e..6796503b 100644 --- a/configs/phytium_e2000_defconfig +++ b/configs/phytium_e2000_defconfig @@ -18,7 +18,10 @@ BR2_ROOTFS_OVERLAY="board/phytium/common/busybox_init_overlay" # Filesystem BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y -BR2_TARGET_ROOTFS_EXT2_SIZE="200M" +BR2_TARGET_ROOTFS_EXT2_SIZE="2G" +BR2_ROOTFS_POST_IMAGE_SCRIPT="board/phytium/post-image.sh support/scripts/genimage.sh" +BR2_ROOTFS_POST_SCRIPT_ARGS="-c board/phytium/genimage-e2000.cfg" + # Bootloader BR2_TARGET_GRUB2=y @@ -33,7 +36,7 @@ BR2_LINUX_KERNEL=y BR2_LINUX_KERNEL_CUSTOM_GIT=y BR2_LINUX_KERNEL_CUSTOM_REPO_URL="https://gitee.com/phytium_embedded/phytium-linux-kernel.git" # kernel 5.10 -BR2_LINUX_KERNEL_CUSTOM_REPO_VERSION="kernel_5.10_2023-v1.0-RC1" +BR2_LINUX_KERNEL_CUSTOM_REPO_VERSION="kernel_5.10_2023-v1.0-GA" BR2_LINUX_KERNEL_DEFCONFIG="phytium" BR2_LINUX_KERNEL_IMAGE_TARGET_CUSTOM=y BR2_LINUX_KERNEL_IMAGE_TARGET_NAME="Image" diff --git a/configs/phytium_e2000_ethercat.config b/configs/phytium_e2000_ethercat.config new file mode 100644 index 00000000..4a46095a --- /dev/null +++ b/configs/phytium_e2000_ethercat.config @@ -0,0 +1,5 @@ +# ethercat +BR2_PACKAGE_IGH_ETHERCAT=y + +# open62541 +BR2_PACKAGE_OPEN62541=y diff --git a/configs/phytium_e2000_jailhouse_4.19.config b/configs/phytium_e2000_jailhouse_4.19.config new file mode 100644 index 00000000..daae1bc5 --- /dev/null +++ b/configs/phytium_e2000_jailhouse_4.19.config @@ -0,0 +1,13 @@ +# jailhouse +BR2_PACKAGE_JAILHOUSE=y + +# jailhouse helper scripts +BR2_PACKAGE_PYTHON3=y +BR2_PACKAGE_PYTHON3_ZLIB=y +BR2_PACKAGE_JAILHOUSE_HELPER_SCRIPTS=y + +# kernel 4.19 +BR2_LINUX_KERNEL_CUSTOM_REPO_VERSION="kernel_4.19_2023-v1.0-GA" + +# kernel patch for e2000 linux-4.19 +BR2_LINUX_KERNEL_PATCH="$(LINUX_PKGDIR)/kernel-patches/jailhouse/0001-modify-the-dts-of-e2000-linux-4.19-kernel-to-reserve.patch" diff --git a/configs/phytium_e2000_jailhouse_5.10.config b/configs/phytium_e2000_jailhouse_5.10.config new file mode 100644 index 00000000..a35f25be --- /dev/null +++ b/configs/phytium_e2000_jailhouse_5.10.config @@ -0,0 +1,10 @@ +# jailhouse +BR2_PACKAGE_JAILHOUSE=y + +# jailhouse helper scripts +BR2_PACKAGE_PYTHON3=y +BR2_PACKAGE_PYTHON3_ZLIB=y +BR2_PACKAGE_JAILHOUSE_HELPER_SCRIPTS=y + +# kernel patch for e2000 linux-5.10 +BR2_LINUX_KERNEL_PATCH="$(LINUX_PKGDIR)/kernel-patches/jailhouse/0001-modify-the-dts-of-e2000-linux-5.10-kernel-to-reserve.patch" diff --git a/configs/phytium_e2000_linux_4.19.config b/configs/phytium_e2000_linux_4.19.config index 32ba6103..f9041e24 100644 --- a/configs/phytium_e2000_linux_4.19.config +++ b/configs/phytium_e2000_linux_4.19.config @@ -1,2 +1,2 @@ # kernel 4.19 -BR2_LINUX_KERNEL_CUSTOM_REPO_VERSION="kernel_4.19_2023-v1.0-RC1" +BR2_LINUX_KERNEL_CUSTOM_REPO_VERSION="kernel_4.19_2023-v1.0-GA" diff --git a/configs/phytium_e2000_linux_4.19_rt.config b/configs/phytium_e2000_linux_4.19_rt.config index 9f353d17..55e9b83a 100644 --- a/configs/phytium_e2000_linux_4.19_rt.config +++ b/configs/phytium_e2000_linux_4.19_rt.config @@ -1,2 +1,2 @@ # kernel 4.19-rt -BR2_LINUX_KERNEL_CUSTOM_REPO_VERSION="kernel_4.19-rt_2023-v1.0-RC1" +BR2_LINUX_KERNEL_CUSTOM_REPO_VERSION="kernel_4.19-rt_2023-v1.0-GA" diff --git a/configs/phytium_e2000_linux_5.10_rt.config b/configs/phytium_e2000_linux_5.10_rt.config index 1bb4e162..86b3ce95 100644 --- a/configs/phytium_e2000_linux_5.10_rt.config +++ b/configs/phytium_e2000_linux_5.10_rt.config @@ -1,2 +1,2 @@ # kernel 5.10-rt -BR2_LINUX_KERNEL_CUSTOM_REPO_VERSION="kernel_5.10-rt_2023-v1.0-RC1" +BR2_LINUX_KERNEL_CUSTOM_REPO_VERSION="kernel_5.10-rt_2023-v1.0-GA" diff --git a/configs/phytium_e2000_optee.config b/configs/phytium_e2000_optee.config index f361d418..0acbf8e9 100644 --- a/configs/phytium_e2000_optee.config +++ b/configs/phytium_e2000_optee.config @@ -4,5 +4,5 @@ BR2_LINUX_KERNEL_CONFIG_FRAGMENT_FILES="$(LINUX_DIR)/arch/arm64/configs/phytium_ BR2_PACKAGE_PHYTIUM_OPTEE=y BR2_PACKAGE_PHYTIUM_OPTEE_CUSTOM_REPO_URL="https://gitee.com/phytium_embedded/phytium-optee.git" -BR2_PACKAGE_PHYTIUM_OPTEE_CUSTOM_REPO_VERSION="beb883a34c9c7b1aaa96bbacd611be218809705c" +BR2_PACKAGE_PHYTIUM_OPTEE_CUSTOM_REPO_VERSION="v2.2" BR2_PACKAGE_PHYTIUM_OPTEE_BOARD="e2000ddemo" diff --git a/configs/phytium_e2000_ubuntu_defconfig b/configs/phytium_e2000_ubuntu_defconfig index cda38333..cdf9ed65 100644 --- a/configs/phytium_e2000_ubuntu_defconfig +++ b/configs/phytium_e2000_ubuntu_defconfig @@ -5,8 +5,9 @@ BR2_cortex_a53=y # Filesystem BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y -#BR2_ROOTFS_POST_IMAGE_SCRIPT="board/phytium/post-image.sh support/scripts/genimage.sh" -#BR2_ROOTFS_POST_SCRIPT_ARGS="-c board/phytium/genimage-e2000.cfg" +BR2_TARGET_ROOTFS_EXT2_SIZE="5G" +BR2_ROOTFS_POST_IMAGE_SCRIPT="board/phytium/post-image.sh support/scripts/genimage.sh" +BR2_ROOTFS_POST_SCRIPT_ARGS="-c board/phytium/genimage-e2000.cfg" # custom skeleton BR2_ROOTFS_SKELETON_UBUNTU=y @@ -38,7 +39,7 @@ BR2_LINUX_KERNEL=y BR2_LINUX_KERNEL_CUSTOM_GIT=y BR2_LINUX_KERNEL_CUSTOM_REPO_URL="https://gitee.com/phytium_embedded/phytium-linux-kernel.git" # kernel 5.10 -BR2_LINUX_KERNEL_CUSTOM_REPO_VERSION="kernel_5.10_2023-v1.0-RC1" +BR2_LINUX_KERNEL_CUSTOM_REPO_VERSION="kernel_5.10_2023-v1.0-GA" BR2_LINUX_KERNEL_INTREE_DTS_NAME="phytium/e2000d-demo-board phytium/e2000d-miniitx-board phytium/e2000d-power-board phytium/e2000q-come-board phytium/e2000q-demo-board phytium/e2000q-edu-board phytium/e2000q-hanwei-board phytium/e2000q-miniitx-board phytium/e2000q-vpx-board phytium/e2000s-demo-board" BR2_LINUX_KERNEL_DTS_SUPPORT=y BR2_LINUX_KERNEL_DEFCONFIG="phytium" diff --git a/configs/phytium_e2000_ubuntu_desktop_defconfig b/configs/phytium_e2000_ubuntu_desktop_defconfig index 2c9aa9d8..f2e7f4d7 100644 --- a/configs/phytium_e2000_ubuntu_desktop_defconfig +++ b/configs/phytium_e2000_ubuntu_desktop_defconfig @@ -5,6 +5,10 @@ BR2_cortex_a53=y # Filesystem BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y +BR2_TARGET_ROOTFS_EXT2_SIZE="5G" +BR2_ROOTFS_POST_IMAGE_SCRIPT="board/phytium/post-image.sh support/scripts/genimage.sh" +BR2_ROOTFS_POST_SCRIPT_ARGS="-c board/phytium/genimage-e2000.cfg" + # custom skeleton BR2_ROOTFS_SKELETON_UBUNTU=y @@ -36,7 +40,7 @@ BR2_LINUX_KERNEL=y BR2_LINUX_KERNEL_CUSTOM_GIT=y BR2_LINUX_KERNEL_CUSTOM_REPO_URL="https://gitee.com/phytium_embedded/phytium-linux-kernel.git" # kernel 5.10 -BR2_LINUX_KERNEL_CUSTOM_REPO_VERSION="kernel_5.10_2023-v1.0-RC1" +BR2_LINUX_KERNEL_CUSTOM_REPO_VERSION="kernel_5.10_2023-v1.0-GA" BR2_LINUX_KERNEL_INTREE_DTS_NAME="phytium/e2000d-demo-board phytium/e2000d-miniitx-board phytium/e2000d-power-board phytium/e2000q-come-board phytium/e2000q-demo-board phytium/e2000q-edu-board phytium/e2000q-hanwei-board phytium/e2000q-miniitx-board phytium/e2000q-vpx-board phytium/e2000s-demo-board" BR2_LINUX_KERNEL_DTS_SUPPORT=y BR2_LINUX_KERNEL_DEFCONFIG="phytium" diff --git a/configs/phytium_e2000_xenomai_cobalt_4.19.config b/configs/phytium_e2000_xenomai_cobalt_4.19.config new file mode 100644 index 00000000..9fe5d76b --- /dev/null +++ b/configs/phytium_e2000_xenomai_cobalt_4.19.config @@ -0,0 +1,14 @@ +# cobalt kernel 4.19.209-cip59 +BR2_LINUX_KERNEL_CUSTOM_REPO_URL="https://gitee.com/phytium_embedded/linux-kernel-xenomai.git" +BR2_LINUX_KERNEL_CUSTOM_REPO_VERSION="kernel_4.19.209-cip59_2023-v1.0-GA" +BR2_LINUX_KERNEL_CONFIG_FRAGMENT_FILES="$(LINUX_DIR)/arch/arm64/configs/cobalt.config" +# xenomai libraries and tools +BR2_PACKAGE_XENOMAI=y +BR2_PACKAGE_XENOMAI_CUSTOM_TARBALL=y +BR2_PACKAGE_XENOMAI_CUSTOM_TARBALL_URL="https://source.denx.de/Xenomai/xenomai/-/archive/v3.1.3/xenomai-v3.1.3.tar.gz" +BR2_PACKAGE_XENOMAI_COBALT=y +BR2_PACKAGE_XENOMAI_ENABLE_SMP=y +BR2_PACKAGE_XENOMAI_ADDITIONAL_CONF_OPTS="--enable-pshared" +BR2_PACKAGE_XENOMAI_TESTSUITE=y +BR2_PACKAGE_XENOMAI_RTCAN=y +BR2_PACKAGE_XENOMAI_ANALOGY=y diff --git a/configs/phytium_e2000_xenomai_cobalt_5.10.config b/configs/phytium_e2000_xenomai_cobalt_5.10.config new file mode 100644 index 00000000..515a9afe --- /dev/null +++ b/configs/phytium_e2000_xenomai_cobalt_5.10.config @@ -0,0 +1,14 @@ +# cobalt kernel 5.10.153-dovetail3 +BR2_LINUX_KERNEL_CUSTOM_REPO_URL="https://gitee.com/phytium_embedded/linux-kernel-xenomai.git" +BR2_LINUX_KERNEL_CUSTOM_REPO_VERSION="kernel_5.10.153-dovetail3_2023-v1.0-GA" +BR2_LINUX_KERNEL_CONFIG_FRAGMENT_FILES="$(LINUX_DIR)/arch/arm64/configs/cobalt.config" +# xenomai libraries and tools +BR2_PACKAGE_XENOMAI=y +BR2_PACKAGE_XENOMAI_CUSTOM_TARBALL=y +BR2_PACKAGE_XENOMAI_CUSTOM_TARBALL_URL="https://source.denx.de/Xenomai/xenomai/-/archive/v3.2.2/xenomai-v3.2.2.tar.gz" +BR2_PACKAGE_XENOMAI_COBALT=y +BR2_PACKAGE_XENOMAI_ENABLE_SMP=y +BR2_PACKAGE_XENOMAI_ADDITIONAL_CONF_OPTS="--enable-pshared" +BR2_PACKAGE_XENOMAI_TESTSUITE=y +BR2_PACKAGE_XENOMAI_RTCAN=y +BR2_PACKAGE_XENOMAI_ANALOGY=y diff --git a/configs/phytium_e2000_xenomai_mercury_4.19.config b/configs/phytium_e2000_xenomai_mercury_4.19.config new file mode 100644 index 00000000..04955414 --- /dev/null +++ b/configs/phytium_e2000_xenomai_mercury_4.19.config @@ -0,0 +1,12 @@ +# kernel 4.19-rt +BR2_LINUX_KERNEL_CUSTOM_REPO_VERSION="kernel_4.19-rt_2023-v1.0-GA" +# xenomai libraries and tools +BR2_PACKAGE_XENOMAI=y +BR2_PACKAGE_XENOMAI_CUSTOM_TARBALL=y +BR2_PACKAGE_XENOMAI_CUSTOM_TARBALL_URL="https://source.denx.de/Xenomai/xenomai/-/archive/v3.1.3/xenomai-v3.1.3.tar.gz" +BR2_PACKAGE_XENOMAI_MERCURY=y +BR2_PACKAGE_XENOMAI_ENABLE_SMP=y +BR2_PACKAGE_XENOMAI_ADDITIONAL_CONF_OPTS="--enable-pshared" +BR2_PACKAGE_XENOMAI_TESTSUITE=y +BR2_PACKAGE_XENOMAI_RTCAN=y +BR2_PACKAGE_XENOMAI_ANALOGY=y diff --git a/configs/phytium_e2000_xenomai_mercury_5.10.config b/configs/phytium_e2000_xenomai_mercury_5.10.config new file mode 100644 index 00000000..837d258e --- /dev/null +++ b/configs/phytium_e2000_xenomai_mercury_5.10.config @@ -0,0 +1,12 @@ +# kernel 5.10-rt +BR2_LINUX_KERNEL_CUSTOM_REPO_VERSION="kernel_5.10-rt_2023-v1.0-GA" +# xenomai libraries and tools +BR2_PACKAGE_XENOMAI=y +BR2_PACKAGE_XENOMAI_CUSTOM_TARBALL=y +BR2_PACKAGE_XENOMAI_CUSTOM_TARBALL_URL="https://source.denx.de/Xenomai/xenomai/-/archive/v3.2.2/xenomai-v3.2.2.tar.gz" +BR2_PACKAGE_XENOMAI_MERCURY=y +BR2_PACKAGE_XENOMAI_ENABLE_SMP=y +BR2_PACKAGE_XENOMAI_ADDITIONAL_CONF_OPTS="--enable-pshared" +BR2_PACKAGE_XENOMAI_TESTSUITE=y +BR2_PACKAGE_XENOMAI_RTCAN=y +BR2_PACKAGE_XENOMAI_ANALOGY=y diff --git a/configs/phytium_initrd_defconfig b/configs/phytium_initrd_defconfig index 751f0f13..3e0221ba 100644 --- a/configs/phytium_initrd_defconfig +++ b/configs/phytium_initrd_defconfig @@ -5,137 +5,17 @@ BR2_cortex_a53=y # Filesystem BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y -BR2_TARGET_ROOTFS_EXT2_SIZE="80M" -BR2_TARGET_ROOTFS_INITRAMFS=y -BR2_ROOTFS_RESIZE=y -#BR2_ROOTFS_POST_IMAGE_SCRIPT="board/phytium/post-image.sh support/scripts/genimage.sh" -#BR2_ROOTFS_POST_SCRIPT_ARGS="-c board/phytium/genimage-efi.cfg" +BR2_TARGET_ROOTFS_EXT2_SIZE="30M" BR2_TARGET_ROOTFS_CPIO=y BR2_TARGET_ROOTFS_CPIO_GZIP=y -# Hostname and issue -BR2_TARGET_GENERIC_HOSTNAME="D2000" -BR2_TARGET_GENERIC_ISSUE="Welcome to Phytium Buildroot initrd" - # toolchain BR2_TOOLCHAIN_EXTERNAL=y -BR2_TOOLCHAIN_EXTERNAL_ARM_AARCH64=y -BR2_TOOLCHAIN_USES_GLIBC=y -BR2_TOOLCHAIN_EXTERNAL_GLIBC=y - -# Linux headers same as kernel -BR2_PACKAGE_HOST_LINUX_HEADERS_CUSTOM_4_19=y - -# Kernel -BR2_LINUX_KERNEL=y -BR2_LINUX_KERNEL_CUSTOM_TARBALL=y -BR2_LINUX_KERNEL_USE_ARCH_DEFAULT_CONFIG=y -BR2_LINUX_KERNEL_CUSTOM_TARBALL_LOCATION="file://$(TOPDIR)/files/linux-4.19.tar.gz" -BR2_LINUX_KERNEL_CONFIG_FRAGMENT_FILES="$(LINUX_DIR)/arch/arm64/configs/sdk.config" -#BR2_LINUX_KERNEL_DTS_SUPPORT=y -#BR2_LINUX_KERNEL_INTREE_DTS_NAME="phytium/d2000-devboard-dsk" -BR2_LINUX_KERNEL_IMAGE_TARGET_CUSTOM=y -BR2_LINUX_KERNEL_IMAGE_TARGET_NAME="Image" -BR2_LINUX_KERNEL_NEEDS_HOST_OPENSSL=y - -# Bootloader -#BR2_TARGET_GRUB2=y -#BR2_TARGET_GRUB2_ARM64_EFI=y - - -# Serial port config -BR2_TARGET_GENERIC_GETTY=y -BR2_TARGET_GENERIC_GETTY_PORT="ttyAMA0" - -# required tools to create the microSD image -#BR2_PACKAGE_HOST_DOSFSTOOLS=y -#BR2_PACKAGE_HOST_GENIMAGE=y -#BR2_PACKAGE_HOST_MTOOLS=y - -# busybox setting -#BR2_INIT_BUSYBOX=y #eudev support BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_EUDEV=y BR2_ROOTFS_OVERLAY="board/phytium/common/busybox_initrd_overlay" -# basic packages and tools -#BR2_PACKAGE_MTD=y -#BR2_PACKAGE_MTD_MTD_DEBUG=y -#BR2_PACKAGE_SYSSTAT=y -#BR2_PACKAGE_E2FSPROGS=y -#BR2_PACKAGE_RT_TESTS=y -#BR2_PACKAGE_OPENSSH=y -#BR2_PACKAGE_OPENSSL=y -#BR2_PACKAGE_WGET=y - -# ca-certs packages -#BR2_PACKAGE_CA_CERTIFICATES=y - -# dhcpd package -#BR2_PACKAGE_DHCPCD=y - -# resize2fs package -#BR2_PACKAGE_E2FSPROGS_RESIZE2FS=y - -# Text editors -#BR2_PACKAGE_NANO=y - -# IGH ETHERCAT -#BR2_PACKAGE_IGH_ETHERCAT=y - -#iproute2 -#BR2_PACKAGE_IPROUTE2=y - -#netperf -#BR2_PACKAGE_NETPERF=y - -#BR2_PACKAGE_ETHTOOL=y -#BR2_PACKAGE_COLLECTD_CURL=y -#BR2_PACKAGE_COLLECTD_CURL_JSON=y -#BR2_PACKAGE_COLLECTD_CURL_XML=y -#BR2_PACKAGE_LIBCURL=y -#BR2_PACKAGE_LIBCURL_CURL=y -#BR2_PACKAGE_LIBCURL_VERBOSE=y -#BR2_PACKAGE_FLICKCURL=y -#BR2_PACKAGE_FLICKCURL_UTILS=y -BR2_PACKAGE_BASH=y -BR2_SYSTEM_BIN_SH_BASH=y -BR2_SYSTEM_BIN_SH="bash" - -# haveged -#BR2_PACKAGE_HAVEGED=y - -#avahi -#BR2_PACKAGE_AVAHI=y -#BR2_PACKAGE_AVAHI_AUTOIPD=y -#BR2_PACKAGE_AVAHI_DAEMON=y -#BR2_PACKAGE_AVAHI_LIBDNSSD_COMPATIBILITY=y -#BR2_PACKAGE_NSS_MDNS=y - -# i2c-tools -#BR2_PACKAGE_I2C_TOOLS=y - -BR2_USE_MMU=y -BR2_USE_WCHAR=y -#BR2_PACKAGE_VIM=y - -#BR2_INSTALL_LIBSTDCPP=y -#BR2_PACKAGE_IPERF=y - -BR2_TOOLCHAIN_HAS_THREADS=y -#BR2_PACKAGE_IPERF3=y -#BR2_PACKAGE_TCPDUMP=y - -# OPC UA tools -#BR2_PACKAGE_LIBOPEN62541=y -#BR2_PACKAGE_LIBOPEN62541_BUILD_EXAMPLES=y - # xorg-rogue-umlibs firmware BR2_PACKAGE_XORG_ROGUE_UMLIBS=y BR2_PACKAGE_XORG_ROGUE_UMLIBS_FIRMWARE=y - -# vpu-lib firmware -BR2_PACKAGE_VPU_LIB=y -BR2_PACKAGE_VPU_LIB_CPU_MODEL="d2000" -BR2_PACKAGE_VPU_LIB_FIRMWARE=y diff --git a/fs/ext2/ext2.mk b/fs/ext2/ext2.mk index 75dc4b04..1bfc9b58 100644 --- a/fs/ext2/ext2.mk +++ b/fs/ext2/ext2.mk @@ -28,40 +28,13 @@ ROOTFS_EXT2_DEPENDENCIES = host-e2fsprogs define ROOTFS_EXT2_CMD rm -f $@ - if [ "x$(BR2_ROOTFS_EXT2_SIZE)" != "x" ] - then - $(HOST_DIR)/sbin/mkfs.ext$(BR2_TARGET_ROOTFS_EXT2_GEN) $(ROOTFS_EXT2_OPTS) $@ \ + $(HOST_DIR)/sbin/mkfs.ext$(BR2_TARGET_ROOTFS_EXT2_GEN) $(ROOTFS_EXT2_OPTS) $@ \ "$(ROOTFS_EXT2_SIZE)" \ - || { ret=$$?; \ - echo "*** Maybe you need to increase the filesystem size (BR2_TARGET_ROOTFS_EXT2_SIZE)" 1>&2; \ - exit $$ret; \ - } - else - EXT2_SIZE_E=`du -s $(TARGET_DIR) | cut -f 1` - while true - do - EXT2_SIZE_E=$$(($${EXT2_SIZE_E} + 100 * 1024)) - echo "The size of rootfs.ext2 will set to $${EXT2_SIZE_E}" - $(HOST_DIR)/sbin/mkfs.ext$(BR2_TARGET_ROOTFS_EXT2_GEN) $(ROOTFS_EXT2_OPTS) $@ "$${EXT2_SIZE_E}K" \ - && break - done + || { ret=$$?; \ + echo "*** Maybe you need to increase the filesystem size (BR2_TARGET_ROOTFS_EXT2_SIZE)" 1>&2; \ + exit $$ret; \ + } - FREE_BLOCK=`dumpe2fs $@ 2>/dev/null | grep -i "^Free blocks" | awk -F ':' '{print $$2}'` - BLOCK_COUNT=`dumpe2fs $@ 2>/dev/null | grep -i "^Block count" | awk -F ':' '{print $$2}'` - BLOCK_SIZE=`dumpe2fs $@ 2>/dev/null | grep -i "^Block size" | awk -F ':' '{print $$2}'` - - FREE_BLOCK=$$(($${FREE_BLOCK}*$${BLOCK_SIZE}/1024)) - BLOCK_COUNT=$$(($${BLOCK_COUNT}*$${BLOCK_SIZE}/1024)) - USED_BLOCK=$$(($${BLOCK_COUNT}-$${FREE_BLOCK})) - - EXT2_SIZE_E=$$(($${USED_BLOCK}*100/90)) - - if [ $$(($${EXT2_SIZE_E} - $${USED_BLOCK})) -le 51200 ] - then - EXT2_SIZE_E=$$(($${USED_BLOCK} + 51200)) - fi - - fi endef ifneq ($(BR2_TARGET_ROOTFS_EXT2_GEN),2) diff --git a/linux/kernel-patches/jailhouse/0001-modify-the-dts-of-d2000-and-ft2004-linux-kernel-to-r.patch b/linux/kernel-patches/jailhouse/0001-modify-the-dts-of-d2000-and-ft2004-linux-kernel-to-r.patch new file mode 100644 index 00000000..86955881 --- /dev/null +++ b/linux/kernel-patches/jailhouse/0001-modify-the-dts-of-d2000-and-ft2004-linux-kernel-to-r.patch @@ -0,0 +1,57 @@ +From 1a1a209d5c3722f54dd8daf5d971c74ecd9250ac Mon Sep 17 00:00:00 2001 +From: weishanshan1084 +Date: Mon, 17 Jul 2023 15:37:55 +0800 +Subject: [PATCH] modify the dts of d2000 and ft2004 linux kernel to reserve + memory for jailhouse. + +Signed-off-by: weishanshan1084 +--- + .../arm64/boot/dts/phytium/d2000-generic-psci-soc.dtsi | 10 ++++++++++ + .../boot/dts/phytium/ft2004-generic-psci-soc.dtsi | 10 ++++++++++ + 2 files changed, 20 insertions(+) + +diff --git a/arch/arm64/boot/dts/phytium/d2000-generic-psci-soc.dtsi b/arch/arm64/boot/dts/phytium/d2000-generic-psci-soc.dtsi +index 69d42a220..10adea18c 100644 +--- a/arch/arm64/boot/dts/phytium/d2000-generic-psci-soc.dtsi ++++ b/arch/arm64/boot/dts/phytium/d2000-generic-psci-soc.dtsi +@@ -13,6 +13,16 @@ + #address-cells = <2>; + #size-cells = <2>; + ++ reserved-memory { ++ #address-cells = <0x00000002>; ++ #size-cells = <0x00000002>; ++ ranges; ++ reserved@b0000000 { ++ reg = <0x00000000 0xb0000000 0x00000000 0x10000000>; ++ no-map; ++ }; ++ }; ++ + aliases { + ethernet0 = &gmac0; + ethernet1 = &gmac1; +diff --git a/arch/arm64/boot/dts/phytium/ft2004-generic-psci-soc.dtsi b/arch/arm64/boot/dts/phytium/ft2004-generic-psci-soc.dtsi +index 3f2eb7406..d6c317694 100644 +--- a/arch/arm64/boot/dts/phytium/ft2004-generic-psci-soc.dtsi ++++ b/arch/arm64/boot/dts/phytium/ft2004-generic-psci-soc.dtsi +@@ -13,6 +13,16 @@ + #address-cells = <2>; + #size-cells = <2>; + ++ reserved-memory { ++ #address-cells = <0x00000002>; ++ #size-cells = <0x00000002>; ++ ranges; ++ reserved@b0000000 { ++ reg = <0x00000000 0xb0000000 0x00000000 0x10000000>; ++ no-map; ++ }; ++ }; ++ + aliases { + ethernet0 = &gmac0; + ethernet1 = &gmac1; +-- +2.25.1 + diff --git a/linux/kernel-patches/jailhouse/0001-modify-the-dts-of-e2000-linux-4.19-kernel-to-reserve.patch b/linux/kernel-patches/jailhouse/0001-modify-the-dts-of-e2000-linux-4.19-kernel-to-reserve.patch new file mode 100644 index 00000000..d57784b5 --- /dev/null +++ b/linux/kernel-patches/jailhouse/0001-modify-the-dts-of-e2000-linux-4.19-kernel-to-reserve.patch @@ -0,0 +1,42 @@ +From 1cfc4bafbb86449d20565bac2ccd5ec401a15d55 Mon Sep 17 00:00:00 2001 +From: weishanshan1084 +Date: Thu, 13 Jul 2023 07:15:58 +0000 +Subject: [PATCH] modify the dts of e2000 linux-4.19 kernel to reserve memory + for jailhouse. + +Signed-off-by: weishanshan1084 +--- + arch/arm64/boot/dts/phytium/pe2204.dtsi | 11 ++++++++--- + 1 file changed, 8 insertions(+), 3 deletions(-) + +diff --git a/arch/arm64/boot/dts/phytium/pe2204.dtsi b/arch/arm64/boot/dts/phytium/pe2204.dtsi +index 950a35b64..574c9653d 100644 +--- a/arch/arm64/boot/dts/phytium/pe2204.dtsi ++++ b/arch/arm64/boot/dts/phytium/pe2204.dtsi +@@ -15,15 +15,20 @@ + #size-cells = <0x2>; + ranges; + +- reserved0: reserved@0 { ++ rproc: rproc@0x2110100000 { + no-map; +- reg = <0x0 0xb0100000 0x0 0x19900000>; ++ reg = <0x21 0x10100000 0x0 0x19900000>; + }; ++ ++ jailhouse@b0000000 { ++ reg = <0x00000000 0xb0000000 0x00000000 0x10000000>; ++ no-map; ++ }; + }; + + remoteproc: remoteproc@0 { + compatible = "phytium,rproc"; +- memory-region = <&reserved0>; ++ memory-region = <&rproc>; + status = "disabled"; + }; + +-- +2.25.1 + diff --git a/linux/kernel-patches/jailhouse/0001-modify-the-dts-of-e2000-linux-5.10-kernel-to-reserve.patch b/linux/kernel-patches/jailhouse/0001-modify-the-dts-of-e2000-linux-5.10-kernel-to-reserve.patch new file mode 100644 index 00000000..29019cf2 --- /dev/null +++ b/linux/kernel-patches/jailhouse/0001-modify-the-dts-of-e2000-linux-5.10-kernel-to-reserve.patch @@ -0,0 +1,35 @@ +From ec7f731688b27c812d7c9d210f705ff10c55ab0d Mon Sep 17 00:00:00 2001 +From: weishanshan1084 +Date: Wed, 19 Jul 2023 14:43:34 +0800 +Subject: [PATCH] modify the dts of e2000 linux-5.10 kernel to reserve memory + for jailhouse. + +Signed-off-by: weishanshan1084 +--- + arch/arm64/boot/dts/phytium/pe2204.dtsi | 10 ++++++++++ + 1 file changed, 10 insertions(+) + +diff --git a/arch/arm64/boot/dts/phytium/pe2204.dtsi b/arch/arm64/boot/dts/phytium/pe2204.dtsi +index 2cd699de4..9344ad756 100644 +--- a/arch/arm64/boot/dts/phytium/pe2204.dtsi ++++ b/arch/arm64/boot/dts/phytium/pe2204.dtsi +@@ -10,6 +10,16 @@ + / { + compatible = "phytium,pe2204"; + ++ reserved-memory { ++ #address-cells = <0x00000002>; ++ #size-cells = <0x00000002>; ++ ranges; ++ reserved@b0000000 { ++ reg = <0x00000000 0xb0000000 0x00000000 0x10000000>; ++ no-map; ++ }; ++ }; ++ + aliases { + ethernet0 = &macb0; + ethernet1 = &macb1; +-- +2.25.1 + diff --git a/package/igh-ethercat/igh-ethercat.mk b/package/igh-ethercat/igh-ethercat.mk index 127ac7fc..eaa2edf7 100644 --- a/package/igh-ethercat/igh-ethercat.mk +++ b/package/igh-ethercat/igh-ethercat.mk @@ -4,17 +4,17 @@ # ################################################################################ -IGH_ETHERCAT_VERSION = bec5f529701a07d0da2730c94e75a777e07eefe0 +IGH_ETHERCAT_VERSION = stable-1.5-rt_2023-v1.0-GA IGH_ETHERCAT_SITE = https://gitee.com/phytium_embedded/ether-cat.git -IGH_ETHERCAT_INSTALL_IMAGES = YES IGH_ETHERCAT_SITE_METHOD = git IGH_ETHERCAT_AUTORECONF = YES - IGH_ETHERCAT_INSTALL_STAGING = YES IGH_ETHERCAT_CONF_OPTS = \ - --with-linux-dir=$(LINUX_DIR) + --with-linux-dir=$(LINUX_DIR) \ + --enable-generic \ + --enable-cadence IGH_ETHERCAT_CONF_OPTS += $(if $(BR2_PACKAGE_IGH_ETHERCAT_8139TOO),--enable-8139too,--disable-8139too) IGH_ETHERCAT_CONF_OPTS += $(if $(BR2_PACKAGE_IGH_ETHERCAT_E100),--enable-e100,--disable-e100) @@ -24,9 +24,19 @@ IGH_ETHERCAT_CONF_OPTS += $(if $(BR2_PACKAGE_IGH_ETHERCAT_R8169),--enable-r8169, define IGH_ETHERCAT_CREATE_CHANGELOG touch $(@D)/ChangeLog + mkdir -p $(@D)/m4 endef - IGH_ETHERCAT_POST_PATCH_HOOKS += IGH_ETHERCAT_CREATE_CHANGELOG +IGH_ETHERCAT_MODULE_MAKE_OPTS = INSTALL_MOD_DIR="ethercat" + $(eval $(kernel-module)) + +define IGH_ETHERCAT_DO_NOT_LOAD_ON_BOOT + mkdir -p $(TARGET_DIR)/etc/modprobe.d + echo "# Do not load the 'ec_macb' module on boot." >> $(TARGET_DIR)/etc/modprobe.d/blacklist.conf + echo "blacklist ec_macb" >> $(TARGET_DIR)/etc/modprobe.d/blacklist.conf +endef +IGH_ETHERCAT_POST_INSTALL_TARGET_HOOKS += IGH_ETHERCAT_DO_NOT_LOAD_ON_BOOT + $(eval $(autotools-package)) diff --git a/package/jailhouse/jailhouse.hash b/package/jailhouse/jailhouse.hash deleted file mode 100644 index 13a260e8..00000000 --- a/package/jailhouse/jailhouse.hash +++ /dev/null @@ -1,3 +0,0 @@ -# Locally computed: -sha256 3777a553c2acb2b693843fe4d16ab80333879daedd47d9c9f3717c9644e6cf93 jailhouse-0.12.tar.gz -sha256 3aafb31a2436178323663e00511f16d58fc36ea654b1457532e79d017205efd8 COPYING diff --git a/package/jailhouse/jailhouse.mk b/package/jailhouse/jailhouse.mk index 6356c5a7..b6dc54b4 100644 --- a/package/jailhouse/jailhouse.mk +++ b/package/jailhouse/jailhouse.mk @@ -4,8 +4,9 @@ # ################################################################################ -JAILHOUSE_VERSION = 0.12 -JAILHOUSE_SITE = $(call github,siemens,jailhouse,v$(JAILHOUSE_VERSION)) +JAILHOUSE_VERSION = phytium-jailhouse-2023-v1.0-GA +JAILHOUSE_SITE = https://gitee.com/phytium_embedded/phytium-jailhouse.git +JAILHOUSE_SITE_METHOD = git JAILHOUSE_LICENSE = GPL-2.0 JAILHOUSE_LICENSE_FILES = COPYING JAILHOUSE_DEPENDENCIES = \ @@ -15,10 +16,12 @@ JAILHOUSE_MAKE_OPTS = \ CROSS_COMPILE="$(TARGET_CROSS)" \ ARCH="$(KERNEL_ARCH)" \ KDIR="$(LINUX_DIR)" \ - DESTDIR="$(TARGET_DIR)" + DESTDIR="$(TARGET_DIR)" \ + INSTALL_MOD_DIR="jailhouse" ifeq ($(BR2_PACKAGE_JAILHOUSE_HELPER_SCRIPTS),y) JAILHOUSE_DEPENDENCIES += \ + python3 \ host-python-mako \ host-python-setuptools JAILHOUSE_MAKE_OPTS += \ @@ -31,24 +34,24 @@ JAILHOUSE_MAKE_OPTS += \ endif define JAILHOUSE_BUILD_CMDS - $(TARGET_MAKE_ENV) $(MAKE) $(JAILHOUSE_MAKE_OPTS) -C $(@D) + $(TARGET_MAKE_ENV) $(MAKE) $(JAILHOUSE_MAKE_OPTS) -C $(@D)/src/jailhouse $(if $(BR2_PACKAGE_JAILHOUSE_HELPER_SCRIPTS), \ - cd $(@D) && $(PKG_PYTHON_SETUPTOOLS_ENV) $(HOST_DIR)/bin/python setup.py build) + cd $(@D)/src/jailhouse && $(PKG_PYTHON_SETUPTOOLS_ENV) $(HOST_DIR)/bin/python setup.py build) endef define JAILHOUSE_INSTALL_TARGET_CMDS - $(TARGET_MAKE_ENV) $(MAKE) $(JAILHOUSE_MAKE_OPTS) -C $(@D) modules_install firmware_install tool_inmates_install - $(TARGET_MAKE_ENV) $(MAKE) $(JAILHOUSE_MAKE_OPTS) -C $(@D)/tools src=$(@D)/tools install + $(TARGET_MAKE_ENV) $(MAKE) $(JAILHOUSE_MAKE_OPTS) -C $(@D)/src/jailhouse modules_install firmware_install tool_inmates_install + $(TARGET_MAKE_ENV) $(MAKE) $(JAILHOUSE_MAKE_OPTS) -C $(@D)/src/jailhouse/tools src=$(@D)/src/jailhouse/tools install $(INSTALL) -d -m 0755 $(TARGET_DIR)/etc/jailhouse - $(INSTALL) -D -m 0644 $(@D)/configs/*/*.cell $(TARGET_DIR)/etc/jailhouse + $(INSTALL) -D -m 0644 $(@D)/src/jailhouse/configs/*/*.cell $(TARGET_DIR)/etc/jailhouse $(INSTALL) -d -m 0755 $(TARGET_DIR)/usr/local/libexec/jailhouse/demos - $(INSTALL) -D -m 0755 $(@D)/inmates/demos/*/*.bin $(TARGET_DIR)/usr/local/libexec/jailhouse/demos + $(INSTALL) -D -m 0755 $(@D)/src/jailhouse/inmates/demos/*/*.bin $(TARGET_DIR)/usr/local/libexec/jailhouse/demos $(if $(BR2_PACKAGE_JAILHOUSE_HELPER_SCRIPTS), \ - cd $(@D) && $(PKG_PYTHON_SETUPTOOLS_ENV) $(HOST_DIR)/bin/python setup.py install --no-compile $(PKG_PYTHON_SETUPTOOLS_INSTALL_TARGET_OPTS)) + cd $(@D)/src/jailhouse && $(PKG_PYTHON_SETUPTOOLS_ENV) $(HOST_DIR)/bin/python setup.py install --no-compile $(PKG_PYTHON_SETUPTOOLS_INSTALL_TARGET_OPTS)) endef $(eval $(generic-package)) diff --git a/package/qt5/qt5base/qt5base.mk b/package/qt5/qt5base/qt5base.mk index ef38d032..177db941 100644 --- a/package/qt5/qt5base/qt5base.mk +++ b/package/qt5/qt5base/qt5base.mk @@ -320,6 +320,7 @@ define QT5BASE_CONFIGURE_CMDS (cd $(@D); \ $(TARGET_MAKE_ENV) \ PKG_CONFIG="$(PKG_CONFIG_HOST_BINARY)" \ + PKG_CONFIG_LIBDIR="$(STAGING_DIR)/usr/lib/pkgconfig:$(STAGING_DIR)/usr/local/lib/pkgconfig:$(STAGING_DIR)/usr/local/share/pkgconfig" \ MAKEFLAGS="-j$(PARALLEL_JOBS) $(MAKEFLAGS)" \ ./configure \ -v \ diff --git a/package/vpu-lib/Config.in b/package/vpu-lib/Config.in index f29aa607..3404ca53 100644 --- a/package/vpu-lib/Config.in +++ b/package/vpu-lib/Config.in @@ -13,6 +13,15 @@ config BR2_PACKAGE_VPU_LIB_CPU_MODEL help This is a comment that defines the cpu model, and the supported value is "d2000". +config BR2_PACKAGE_VPU_LIB_CUSTOM_TARBALL + bool "Custom tarball" + help + This option allows to specify a URL pointing to a vpu-lib tarball. + +config BR2_PACKAGE_VPU_LIB_CUSTOM_TARBALL_LOCATION + string "URL of custom vpu-lib tarball" + depends on BR2_PACKAGE_VPU_LIB_CUSTOM_TARBALL + config BR2_PACKAGE_VPU_LIB_FIRMWARE bool "vpu-lib firmware" help diff --git a/package/vpu-lib/vpu-lib.mk b/package/vpu-lib/vpu-lib.mk index e3260e57..5a4a3eed 100644 --- a/package/vpu-lib/vpu-lib.mk +++ b/package/vpu-lib/vpu-lib.mk @@ -4,10 +4,16 @@ # ################################################################################ +ifeq ($(BR2_PACKAGE_VPU_LIB_CUSTOM_TARBALL),y) +VPU_LIB_TARBALL = $(call qstrip,$(BR2_PACKAGE_VPU_LIB_CUSTOM_TARBALL_LOCATION)) +VPU_LIB_SITE = $(patsubst %/,%,$(dir $(VPU_LIB_TARBALL))) +VPU_LIB_SOURCE = $(notdir $(VPU_LIB_TARBALL)) +else VPU_LIB_VERSION = 28655c1d76a99db4460a3bc85e766555d568ecee VPU_LIB_SITE = https://gitee.com/phytium_embedded/vpu-lib.git -VPU_LIB_INSTALL_TARGET = YES VPU_LIB_SITE_METHOD = git +endif + VPU_LIB_DEPENDENCIES = linux ifeq ($(BR2_PACKAGE_VPU_LIB_FIRMWARE),y) diff --git a/package/xenomai/Config.in b/package/xenomai/Config.in index ec6d9e5d..f7c318e4 100644 --- a/package/xenomai/Config.in +++ b/package/xenomai/Config.in @@ -4,6 +4,7 @@ config BR2_PACKAGE_XENOMAI_COBALT_ARCH_SUPPORTS default y if BR2_x86_64 default y if BR2_powerpc default y if BR2_arm && !BR2_ARM_CPU_ARMV7M && !BR2_ARM_CPU_ARMV8A + default y if BR2_aarch64 comment "xenomai needs a glibc or uClibc toolchain w/ threads" depends on BR2_USE_MMU diff --git a/package/xenomai/xenomai.mk b/package/xenomai/xenomai.mk index c1ad0c5d..e1d6f560 100644 --- a/package/xenomai/xenomai.mk +++ b/package/xenomai/xenomai.mk @@ -40,8 +40,6 @@ XENOMAI_INSTALL_TARGET_OPTS = DESTDIR=$(TARGET_DIR) install-user XENOMAI_INSTALL_STAGING_OPTS = DESTDIR=$(STAGING_DIR) install-user XENOMAI_CONF_OPTS += \ - --disable-demo \ - --disable-testsuite \ --includedir=/usr/include/xenomai/ ifeq ($(BR2_PACKAGE_XENOMAI_MERCURY),y) diff --git a/package/xorg-rogue-umlibs/Config.in b/package/xorg-rogue-umlibs/Config.in index b7108652..da30f7e3 100644 --- a/package/xorg-rogue-umlibs/Config.in +++ b/package/xorg-rogue-umlibs/Config.in @@ -1,5 +1,8 @@ config BR2_PACKAGE_XORG_ROGUE_UMLIBS bool "xorg-rogue-umlibs" + select BR2_PACKAGE_HAS_LIBEGL + select BR2_PACKAGE_HAS_LIBGLES + select BR2_PACKAGE_HAS_LIBGBM help This is a comment that explains what xorg-rogue-umlibs is. The help text should be wrapped. @@ -13,4 +16,13 @@ config BR2_PACKAGE_XORG_ROGUE_UMLIBS_FIRMWARE help Install only xorg-rogue-umlibs firmware and do not install other files. +config BR2_PACKAGE_PROVIDES_LIBEGL + default "xorg-rogue-umlibs" + +config BR2_PACKAGE_PROVIDES_LIBGLES + default "xorg-rogue-umlibs" + +config BR2_PACKAGE_PROVIDES_LIBGBM + default "xorg-rogue-umlibs" + endif diff --git a/package/xorg-rogue-umlibs/xorg-rogue-umlibs.mk b/package/xorg-rogue-umlibs/xorg-rogue-umlibs.mk index 7b6e39a9..cc2761c4 100644 --- a/package/xorg-rogue-umlibs/xorg-rogue-umlibs.mk +++ b/package/xorg-rogue-umlibs/xorg-rogue-umlibs.mk @@ -4,10 +4,12 @@ # ################################################################################ -XORG_ROGUE_UMLIBS_VERSION = 1932ace1db48c4301fcc1dd21e7b08c8e09be1c4 +XORG_ROGUE_UMLIBS_VERSION = 6cd4ee6f949bb2622a19f46ae3faccca4f9a0b89 XORG_ROGUE_UMLIBS_CUSTOM_REPO_URL = https://gitee.com/phytium_embedded/phytium-rogue-umlibs.git XORG_ROGUE_UMLIBS_SITE = $(call qstrip,$(XORG_ROGUE_UMLIBS_CUSTOM_REPO_URL)) XORG_ROGUE_UMLIBS_SITE_METHOD = git +XORG_ROGUE_UMLIBS_INSTALL_STAGING = YES +XORG_ROGUE_UMLIBS_PROVIDES = libegl libgles libgbm define XORG_ROGUE_UMLIBS_BUILD_CMDS $(TARGET_MAKE_ENV) $(MAKE) -C $(@D) all @@ -23,4 +25,8 @@ define XORG_ROGUE_UMLIBS_INSTALL_TARGET_CMDS endef endif +define XORG_ROGUE_UMLIBS_INSTALL_STAGING_CMDS + $(TARGET_MAKE_ENV) $(MAKE) -C $(@D) install DESTDIR=$(STAGING_DIR) WINDOW_SYSTEM=xorg +endef + $(eval $(generic-package))