在我的嵌入式系统中,我使CONFIG_CONFIGFS_FS=y能够访问configFS。在引导时,我在mount -t configfs none /sys/kernel/config的帮助下安装了它。这就像魅力一样:
# mount | grep configfs
configfs on /sys/kernel/config type configfs (rw,relatime)现在我尝试创建一个文件夹device-tree,因为我想尝试从用户空间动态加载dtbo文件。不幸的是,我遇到了一个错误:
# mkdir -p /sys/kernel/config/device-tree/overlays/dummy
mkdir: can't create directory '/sys/kernel/config/device-tree/': Operation not permitted我已经确保设置了CONFIG_OF_DYNAMIC和CONFIG_OF_OVERLAY。
/sys/kernel/config的权限如下:
# ls -la /sys/kernel/config/
total 0
drwxr-xr-x 2 root root 0 May 31 16:57 .
drwxr-xr-x 8 root root 0 May 31 15:56 ..因此,我已经猜到了,以root的形式写入这个目录根本就不是问题。
有什么线索吗,我怎么能调查这个问题?
发布于 2023-06-02 05:32:05
我的问题是,我使用了不支持CONFIG_OF_CONFIGFS的主线内核6.1 (LTS)。因此,我从这里下载了一个dtbo-configfs devicedriver:https://github.com/ikwzm/dtbocfg,编译它并将其加载到内核中。然后,在挂载configfs之后,device-tree目录已经可用。
https://unix.stackexchange.com/questions/747665
复制相似问题