use sysfs to read/write bin attribute of driver

39 views
Skip to first unread message

Jiejie Rong

unread,
Jul 7, 2011, 9:19:17 PM7/7/11
to zh-kernel
hi all,
我注册了bin attribute的读写函数,不过不了解在用户空间如何去读写??
我读写非bin attribute直接cat/echo就行了。。。。不知道linux下有没自带的工具
能够读写 bin attribute的文件的?

best regards


_______________________________________________
Linux 内核开发中文邮件列表
Linux-...@zh-kernel.org
http://zh-kernel.org/mailman/listinfo/linux-kernel
Linux 内核开发中文社区: http://zh-kernel.org

Américo Wang

unread,
Jul 10, 2011, 5:58:20 AM7/10/11
to Jiejie Rong, zh-kernel
2011/7/8 Jiejie Rong <rji...@gmail.com>:

> hi all,
> 我注册了bin attribute的读写函数,不过不了解在用户空间如何去读写??
> 我读写非bin attribute直接cat/echo就行了。。。。不知道linux下有没自带的工具
> 能够读写 bin attribute的文件的?

hexdump -C

jojo

unread,
Jul 10, 2011, 11:12:49 AM7/10/11
to Américo Wang, zh-kernel
嗯,找到了,操作二进制文件的工具操作。。。thanks

在 2011年7月10日星期日,下午5:58,Américo Wang 写道:

> 2011/7/8 Jiejie Rong <rji...@gmail.com (mailto:rji...@gmail.com)>:

Reply all
Reply to author
Forward
0 new messages