Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
Mostly simple overlapping changes. For example, David Ahern's adjacency list revamp in 'net-next' conflicted with an adjacency list traversal bug fix in 'net'. Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
@@ -174,6 +174,7 @@ int ipv6_sock_mc_join(struct sock *sk, int ifindex,
|
||||
const struct in6_addr *addr);
|
||||
int ipv6_sock_mc_drop(struct sock *sk, int ifindex,
|
||||
const struct in6_addr *addr);
|
||||
void __ipv6_sock_mc_close(struct sock *sk);
|
||||
void ipv6_sock_mc_close(struct sock *sk);
|
||||
bool inet6_mc_check(struct sock *sk, const struct in6_addr *mc_addr,
|
||||
const struct in6_addr *src_addr);
|
||||
|
||||
+65
-42
@@ -820,9 +820,9 @@ enum station_parameters_apply_mask {
|
||||
* (or NULL for no change)
|
||||
* @supported_rates_len: number of supported rates
|
||||
* @sta_flags_mask: station flags that changed
|
||||
* (bitmask of BIT(NL80211_STA_FLAG_...))
|
||||
* (bitmask of BIT(%NL80211_STA_FLAG_...))
|
||||
* @sta_flags_set: station flags values
|
||||
* (bitmask of BIT(NL80211_STA_FLAG_...))
|
||||
* (bitmask of BIT(%NL80211_STA_FLAG_...))
|
||||
* @listen_interval: listen interval or -1 for no change
|
||||
* @aid: AID or zero for no change
|
||||
* @peer_aid: mesh peer AID or zero for no change
|
||||
@@ -3160,47 +3160,54 @@ struct ieee80211_iface_limit {
|
||||
*
|
||||
* 1. Allow #STA <= 1, #AP <= 1, matching BI, channels = 1, 2 total:
|
||||
*
|
||||
* struct ieee80211_iface_limit limits1[] = {
|
||||
* { .max = 1, .types = BIT(NL80211_IFTYPE_STATION), },
|
||||
* { .max = 1, .types = BIT(NL80211_IFTYPE_AP}, },
|
||||
* };
|
||||
* struct ieee80211_iface_combination combination1 = {
|
||||
* .limits = limits1,
|
||||
* .n_limits = ARRAY_SIZE(limits1),
|
||||
* .max_interfaces = 2,
|
||||
* .beacon_int_infra_match = true,
|
||||
* };
|
||||
* .. code-block:: c
|
||||
*
|
||||
* struct ieee80211_iface_limit limits1[] = {
|
||||
* { .max = 1, .types = BIT(NL80211_IFTYPE_STATION), },
|
||||
* { .max = 1, .types = BIT(NL80211_IFTYPE_AP}, },
|
||||
* };
|
||||
* struct ieee80211_iface_combination combination1 = {
|
||||
* .limits = limits1,
|
||||
* .n_limits = ARRAY_SIZE(limits1),
|
||||
* .max_interfaces = 2,
|
||||
* .beacon_int_infra_match = true,
|
||||
* };
|
||||
*
|
||||
*
|
||||
* 2. Allow #{AP, P2P-GO} <= 8, channels = 1, 8 total:
|
||||
*
|
||||
* struct ieee80211_iface_limit limits2[] = {
|
||||
* { .max = 8, .types = BIT(NL80211_IFTYPE_AP) |
|
||||
* BIT(NL80211_IFTYPE_P2P_GO), },
|
||||
* };
|
||||
* struct ieee80211_iface_combination combination2 = {
|
||||
* .limits = limits2,
|
||||
* .n_limits = ARRAY_SIZE(limits2),
|
||||
* .max_interfaces = 8,
|
||||
* .num_different_channels = 1,
|
||||
* };
|
||||
* .. code-block:: c
|
||||
*
|
||||
* struct ieee80211_iface_limit limits2[] = {
|
||||
* { .max = 8, .types = BIT(NL80211_IFTYPE_AP) |
|
||||
* BIT(NL80211_IFTYPE_P2P_GO), },
|
||||
* };
|
||||
* struct ieee80211_iface_combination combination2 = {
|
||||
* .limits = limits2,
|
||||
* .n_limits = ARRAY_SIZE(limits2),
|
||||
* .max_interfaces = 8,
|
||||
* .num_different_channels = 1,
|
||||
* };
|
||||
*
|
||||
*
|
||||
* 3. Allow #STA <= 1, #{P2P-client,P2P-GO} <= 3 on two channels, 4 total.
|
||||
*
|
||||
* This allows for an infrastructure connection and three P2P connections.
|
||||
* This allows for an infrastructure connection and three P2P connections.
|
||||
*
|
||||
* .. code-block:: c
|
||||
*
|
||||
* struct ieee80211_iface_limit limits3[] = {
|
||||
* { .max = 1, .types = BIT(NL80211_IFTYPE_STATION), },
|
||||
* { .max = 3, .types = BIT(NL80211_IFTYPE_P2P_GO) |
|
||||
* BIT(NL80211_IFTYPE_P2P_CLIENT), },
|
||||
* };
|
||||
* struct ieee80211_iface_combination combination3 = {
|
||||
* .limits = limits3,
|
||||
* .n_limits = ARRAY_SIZE(limits3),
|
||||
* .max_interfaces = 4,
|
||||
* .num_different_channels = 2,
|
||||
* };
|
||||
*
|
||||
* struct ieee80211_iface_limit limits3[] = {
|
||||
* { .max = 1, .types = BIT(NL80211_IFTYPE_STATION), },
|
||||
* { .max = 3, .types = BIT(NL80211_IFTYPE_P2P_GO) |
|
||||
* BIT(NL80211_IFTYPE_P2P_CLIENT), },
|
||||
* };
|
||||
* struct ieee80211_iface_combination combination3 = {
|
||||
* .limits = limits3,
|
||||
* .n_limits = ARRAY_SIZE(limits3),
|
||||
* .max_interfaces = 4,
|
||||
* .num_different_channels = 2,
|
||||
* };
|
||||
*/
|
||||
struct ieee80211_iface_combination {
|
||||
const struct ieee80211_iface_limit *limits;
|
||||
@@ -4119,6 +4126,18 @@ unsigned int ieee80211_get_mesh_hdrlen(struct ieee80211s_hdr *meshhdr);
|
||||
* that do not do the 802.11/802.3 conversion on the device.
|
||||
*/
|
||||
|
||||
/**
|
||||
* ieee80211_data_to_8023_exthdr - convert an 802.11 data frame to 802.3
|
||||
* @skb: the 802.11 data frame
|
||||
* @ehdr: pointer to a &struct ethhdr that will get the header, instead
|
||||
* of it being pushed into the SKB
|
||||
* @addr: the device MAC address
|
||||
* @iftype: the virtual interface type
|
||||
* Return: 0 on success. Non-zero on error.
|
||||
*/
|
||||
int ieee80211_data_to_8023_exthdr(struct sk_buff *skb, struct ethhdr *ehdr,
|
||||
const u8 *addr, enum nl80211_iftype iftype);
|
||||
|
||||
/**
|
||||
* ieee80211_data_to_8023 - convert an 802.11 data frame to 802.3
|
||||
* @skb: the 802.11 data frame
|
||||
@@ -4126,8 +4145,11 @@ unsigned int ieee80211_get_mesh_hdrlen(struct ieee80211s_hdr *meshhdr);
|
||||
* @iftype: the virtual interface type
|
||||
* Return: 0 on success. Non-zero on error.
|
||||
*/
|
||||
int ieee80211_data_to_8023(struct sk_buff *skb, const u8 *addr,
|
||||
enum nl80211_iftype iftype);
|
||||
static inline int ieee80211_data_to_8023(struct sk_buff *skb, const u8 *addr,
|
||||
enum nl80211_iftype iftype)
|
||||
{
|
||||
return ieee80211_data_to_8023_exthdr(skb, NULL, addr, iftype);
|
||||
}
|
||||
|
||||
/**
|
||||
* ieee80211_data_from_8023 - convert an 802.3 frame to 802.11
|
||||
@@ -4145,22 +4167,23 @@ int ieee80211_data_from_8023(struct sk_buff *skb, const u8 *addr,
|
||||
/**
|
||||
* ieee80211_amsdu_to_8023s - decode an IEEE 802.11n A-MSDU frame
|
||||
*
|
||||
* Decode an IEEE 802.11n A-MSDU frame and convert it to a list of
|
||||
* 802.3 frames. The @list will be empty if the decode fails. The
|
||||
* @skb is consumed after the function returns.
|
||||
* Decode an IEEE 802.11 A-MSDU and convert it to a list of 802.3 frames.
|
||||
* The @list will be empty if the decode fails. The @skb must be fully
|
||||
* header-less before being passed in here; it is freed in this function.
|
||||
*
|
||||
* @skb: The input IEEE 802.11n A-MSDU frame.
|
||||
* @skb: The input A-MSDU frame without any headers.
|
||||
* @list: The output list of 802.3 frames. It must be allocated and
|
||||
* initialized by by the caller.
|
||||
* @addr: The device MAC address.
|
||||
* @iftype: The device interface type.
|
||||
* @extra_headroom: The hardware extra headroom for SKBs in the @list.
|
||||
* @has_80211_header: Set it true if SKB is with IEEE 802.11 header.
|
||||
* @check_da: DA to check in the inner ethernet header, or NULL
|
||||
* @check_sa: SA to check in the inner ethernet header, or NULL
|
||||
*/
|
||||
void ieee80211_amsdu_to_8023s(struct sk_buff *skb, struct sk_buff_head *list,
|
||||
const u8 *addr, enum nl80211_iftype iftype,
|
||||
const unsigned int extra_headroom,
|
||||
bool has_80211_header);
|
||||
const u8 *check_da, const u8 *check_sa);
|
||||
|
||||
/**
|
||||
* cfg80211_classify8021d - determine the 802.1p/1d tag for a data frame
|
||||
|
||||
@@ -190,8 +190,8 @@ struct inet6_dev {
|
||||
__u32 if_flags;
|
||||
int dead;
|
||||
|
||||
u32 desync_factor;
|
||||
u8 rndid[8];
|
||||
struct timer_list regen_timer;
|
||||
struct list_head tempaddr_list;
|
||||
|
||||
struct in6_addr token;
|
||||
|
||||
+9
-3
@@ -38,7 +38,7 @@ struct sock;
|
||||
struct inet_skb_parm {
|
||||
int iif;
|
||||
struct ip_options opt; /* Compiled IP options */
|
||||
unsigned char flags;
|
||||
u16 flags;
|
||||
|
||||
#define IPSKB_FORWARDED BIT(0)
|
||||
#define IPSKB_XFRM_TUNNEL_SIZE BIT(1)
|
||||
@@ -48,10 +48,16 @@ struct inet_skb_parm {
|
||||
#define IPSKB_DOREDIRECT BIT(5)
|
||||
#define IPSKB_FRAG_PMTU BIT(6)
|
||||
#define IPSKB_FRAG_SEGS BIT(7)
|
||||
#define IPSKB_L3SLAVE BIT(8)
|
||||
|
||||
u16 frag_max_size;
|
||||
};
|
||||
|
||||
static inline bool ipv4_l3mdev_skb(u16 flags)
|
||||
{
|
||||
return !!(flags & IPSKB_L3SLAVE);
|
||||
}
|
||||
|
||||
static inline unsigned int ip_hdrlen(const struct sk_buff *skb)
|
||||
{
|
||||
return ip_hdr(skb)->ihl * 4;
|
||||
@@ -572,7 +578,7 @@ int ip_options_rcv_srr(struct sk_buff *skb);
|
||||
*/
|
||||
|
||||
void ipv4_pktinfo_prepare(const struct sock *sk, struct sk_buff *skb);
|
||||
void ip_cmsg_recv_offset(struct msghdr *msg, struct sk_buff *skb, int offset);
|
||||
void ip_cmsg_recv_offset(struct msghdr *msg, struct sk_buff *skb, int tlen, int offset);
|
||||
int ip_cmsg_send(struct sock *sk, struct msghdr *msg,
|
||||
struct ipcm_cookie *ipc, bool allow_ipv6);
|
||||
int ip_setsockopt(struct sock *sk, int level, int optname, char __user *optval,
|
||||
@@ -594,7 +600,7 @@ void ip_local_error(struct sock *sk, int err, __be32 daddr, __be16 dport,
|
||||
|
||||
static inline void ip_cmsg_recv(struct msghdr *msg, struct sk_buff *skb)
|
||||
{
|
||||
ip_cmsg_recv_offset(msg, skb, 0);
|
||||
ip_cmsg_recv_offset(msg, skb, 0, 0);
|
||||
}
|
||||
|
||||
bool icmp_global_allow(void);
|
||||
|
||||
@@ -230,6 +230,8 @@ struct fib6_table {
|
||||
rwlock_t tb6_lock;
|
||||
struct fib6_node tb6_root;
|
||||
struct inet_peer_base tb6_peers;
|
||||
unsigned int flags;
|
||||
#define RT6_TABLE_HAS_DFLT_ROUTER BIT(0)
|
||||
};
|
||||
|
||||
#define RT6_TABLE_UNSPEC RT_TABLE_UNSPEC
|
||||
|
||||
@@ -32,6 +32,7 @@ struct route_info {
|
||||
#define RT6_LOOKUP_F_SRCPREF_TMP 0x00000008
|
||||
#define RT6_LOOKUP_F_SRCPREF_PUBLIC 0x00000010
|
||||
#define RT6_LOOKUP_F_SRCPREF_COA 0x00000020
|
||||
#define RT6_LOOKUP_F_IGNORE_LINKSTATE 0x00000040
|
||||
|
||||
/* We do not (yet ?) support IPv6 jumbograms (RFC 2675)
|
||||
* Unlike IPv4, hdr->seg_len doesn't include the IPv6 header
|
||||
|
||||
+13
-8
@@ -811,14 +811,18 @@ enum mac80211_rate_control_flags {
|
||||
* in the control information, and it will be filled by the rate
|
||||
* control algorithm according to what should be sent. For example,
|
||||
* if this array contains, in the format { <idx>, <count> } the
|
||||
* information
|
||||
* information::
|
||||
*
|
||||
* { 3, 2 }, { 2, 2 }, { 1, 4 }, { -1, 0 }, { -1, 0 }
|
||||
*
|
||||
* then this means that the frame should be transmitted
|
||||
* up to twice at rate 3, up to twice at rate 2, and up to four
|
||||
* times at rate 1 if it doesn't get acknowledged. Say it gets
|
||||
* acknowledged by the peer after the fifth attempt, the status
|
||||
* information should then contain
|
||||
* information should then contain::
|
||||
*
|
||||
* { 3, 2 }, { 2, 2 }, { 1, 1 }, { -1, 0 } ...
|
||||
*
|
||||
* since it was transmitted twice at rate 3, twice at rate 2
|
||||
* and once at rate 1 after which we received an acknowledgement.
|
||||
*/
|
||||
@@ -1168,8 +1172,8 @@ enum mac80211_rx_vht_flags {
|
||||
* @rate_idx: index of data rate into band's supported rates or MCS index if
|
||||
* HT or VHT is used (%RX_FLAG_HT/%RX_FLAG_VHT)
|
||||
* @vht_nss: number of streams (VHT only)
|
||||
* @flag: %RX_FLAG_*
|
||||
* @vht_flag: %RX_VHT_FLAG_*
|
||||
* @flag: %RX_FLAG_\*
|
||||
* @vht_flag: %RX_VHT_FLAG_\*
|
||||
* @rx_flags: internal RX flags for mac80211
|
||||
* @ampdu_reference: A-MPDU reference number, must be a different value for
|
||||
* each A-MPDU but the same for each subframe within one A-MPDU
|
||||
@@ -1432,7 +1436,7 @@ enum ieee80211_vif_flags {
|
||||
* @probe_req_reg: probe requests should be reported to mac80211 for this
|
||||
* interface.
|
||||
* @drv_priv: data area for driver use, will always be aligned to
|
||||
* sizeof(void *).
|
||||
* sizeof(void \*).
|
||||
* @txq: the multicast data TX queue (if driver uses the TXQ abstraction)
|
||||
*/
|
||||
struct ieee80211_vif {
|
||||
@@ -1743,7 +1747,7 @@ struct ieee80211_sta_rates {
|
||||
* @wme: indicates whether the STA supports QoS/WME (if local devices does,
|
||||
* otherwise always false)
|
||||
* @drv_priv: data area for driver use, will always be aligned to
|
||||
* sizeof(void *), size is determined in hw information.
|
||||
* sizeof(void \*), size is determined in hw information.
|
||||
* @uapsd_queues: bitmap of queues configured for uapsd. Only valid
|
||||
* if wme is supported. The bits order is like in
|
||||
* IEEE80211_WMM_IE_STA_QOSINFO_AC_*.
|
||||
@@ -2152,12 +2156,12 @@ enum ieee80211_hw_flags {
|
||||
*
|
||||
* @radiotap_mcs_details: lists which MCS information can the HW
|
||||
* reports, by default it is set to _MCS, _GI and _BW but doesn't
|
||||
* include _FMT. Use %IEEE80211_RADIOTAP_MCS_HAVE_* values, only
|
||||
* include _FMT. Use %IEEE80211_RADIOTAP_MCS_HAVE_\* values, only
|
||||
* adding _BW is supported today.
|
||||
*
|
||||
* @radiotap_vht_details: lists which VHT MCS information the HW reports,
|
||||
* the default is _GI | _BANDWIDTH.
|
||||
* Use the %IEEE80211_RADIOTAP_VHT_KNOWN_* values.
|
||||
* Use the %IEEE80211_RADIOTAP_VHT_KNOWN_\* values.
|
||||
*
|
||||
* @radiotap_timestamp: Information for the radiotap timestamp field; if the
|
||||
* 'units_pos' member is set to a non-negative value it must be set to
|
||||
@@ -2492,6 +2496,7 @@ void ieee80211_free_txskb(struct ieee80211_hw *hw, struct sk_buff *skb);
|
||||
* in the software stack cares about, we will, in the future, have mac80211
|
||||
* tell the driver which information elements are interesting in the sense
|
||||
* that we want to see changes in them. This will include
|
||||
*
|
||||
* - a list of information element IDs
|
||||
* - a list of OUIs for the vendor information element
|
||||
*
|
||||
|
||||
+3
-1
@@ -252,6 +252,7 @@ struct sock_common {
|
||||
* @sk_pacing_rate: Pacing rate (if supported by transport/packet scheduler)
|
||||
* @sk_max_pacing_rate: Maximum pacing rate (%SO_MAX_PACING_RATE)
|
||||
* @sk_sndbuf: size of send buffer in bytes
|
||||
* @sk_padding: unused element for alignment
|
||||
* @sk_no_check_tx: %SO_NO_CHECK setting, set checksum in TX packets
|
||||
* @sk_no_check_rx: allow zero checksum in RX packets
|
||||
* @sk_route_caps: route capabilities (e.g. %NETIF_F_TSO)
|
||||
@@ -302,7 +303,8 @@ struct sock_common {
|
||||
* @sk_backlog_rcv: callback to process the backlog
|
||||
* @sk_destruct: called at sock freeing time, i.e. when all refcnt == 0
|
||||
* @sk_reuseport_cb: reuseport group container
|
||||
*/
|
||||
* @sk_rcu: used during RCU grace period
|
||||
*/
|
||||
struct sock {
|
||||
/*
|
||||
* Now struct inet_timewait_sock also uses sock_common, so please just
|
||||
|
||||
+12
-1
@@ -794,12 +794,23 @@ struct tcp_skb_cb {
|
||||
*/
|
||||
static inline int tcp_v6_iif(const struct sk_buff *skb)
|
||||
{
|
||||
bool l3_slave = skb_l3mdev_slave(TCP_SKB_CB(skb)->header.h6.flags);
|
||||
bool l3_slave = ipv6_l3mdev_skb(TCP_SKB_CB(skb)->header.h6.flags);
|
||||
|
||||
return l3_slave ? skb->skb_iif : TCP_SKB_CB(skb)->header.h6.iif;
|
||||
}
|
||||
#endif
|
||||
|
||||
/* TCP_SKB_CB reference means this can not be used from early demux */
|
||||
static inline bool inet_exact_dif_match(struct net *net, struct sk_buff *skb)
|
||||
{
|
||||
#if IS_ENABLED(CONFIG_NET_L3_MASTER_DEV)
|
||||
if (!net->ipv4.sysctl_tcp_l3mdev_accept &&
|
||||
ipv4_l3mdev_skb(TCP_SKB_CB(skb)->header.h4.flags))
|
||||
return true;
|
||||
#endif
|
||||
return false;
|
||||
}
|
||||
|
||||
/* Due to TSO, an SKB can be composed of multiple actual
|
||||
* packets. To keep these tracked properly, we use this.
|
||||
*/
|
||||
|
||||
@@ -262,6 +262,7 @@ void udp4_hwcsum(struct sk_buff *skb, __be32 src, __be32 dst);
|
||||
int udp_rcv(struct sk_buff *skb);
|
||||
int udp_ioctl(struct sock *sk, int cmd, unsigned long arg);
|
||||
int udp_init_sock(struct sock *sk);
|
||||
int __udp_disconnect(struct sock *sk, int flags);
|
||||
int udp_disconnect(struct sock *sk, int flags);
|
||||
unsigned int udp_poll(struct file *file, struct socket *sock, poll_table *wait);
|
||||
struct sk_buff *skb_udp_tunnel_segment(struct sk_buff *skb,
|
||||
|
||||
+2
-2
@@ -225,9 +225,9 @@ struct vxlan_config {
|
||||
struct vxlan_dev {
|
||||
struct hlist_node hlist; /* vni hash table */
|
||||
struct list_head next; /* vxlan's per namespace list */
|
||||
struct vxlan_sock *vn4_sock; /* listening socket for IPv4 */
|
||||
struct vxlan_sock __rcu *vn4_sock; /* listening socket for IPv4 */
|
||||
#if IS_ENABLED(CONFIG_IPV6)
|
||||
struct vxlan_sock *vn6_sock; /* listening socket for IPv6 */
|
||||
struct vxlan_sock __rcu *vn6_sock; /* listening socket for IPv6 */
|
||||
#endif
|
||||
struct net_device *dev;
|
||||
struct net *net; /* netns for packet i/o */
|
||||
|
||||
Reference in New Issue
Block a user