--- zzzz-none-000/linux-2.6.32.61/include/net/sock.h 2013-06-10 09:43:48.000000000 +0000 +++ ar10-7272-687/linux-2.6.32.61/include/net/sock.h 2017-01-26 13:51:06.000000000 +0000 @@ -293,7 +293,7 @@ void *sk_security; #endif __u32 sk_mark; - /* XXX 4 bytes hole on 64 bit */ + unsigned long sk_tc_index; void (*sk_state_change)(struct sock *sk); void (*sk_data_ready)(struct sock *sk, int bytes); void (*sk_write_space)(struct sock *sk); @@ -1330,6 +1330,9 @@ skb_orphan(skb); skb->sk = sk; skb->destructor = sock_wfree; +#ifdef CONFIG_NET_SCHED + skb->tc_index = sk->sk_tc_index; +#endif /* * We used to take a refcount on sk, but following operation * is enough to guarantee sk_free() wont free this sock until @@ -1481,17 +1484,13 @@ /** * sock_tx_timestamp - checks whether the outgoing packet is to be time stamped - * @msg: outgoing packet * @sk: socket sending this packet - * @shtx: filled with instructions for time stamping + * @tx_flags: filled with instructions for time stamping * * Currently only depends on SOCK_TIMESTAMPING* flags. Returns error code if * parameters are invalid. */ -extern int sock_tx_timestamp(struct msghdr *msg, - struct sock *sk, - union skb_shared_tx *shtx); - +extern int sock_tx_timestamp(struct sock *sk, __u8 *tx_flags); /** * sk_eat_skb - Release a skb if it is no longer needed @@ -1512,7 +1511,7 @@ __skb_queue_tail(&sk->sk_async_wait_queue, skb); } #else -static inline void sk_eat_skb(struct sock *sk, struct sk_buff *skb, int copied_early) +static inline void sk_eat_skb(struct sock *sk, struct sk_buff *skb, int copied_early __attribute__((unused))) { __skb_unlink(skb, &sk->sk_receive_queue); __kfree_skb(skb); @@ -1520,7 +1519,10 @@ #endif static inline -struct net *sock_net(const struct sock *sk) +struct net *sock_net(const struct sock *sk +#ifndef CONFIG_NET_NS + __attribute__((unused))) +#endif { #ifdef CONFIG_NET_NS return sk->sk_net; @@ -1530,7 +1532,15 @@ } static inline -void sock_net_set(struct sock *sk, struct net *net) +void sock_net_set(struct sock *sk +#ifndef CONFIG_NET_NS + __attribute__((unused)) +#endif + , struct net *net +#ifndef CONFIG_NET_NS + __attribute__((unused)) +#endif + ) { #ifdef CONFIG_NET_NS sk->sk_net = net;