linux/net
Jesper Dangaard Brouer 1f59533f9c qdisc: validate frames going through the direct_xmit path
In commit 50cbe9ab5f ("net: Validate xmit SKBs right when we
pull them out of the qdisc") the validation code was moved out of
dev_hard_start_xmit and into dequeue_skb.

However this overlooked the fact that we do not always enqueue
the skb onto a qdisc. First situation is if qdisc have flag
TCQ_F_CAN_BYPASS and qdisc is empty.  Second situation is if
there is no qdisc on the device, which is a common case for
software devices.

Originally spotted and inital patch by Alexander Duyck.
As a result Alex was seeing issues trying to connect to a
vhost_net interface after commit 50cbe9ab5f was applied.

Added a call to validate_xmit_skb() in __dev_xmit_skb(), in the
code path for qdiscs with TCQ_F_CAN_BYPASS flag, and in
__dev_queue_xmit() when no qdisc.

Also handle the error situation where dev_hard_start_xmit() could
return a skb list, and does not return dev_xmit_complete(rc) and
falls through to the kfree_skb(), in that situation it should
call kfree_skb_list().

Fixes:  50cbe9ab5f ("net: Validate xmit SKBs right when we pull them out of the qdisc")
Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com>
Signed-off-by: Jesper Dangaard Brouer <brouer@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2014-09-03 20:41:42 -07:00
..
6lowpan
9p
802
8021q net: Always untag vlan-tagged traffic on input. 2014-08-11 12:16:51 -07:00
appletalk
atm net: Pass a "more" indication down into netdev_start_xmit() code paths. 2014-09-01 17:39:55 -07:00
ax25
batman-adv batman-adv: Fix parameter order of hlist_add_behind 2014-08-16 19:19:08 -07:00
bluetooth
bridge br_multicast: Replace rcu_assign_pointer() with RCU_INIT_POINTER() 2014-08-22 12:23:11 -07:00
caif
can
ceph Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/sage/ceph-client 2014-08-13 17:43:29 -06:00
core qdisc: validate frames going through the direct_xmit path 2014-09-03 20:41:42 -07:00
dcb
dccp
decnet af_decnet: Use time_after_eq 2014-08-22 12:23:11 -07:00
dns_resolver
dsa net: dsa: make dsa_pack_type static 2014-09-01 20:41:45 -07:00
ethernet net: dsa: reduce number of protocol hooks 2014-08-27 22:59:39 -07:00
hsr
ieee802154
ipv4 sock: deduplicate errqueue dequeue 2014-09-01 21:49:08 -07:00
ipv6 sock: deduplicate errqueue dequeue 2014-09-01 21:49:08 -07:00
ipx
irda irda: Fix rd_frame control field initialization in irlap_send_rd_frame() 2014-08-13 20:05:52 -07:00
iucv
key
l2tp l2tp: Enable checksum unnecessary conversions for l2tp/UDP sockets 2014-09-01 21:36:28 -07:00
lapb
llc
mac80211 mac80211: fix channel switch for chanctx-based drivers 2014-08-22 14:45:49 -07:00
mac802154
mpls
netfilter net: use reciprocal_scale() helper 2014-08-23 12:21:21 -07:00
netlabel
netlink netlink: Annotate RCU locking for seq_file walker 2014-08-14 15:13:40 -07:00
netrom
nfc
openvswitch Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2014-08-23 11:12:08 -07:00
packet net: Pass a "more" indication down into netdev_start_xmit() code paths. 2014-09-01 17:39:55 -07:00
phonet
rds
rfkill
rose
rxrpc sock: deduplicate errqueue dequeue 2014-09-01 21:49:08 -07:00
sched qdisc: exit case fixes for skb list handling in qdisc layer 2014-09-03 20:41:42 -07:00
sctp sctp: Change sctp to implement csum_levels 2014-08-29 20:41:11 -07:00
sunrpc NFS client updates for Linux 3.17 2014-08-13 18:13:19 -06:00
tipc tipc: add name distributor resiliency queue 2014-09-01 17:51:48 -07:00
unix
vmw_vsock
wimax
wireless
x25
xfrm
Kconfig
Makefile
compat.c
nonet.c
socket.c
sysctl_net.c