- Linux内核(arm64 4.19.0)配置
–>File systems
<*> FUSE (Filesystem in Userspace) support
- 添加exfat支持
因为是用petalinux构建的linux环境,这里也用它添加exfat支持。(也可直接将驱动加到linux源码fs文件夹下,再修改对应目录的Makefile和Kconfig文件即可)
- 下载exfat驱动源码
- 添加exfat驱动到petalinux工程
petalinux-create -t modules --name exfat --enable
- 将驱动源码拷贝到添加的驱动文件夹
- 修改exfat.bb文件如下:
SUMMARY = "Recipe for build an external exfat Linux kernel module"
SECTION = "PETALINUX/modules"
LICENSE = "GPLv2"
LIC_FILES_CHKSUM = "file://COPYING;md5=12f884d2ae1ff87c09e5b7ccc2c4ca7e"
inherit module
SRC_URI = "file://Makefile \
file://dkms.conf \
file://exfat_api.c \
file://exfat_api.h \
file://exfat_bitmap.c \
file://exfat_bitmap.h \
file://exfat_blkdev.c \
file://exfat_blkdev.h \
file://exfat_cache.c \
file://exfat_cache.h \
file://exfat_config.h \
file://exfat_core.c \
file://exfat_core.h \
file://exfat_data.c \
file://exfat_data.h \
file://exfat-km.mk \
file://exfat_oal.c \
file://exfat_oal.h \
file://exfat_super.c \
file://exfat_super.h \
file://exfat_upcase.c \
file://exfat_version.h \
file://exfat_nls.c \
file://exfat_nls.h \
file://Kconfig \
file://LICENSE \
file://COPYING\
"
S = "${WORKDIR}"
# The inherit of module.bbclass will automatically name module packages with
# "kernel-module-" prefix as required by the oe-core build environment.
- petalinux-build
- ntfs
因为linux内核源码中对ntfs的挂载是只读的,所以需要下载ntfs-3g工具进行交叉编译,再移植到板子
- 下载ntfs-3g源码
- 解压后,进入源码文件夹,进行交叉编译
./configure --build=“编译主机,如i386“ --host=“交叉编译工具链” --prefix=“编译生成文件路径” --exec