我需要为Linux系统编写一个内核模块,如下所示。
# uname -a
Linux (none) 3.7.1 #1 SMP Mon Dec 23 06:07:19 PST 2013 i686 GNU/Linux
# cat /proc/cpuinfo
processor : 0
vendor_id : GenuineIntel
cpu family : 6
model : 6
model name : QEMU Virtual CPU version 2.5+
stepping : 3
cpu MHz : 2793.012
cache size : 4096 KB
fdiv_bug : no
hlt_bug : no
f00f_bug : no
coma_bug : no
fpu : yes
fpu_exception : yes
cpuid level : 4
wp : yes
flags : fpu de pse tsc msr pae mce cx8 apic sep pge cmov mmx fxsr sse sse2 pni hypervisor
bogomips : 5586.02
clflush size : 32
cache_alignment : 32
address sizes : 36 bits physical, 32 bits virtual
power management:Linux没有安装内核头或构建系统(gcc/ld)。因此,我需要在我的系统上本地设置它。如何找到这个特定系统的内核头?github上的linux内核只有下面的版本,没有一个版本与安装的内核版本(v3.7.1)完全匹配。
$ git tag | grep v3.7
v3.7
v3.7-rc1
v3.7-rc2
v3.7-rc3
v3.7-rc4
v3.7-rc5
v3.7-rc6
v3.7-rc7
v3.7-rc8发布于 2018-06-15 03:30:06
存档源为在kernel.org,可作为3.7.1版本的压缩tarball和修补程序集在CDN存储库中.使用,可获得下列tarball:
https://unix.stackexchange.com/questions/449916
复制相似问题