base-files: mount bpffs at boot
[openwrt/openwrt.git] / package / base-files / files / etc / init.d / boot
index 21aecde615db7874d5faa76f17bdf0c771c2044e..958a67599e82b536a4e402e71e1563991392136f 100755 (executable)
@@ -35,6 +35,7 @@ boot() {
        touch /tmp/resolv.conf.d/resolv.conf.auto
        ln -sf /tmp/resolv.conf.d/resolv.conf.auto /tmp/resolv.conf
        grep -q debugfs /proc/filesystems && /bin/mount -o noatime -t debugfs debugfs /sys/kernel/debug
+       grep -q bpf /proc/filesystems && /bin/mount -o nosuid,nodev,noexec,noatime,mode=0700 -t bpf bpffs /sys/fs/bpf
        [ "$FAILSAFE" = "true" ] && touch /tmp/.failsafe
 
        /sbin/kmodloader