现在的位置: 首页 > 综合 > 正文

(转)linux内核常用头文件作用简介

2014年01月17日 ⁄ 综合 ⁄ 共 657字 ⁄ 字号 评论关闭

<linux/fb.h> 与framebuffer相关的宏定义如FB_EVENT_BLANK, extern一些常用的函数如fb_blank(), 结构体定义如 struct fb_fix_screeninfo,fb_var_screeninfo

<linux/ctype.h> 定义了一些用于判断某一个字符是否为大写字母、小写字母、数字、控制字符、标点符号等宏,如,isdigit(c)判定参数c是否为数字,此外还有大小写转换宏,如tolower(c), toupper(c)

<linux/wait.h> 定义了linux 进程休眠/等待(sleep/wait)与唤醒(wake up)的相关宏和函数,注意,是进程相关的,并不是系统的休眠(suspend)与唤醒(resume)。

<linux/interrupt.h> 定义了或extern了与中断相关的函数,像request_irq, free_irq 与中断相关的结构体,如tasklet_struct, 

<linux/fs.h> 定义了跟 file_operation相关的函数与结构体, 要用到file_operation相关的东西时需要include 此头文件。

<linux/slab.h> 定义了 kmalloc 相关的函数, 要用到kmalloc 时需要include此头文件。

<asm/uaccess.h> 定义了copy_to_user,  copy_from_user相关函数

转自:http://blog.csdn.net/lihaoweiv/article/details/7851163

抱歉!评论已关闭.