]> rtime.felk.cvut.cz Git - socketcan-devel.git/commit
can-raw: add msg_flags to distinguish local traffic
authorhartkopp <hartkopp@030b6a49-0b11-0410-94ab-b0dab22257f2>
Fri, 22 Oct 2010 05:24:03 +0000 (05:24 +0000)
committerhartkopp <hartkopp@030b6a49-0b11-0410-94ab-b0dab22257f2>
Fri, 22 Oct 2010 05:24:03 +0000 (05:24 +0000)
commit13e779978a5f3bca1f9333d37ab9efa872e9da48
tree7317e23425d02d942da01cf30f1012af07f9d9ad
parentda2ff6e7e7bebfcc206b3c91d723496c29175b37
can-raw: add msg_flags to distinguish local traffic

CAN has no addressing scheme. It is currently impossible for userspace
to tell is a received CAN frame comes from another process on the local
host, or from a remote CAN device.

This patch add support for userspace applications to distinguish between
'own', 'local' and 'remote' CAN traffic. The distinction is made by returning
flags in msg->msg_flags in the call to recvmsg().

The added documentation explains the introduced flags.

Signed-off-by: Kurt Van Dijck <kurt.van.dijck@eia.be>
Signed-off-by: Oliver Hartkopp <socketcan@hartkopp.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
Upstream commit:
http://git.kernel.org/?p=linux/kernel/git/davem/net-next-2.6.git;a=commitdiff;h=1e55659ce6ddb5247cee0b1f720d77a799902b85

git-svn-id: svn://svn.berlios.de//socketcan/trunk@1199 030b6a49-0b11-0410-94ab-b0dab22257f2
kernel/2.6/Documentation/networking/can.txt
kernel/2.6/net/can/raw.c