]> git.kernelconcepts.de Git - karo-tx-linux.git/blobdiff - include/linux/socket.h
mld, igmp: Fix reserved tailroom calculation
[karo-tx-linux.git] / include / linux / socket.h
index 5c19cba34dce023a49c45d776751190834b88889..5bf59c8493b763c6dc11ccce18da9c0ac6c0da46 100644 (file)
@@ -51,6 +51,7 @@ struct msghdr {
        void            *msg_control;   /* ancillary data */
        __kernel_size_t msg_controllen; /* ancillary data buffer length */
        unsigned int    msg_flags;      /* flags on received message */
+       struct kiocb    *msg_iocb;      /* ptr to iocb for async requests */
 };
  
 struct user_msghdr {
@@ -138,6 +139,11 @@ static inline struct cmsghdr * cmsg_nxthdr (struct msghdr *__msg, struct cmsghdr
        return __cmsg_nxthdr(__msg->msg_control, __msg->msg_controllen, __cmsg);
 }
 
+static inline size_t msg_data_left(struct msghdr *msg)
+{
+       return iov_iter_count(&msg->msg_iter);
+}
+
 /* "Socket"-level control message types: */
 
 #define        SCM_RIGHTS      0x01            /* rw: access rights (array of int) */
@@ -181,6 +187,7 @@ struct ucred {
 #define AF_WANPIPE     25      /* Wanpipe API Sockets */
 #define AF_LLC         26      /* Linux LLC                    */
 #define AF_IB          27      /* Native InfiniBand address    */
+#define AF_MPLS                28      /* MPLS */
 #define AF_CAN         29      /* Controller Area Network      */
 #define AF_TIPC                30      /* TIPC sockets                 */
 #define AF_BLUETOOTH   31      /* Bluetooth sockets            */
@@ -226,6 +233,7 @@ struct ucred {
 #define PF_WANPIPE     AF_WANPIPE
 #define PF_LLC         AF_LLC
 #define PF_IB          AF_IB
+#define PF_MPLS                AF_MPLS
 #define PF_CAN         AF_CAN
 #define PF_TIPC                AF_TIPC
 #define PF_BLUETOOTH   AF_BLUETOOTH