mirror of
https://github.com/gatieme/LDD-LinuxDeviceDrivers.git
synced 2026-11-09 08:38:04 +08:00
测试的proc_test的驱动proc_final包括只读proc_entry, 只写proc_entry和可读写proc_entry...
This commit is contained in:
1 parent
7c44230913
commit
10d274cb00
4 files changed
+84
-87
No files matched your search
@@ -46,7 +46,7 @@
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
#include "config.h"
|
||||
|
||||
/// 当前字符是数字
|
||||
#define IsDigit(c) (c >= '0' && c <= '9')
|
||||
|
||||
@@ -66,7 +66,7 @@
|
||||
#endif
|
||||
|
||||
#if defined(CREATE_PROC_ENTRY) || defined(PROC_CREATE)
|
||||
|
||||
#warning "defined CREATE_PROC_ENTRY || PROC_CREATE"
|
||||
#else
|
||||
#error "you must define one of CREATE_PROC_ENTRY and PROC_CREATE"
|
||||
#endif
|
||||
|
||||
File diff suppressed because it is too large.
Load diff
@@ -31,7 +31,7 @@ int proc_write_rw(struct file *file, const char *buffer, unsigned long count, vo
|
||||
|
||||
if(iRet != 1) { return FAIL; }
|
||||
|
||||
printk(KERN_INFO "Rcv rw:0x%lx\n", rw_data);
|
||||
printk(KERN_INFO "Rcv rw : 0x%lx\n", rw_data);
|
||||
return count;
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user