Chinaunix首页 | 论坛 | 博客
  • 博客访问: 478670
  • 博文数量: 144
  • 博客积分: 0
  • 博客等级: 民兵
  • 技术积分: 508
  • 用 户 组: 普通用户
  • 注册时间: 2014-09-10 13:18
个人简介

Keep looking Donot settle

文章分类

全部博文(144)

文章存档

2019年(1)

2016年(31)

2015年(51)

2014年(61)

发布时间:2014-12-12 18:11:46

......【阅读全文】

阅读(2119) | 评论(0) | 转发(0)

发布时间:2014-12-11 16:36:48

(一)先分析/proc/interruptslinux-2.6.28/arch/arm/kernel/irq.c --> show_interrupt()在linux-2.6.28/fs/proc/interrupt.cmodule_init(proc_interrupts_init);|-->proc_interrupts_init()|--> proc_create("interrupts", 0, NULL, &proc_interrupts_operations);一位伟大的程序员说过 -- "代码就是最好.........【阅读全文】

阅读(4142) | 评论(0) | 转发(0)

发布时间:2014-12-03 17:49:54

前面讲了内核模块怎么安装和卸载,那么现在就正式讲解一下内核模块怎么编写。以一个在内核中打印出”hello world”到终端的例子讲解。1、  首先要写模块加载时的入口函数和模块卸载时的入口函数static  int  hello_init(){         &nb.........【阅读全文】

阅读(1001) | 评论(0) | 转发(0)

发布时间:2014-12-03 17:34:07

Linux内核是一种单体内核,但是通过动态加载模块的方式,使它的开发非常灵活 方便。那么,它是如何编译内核的呢?我们可以通过分析它的Makefile入手。以下是 一个简单的hello内核模块的Makefile. ifneq ($(KERNELRELEASE),)obj-m:=hello.oelseKERNELDIR:=/lib/modules/$(shell uname -r)/buildPWD:=$(shell pwd)def.........【阅读全文】

阅读(1025) | 评论(0) | 转发(0)

发布时间:2014-12-03 14:30:55

最近学习linux的驱动编写,在网上普遍用类似以下的Makefile1obj-m += target.o2KERNEL_DIR:=/path/to/the/kernel/source/dir.........【阅读全文】

阅读(810) | 评论(0) | 转发(0)
给主人留下些什么吧!~~
留言热议
请登录后留言。

登录 注册