Netlink user-space and kernel-space communication
Posted
by sasayins
on Stack Overflow
See other posts from Stack Overflow
or by sasayins
Published on 2010-06-12T01:20:58Z
Indexed on
2010/06/12
1:33 UTC
Read the original article
Hit count: 283
linux
Hi,
I am learning programming in embedded systems using Linux as my main platform. And I want to create a Device Event Management Service. This service is a user-space application/daemon that will detect if a connected hardware module triggered an event. But my problem is I don't know where should I start.
I read about Netlink implementation for userspace-kernelspace communication and it seems its a good idea but not sure if it is the best solution. But I read that the UDEV device manager uses Netlink to wait a "uevent" from the kernel space but it is not clear for me how to do that.
I read about polling sysfs but it seems it is not a good idea to poll filesystem.
What do you think the implementation that should I use in my service? Should I use netlink(hard/no clue how to) or just polling the sysfs(not sure if it works)?
Thanks
© Stack Overflow or respective owner