dac_driver.h
来自「S3C2410 DAC驱动程序」· C头文件 代码 · 共 36 行
H
36 行
#ifndef _DAC_H_#define _DAC_H_/******************************************************** * Macros to help debugging ********************************************************/#undef PDEBUG /* undef it, just in case */#ifdef DAC_DEBUG#ifdef __KERNEL__# define PDEBUG(fmt, args...) printk( KERN_DEBUG "DAC: " fmt, ## args)#else# define PDEBUG(fmt, args...) fprintf(stderr, fmt, ## args)#endif#else# define PDEBUG(fmt, args...) /* not debugging: nothing */#endif#undef PDEBUGG#define PDEBUGG(fmt, args...) /* nothing: it's a placeholder */
#define DAC_MAJOR 226#define DAC_MINOR 0struct dac_dev { struct cdev cdev; /* Char device structure */};ssize_t dac_read(struct file *filp, char __user *buf, size_t count, loff_t *f_pos);ssize_t dac_write(struct file *filp, const char __user *buf, size_t count, loff_t *f_pos);#endif /* _DAC_H_ */
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?