]> Gitweb @ Texas Instruments - Open Source Git Repositories - git.TI.com/gitweb - ipc/ipcdev.git/commitdiff
Linux: Update user AF_RPMSG define for 4.11+ kernels
authorSuman Anna <s-anna@ti.com>
Wed, 18 Oct 2017 21:11:13 +0000 (16:11 -0500)
committerAngela Stegmaier <angelabaker@ti.com>
Thu, 19 Oct 2017 16:01:04 +0000 (11:01 -0500)
IPC's Linux user space support contains a copy of a few
kernel-defined structs and definitions including the socket
address family used for rpmsg-based sockets - AF_RPMSG. This
driver is currently out-of-tree and so it's definition is
always 'one more' than the last address family defined by
the mainline kernel's socket.h.

A new address family was introduced in 4.11 (AF_SMC), and as
a result, the AF_RPMSG macro needs to be set to 44 post 4.11
kernel. The user space header has been updated to reflect on
the kernel version and appropriately assign the value of
AF_RPMSG.

Do note that a specific value of AF_RPMSG can always be provided
through the products.mak when KERNEL_INSTALL_DIR is not set.

Signed-off-by: Suman Anna <s-anna@ti.com>
linux/include/net/rpmsg.h

index 8f406e846c825dc531a015c5478731c0983b7e0f..6c59086980d0a83ee508be3476c8e983deea45e7 100644 (file)
 #define AF_RPMSG        41
 #elif LINUX_VERSION_CODE < KERNEL_VERSION(4,7,0)
 #define AF_RPMSG        42
-#else
+#elif LINUX_VERSION_CODE < KERNEL_VERSION(4,11,0)
 #define AF_RPMSG        43
+#else
+#define AF_RPMSG        44
 #endif /* LINUX_VERSION_CODE */
 #endif /* AF_RPMSG */