做S3C2410的驅動比較重要的幾個檔案

2021-07-29 21:10:53 字數 1313 閱讀 1386

**——hantown原創

做s3c2410的驅動,下面幾個檔案是必須去認真關注的:

include/asm-arm/arch-s3c2410/irqs.h定義了中斷相關的各種巨集

include/asm-arm/arch-s3c2410/regs-gpio.h定義了各種gpio

arch/arch/arm/plat-s3c24xx/gpio.c 定義了各種gpio操作函式

arch/arch/arm/plat-s3c24xx/devs.c定義了s3c24xx平台下的各種platform_device和resource資源;如果在這裡找不到資源,可以自己用struct resource ***xx_resource ,

和struct platform_device platform_device_***xx= ;

來定義//define in file include/asm-arm/arch-s3c2410/irqs.h

//#define irq_eint0      s3c2410_irq(0)     /* 16 */

//#define s3c2410_irq(x) ((x) + s3c2410_cpuirq_offset)

//#define s3c2410_cpuirq_offset  (16)

//define in file include/asm-arm/arch-s3c2410/regs-gpio.h

//#define s3c2410_gpf0        s3c2410_gpiono(s3c2410_gpio_bankf, 0)

//#define s3c2410_gpf0_inp    (0x00 << 0)

//#define s3c2410_gpf0_outp   (0x01 << 0)

//#define s3c2410_gpf0_eint0  (0x02 << 0) setup gpf0 is eint0,falling edge triggered

//#define s3c2400_gpf0_rxd0   (0x02 << 0)

//the function defined in file arch/arch/arm/plat-s3c24xx/gpio.c

//s3c2410_gpio_setpin(gpio, value);setup value of xx pin 

//extern int s3c2410_gpio_irq2pin(unsigned int irq);get pin of xx irq

//unsigned int s3c2410_gpio_getpin(unsigned int pin);get vlaue of xx pin

s3c2410的nand flash的驅動分析

以前都是把別人寫好的 直接拿過來用,而沒有去關心裡面到底怎麼實現的,昨晚對照著samsung 2410和k 9f1208的晶元資料把這些 讀了一遍,終於明白了對nand flash的操作一步步是怎麼實現的了。以下的這些 可以在vivi或者kernel裡面找到 對乙個nand flash的操作,總體上...

S3C2410讀寫Nand Flash分析

2009 01 15 16 51 321人閱讀 收藏舉報 s3c2410讀寫nand flash分析 一 結構分析 s3c2410處理器整合了8位nandflash控制器。目前市場上常見的8位nandflash有三星公司的k9f1208 k9f1g08 k9f2g08等。k9f1208 k9f1g0...

S3C2410快速啟動的實現

嵌入式系統對功能 可靠性 成本 體積 功耗等均有嚴格要求,以arm體系結構為基礎的各種risc微處理器具有靈活的特性和強大的效能,在嵌入式系統中得到了廣泛的應用。s3c2410是三星公司基於arm920t設計的一款處理器,在開發基於s3c2410的系統的過程中,如何讓系統快速穩定地啟動是乙個重要問題...