|
|
入门文章:教你学会编写Linux设备驱动之结束篇1 |
|
|
|
return 0;
}
static int
asdf_release /* close回调 */
(
struct inode *inode,
struct file *filp
){
printk("^_^ : close\n ");
return 0;
}
static ssize_t
asdf_read /* read回调 */
(
struct file *filp,
char *buf,
size_t count,
loff_t *f_pos
){
loff_t pos;
pos = *f_pos; /* 文件的读写位置 */
if ((pos==40 页码:[1] [2] [3] [4] [5] 第1页、共5页 |
|
|