在Linux的内核空间中执行程序 [英] Execute a program in kernel space in Linux
本文介绍了在Linux的内核空间中执行程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
如果我想在Linux内核空间中执行用户程序(而不是内核模块),我有什么选择?
If I want to execute a user program (not a kernel module) in Linux kernel space, what options do I have?
我看过KML(内核模式linux),但是它特定于IA-32体系结构.我想要一个跨平台的解决方案,并且可以在嵌入式linux系统上工作.
I have looked at KML(kernel mode linux) but that is specific to IA-32 architecture. I want a solution which is cross platform and can work on embedded linux systems.
推荐答案
用户程序不要在内核空间中执行-这就是使它们成为用户程序的原因.
User programs don't execute in kernel space - that's what makes them user programs.
如果要在内核空间中执行代码,有两种选择:将其构建到内核中,或将其加载到内核模块中.
If you want to execute code in kernel space you have two options: build it in to the kernel, or load it with a kernel module.
这篇关于在Linux的内核空间中执行程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文