/* * Copyright (c) 2016 Chelsio Communications, Inc. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation. * */ #ifndef __CXGBIT_LRO_H__ #define __CXGBIT_LRO_H__ #include #include #include #include #include #define LRO_FLUSH_LEN_MAX 65535 struct cxgbit_lro_cb { struct cxgbit_sock *csk; u32 pdu_totallen; u32 offset; u8 pdu_idx; bool complete; }; enum cxgbit_pducb_flags { PDUCBF_RX_HDR = (1 << 0), /* received pdu header */ PDUCBF_RX_DATA = (1 << 1), /* received pdu payload */ PDUCBF_RX_STATUS = (1 << 2), /* received ddp status */ PDUCBF_RX_DATA_DDPD = (1 << 3), /* pdu payload ddp'd */ PDUCBF_RX_HCRC_ERR = (1 << 4), /* header digest error */ PDUCBF_RX_DCRC_ERR = (1 << 5), /* data digest error */ }; struct cxgbit_lro_pdu_cb { u8 flags; u8 frags; u8 hfrag_idx; u8 nr_dfrags; u8 dfrag_idx; bool complete; u32 seq; u32 pdulen; u32 hlen; u32 dlen; u32 doffset; u32 ddigest; void *hdr; }; #define LRO_SKB_MAX_HEADROOM \ (sizeof(struct cxgbit_lro_cb) + \ (MAX_SKB_FRAGS * sizeof(struct cxgbit_lro_pdu_cb))) #define LRO_SKB_MIN_HEADROOM \ (sizeof(struct cxgbit_lro_cb) + \ sizeof(struct cxgbit_lro_pdu_cb)) #define cxgbit_skb_lro_cb(skb) ((struct cxgbit_lro_cb *)skb->data) #define cxgbit_skb_lro_pdu_cb(skb, i) \ ((struct cxgbit_lro_pdu_cb *)(skb->data + sizeof(struct cxgbit_lro_cb) \ + (i * sizeof(struct cxgbit_lro_pdu_cb)))) #define CPL_RX_ISCSI_DDP_STATUS_DDP_SHIFT 16 /* ddp'able */ #define CPL_RX_ISCSI_DDP_STATUS_PAD_SHIFT 19 /* pad error */ #define CPL_RX_ISCSI_DDP_STATUS_HCRC_SHIFT 20 /* hcrc error */ #define CPL_RX_ISCSI_DDP_STATUS_DCRC_SHIFT 21 /* dcrc error */ #endif /*__CXGBIT_LRO_H_*/ -next.git/commit/net/sched?id=fee402211ff2d2f0a136a9d77b30d66aeea193b8'>commitdiff
path: root/net/sched
AgeCommit message (Collapse)AuthorFilesLines
2017-02-03Merge git://git.kernel.org/pub/scm/linux/kernel/git/pablo/nf-nextDavid S. Miller1-1/+1
Pablo Neira Ayuso says: ==================== Netfilter updates for net-next The following patchset contains Netfilter updates for your net-next tree, they are: 1) Stash ctinfo 3-bit field into pointer to nf_conntrack object from sk_buff so we only access one single cacheline in the conntrack hotpath. Patchset from Florian Westphal. 2) Don't leak pointer to internal structures when exporting x_tables ruleset back to userspace, from Willem DeBruijn. This includes new helper functions to copy data to userspace such as xt_data_to_user() as well as conversions of our ip_tables, ip6_tables and arp_tables clients to use it. Not surprinsingly, ebtables requires an ad-hoc update. There is also a new field in x_tables extensions to indicate the amount of bytes that we copy to userspace. 3) Add nf_log_all_netns sysctl: This new knob allows you to enable logging via nf_log infrastructure for all existing netnamespaces. Given the effort to provide pernet syslog has been discontinued, let's provide a way to restore logging using netfilter kernel logging facilities in trusted environments. Patch from Michal Kubecek. 4) Validate SCTP checksum from conntrack helper, from Davide Caratti. 5) Merge UDPlite conntrack and NAT helpers into UDP, this was mostly a copy&paste from the original helper, from Florian Westphal. 6) Reset netfilter state when duplicating packets, also from Florian. 7) Remove unnecessary check for broadcast in IPv6 in pkttype match and nft_meta, from Liping Zhang. 8) Add missing code to deal with loopback packets from nft_meta when used by the netdev family, also from Liping. 9) Several cleanups on nf_tables, one to remove unnecessary check from the netlink control plane path to add table, set and stateful objects and code consolidation when unregister chain hooks, from Gao Feng. 10) Fix harmless reference counter underflow in IPVS that, however, results in problems with the introduction of the new refcount_t type, from David Windsor. 11) Enable LIBCRC32C from nf_ct_sctp instead of nf_nat_sctp, from Davide Caratti. 12) Missing documentation on nf_tables uapi header, from Liping Zhang. 13) Use rb_entry() helper in xt_connlimit, from Geliang Tang. ==================== Signed-off-by: David S. Miller <davem@davemloft.net>
2017-02-03sched: cls_flower: expose priority to offloading netdeviceJiri Pirko1-0/+3
The driver that offloads flower rules needs to know with which priority user inserted the rules. So add this information into offload struct. Signed-off-by: Jiri Pirko <jiri@mellanox.com> Acked-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2017-02-03net/sched: act_ife: Change to use ife moduleYotam Gigi2-78/+33
Use the encode/decode functionality from the ife module instead of using implementation inside the act_ife. Reviewed-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: Yotam Gigi <yotamg@mellanox.com> Signed-off-by: Jamal Hadi Salim <jhs@mojatatu.com> Signed-off-by: Roman Mashak <mrv@mojatatu.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2017-02-03net/sched: act_ife: Unexport ife_tlv_meta_encodeYotam Gigi1-2/+2
As the function ife_tlv_meta_encode is not used by any other module, unexport it and make it static for the act_ife module. Signed-off-by: Yotam Gigi <yotamg@mellanox.com> Signed-off-by: Jamal Hadi Salim <jhs@mojatatu.com> Signed-off-by: Roman Mashak <mrv@mojatatu.com> Signed-off-by: David S. Miller <davem@davemloft.net>
2017-02-02Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/netDavid S. Miller2-85/+48
All merge conflicts were simple overlapping changes. Signed-off-by: David S. Miller <davem@davemloft.net>
2017-02-02skbuff: add and use skb_nfct helperFlorian Westphal1-1/+1
Followup patch renames skb->nfct and changes its type so add a helper to avoid intrusive rename change later. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>