]> git.baikalelectronics.ru Git - kernel.git/commit
skbuff: add check for non-linear to warn_if_lro and needs_linearize
authorAlexander Duyck <alexander.h.duyck@intel.com>
Wed, 2 Jun 2010 12:24:37 +0000 (12:24 +0000)
committerDavid S. Miller <davem@davemloft.net>
Sat, 5 Jun 2010 09:23:16 +0000 (02:23 -0700)
commitfe0f50dd4412200b3dac534ef2a30fcbf4d5acaf
treefba32dab1e3dca2c5bb5b7d73a64a77c2b6872e8
parent7692549dab69d816357402e277c1131ebf7fac30
skbuff: add check for non-linear to warn_if_lro and needs_linearize

We can avoid an unecessary cache miss by checking if the skb is non-linear
before accessing gso_size/gso_type in skb_warn_if_lro, the same can also be
done to avoid a cache miss on nr_frags if data_len is 0.

Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/linux/skbuff.h
net/core/dev.c