简体   繁体   English

内核模块如何自动加载

[英]How can kernel modules load automatically

I loaded some kernel modules on linux for an embedded system. 我在Linux上为嵌入式系统加载了一些内核模块。 When I run these kernel-modules by insmod command, it works. 当我通过insmod命令运行这些内核模块时,它可以工作。 How can I run these modules automatically(without entering any command) at boot starting time 如何在启动启动时自动运行这些模块(不输入任何命令)

-----SOLVED---- - - -解决了 - -

I added modules' configuration file to etc/modules-load.d 我将模块的配置文件添加到etc / modules-load.d

Then I put modules and modules.dep file in /lib/modules/ uname -r directory 然后我将modules和modules.dep文件放在/ lib / modules / uname -r目录中

----SOLVED---- - - 解决了 - -

Add your modules in the following config file 在以下配置文件中添加模块

/etc/modules-load.d/modules.conf /etc/modules-load.d/modules.conf

您可以使用modprobe命令

 modprobe {driver-name}

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM