j1939: Following kernel updates 91/23191/6
authorRomain Forlot <romain.forlot@iot.bzh>
Wed, 6 Nov 2019 10:31:50 +0000 (11:31 +0100)
committerRomain Forlot <romain.forlot@iot.bzh>
Tue, 7 Jan 2020 23:17:29 +0000 (00:17 +0100)
Compatatibility for latest kernel/glibc version
See: https://github.com/torvalds/linux/commit/0768e17073dc527ccd18ed5f96ce85f9985e9115

Follow j1939 integration in the kernel which remove SO_J1939_RECV_OWN

Bug-AGL: SPEC-2932

Change-Id: Id01e92330582da299af675676987cd667272e2c5
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
low-can-binding/utils/socketcan-j1939/socketcan-j1939.cpp
low-can-binding/utils/socketcan.hpp

index fdcfe3b..88bca56 100644 (file)
@@ -107,7 +107,6 @@ namespace utils
                if(broadcast) broadcast_i = 1;
 
                setopt(SOL_CAN_J1939, SO_J1939_PROMISC, &promisc_i, sizeof(promisc_i));
-               setopt(SOL_CAN_J1939, SO_J1939_RECV_OWN, &recv_own_msgs_i, sizeof(recv_own_msgs_i));
                setopt(SOL_SOCKET, SO_BROADCAST, &broadcast_i, sizeof(broadcast_i));
        }
 
@@ -285,4 +284,4 @@ namespace utils
                }
                return 0;
        }
-}
\ No newline at end of file
+}
index a3b3159..7b2501a 100644 (file)
@@ -21,6 +21,7 @@
 
 #include <sys/socket.h>
 #include <linux/can/bcm.h>
+#include <linux/sockios.h>
 #include <string.h>
 
 #include "../binding/low-can-hat.hpp"