linux核心常用標頭檔作用簡介

來源:互聯網
上載者:User

<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相關函數

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.