1. 31 7月, 2019 1 次提交
  2. 23 7月, 2019 6 次提交
  3. 10 7月, 2019 1 次提交
  4. 09 7月, 2019 5 次提交
  5. 06 7月, 2019 1 次提交
  6. 19 6月, 2019 1 次提交
  7. 05 6月, 2019 1 次提交
  8. 31 5月, 2019 1 次提交
  9. 17 5月, 2019 1 次提交
    • W
      net: test nouarg before dereferencing zerocopy pointers · 185ce5c3
      Willem de Bruijn 提交于
      Zerocopy skbs without completion notification were added for packet
      sockets with PACKET_TX_RING user buffers. Those signal completion
      through the TP_STATUS_USER bit in the ring. Zerocopy annotation was
      added only to avoid premature notification after clone or orphan, by
      triggering a copy on these paths for these packets.
      
      The mechanism had to define a special "no-uarg" mode because packet
      sockets already use skb_uarg(skb) == skb_shinfo(skb)->destructor_arg
      for a different pointer.
      
      Before deferencing skb_uarg(skb), verify that it is a real pointer.
      
      Fixes: 5cd8d46e ("packet: copy user buffers before orphan or clone")
      Signed-off-by: NWillem de Bruijn <willemb@google.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      185ce5c3
  10. 26 4月, 2019 1 次提交
  11. 24 4月, 2019 3 次提交
  12. 19 4月, 2019 1 次提交
  13. 18 4月, 2019 1 次提交
  14. 09 4月, 2019 1 次提交
  15. 02 4月, 2019 1 次提交
  16. 09 3月, 2019 1 次提交
  17. 07 3月, 2019 1 次提交
  18. 23 2月, 2019 1 次提交
    • M
      net: Don't set transport offset to invalid value · d2aa125d
      Maxim Mikityanskiy 提交于
      If the socket was created with socket(AF_PACKET, SOCK_RAW, 0),
      skb->protocol will be unset, __skb_flow_dissect() will fail, and
      skb_probe_transport_header() will fall back to the offset_hint, making
      the resulting skb_transport_offset incorrect.
      
      If, however, there is no transport header in the packet,
      transport_header shouldn't be set to an arbitrary value.
      
      Fix it by leaving the transport offset unset if it couldn't be found, to
      be explicit rather than to fill it with some wrong value. It changes the
      behavior, but if some code relied on the old behavior, it would be
      broken anyway, as the old one is incorrect.
      Signed-off-by: NMaxim Mikityanskiy <maximmi@mellanox.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      d2aa125d
  19. 16 2月, 2019 1 次提交
  20. 13 2月, 2019 1 次提交
    • B
      net/skbuff: fix up kernel-doc placement · 4ea7b0cf
      Brian Norris 提交于
      There are several skb_* functions where the locked and unlocked
      functions are confusingly documented. For several of them, the
      kernel-doc for the unlocked version is placed above the locked version,
      which to the casual reader makes it seems like the locked version "takes
      no locks and you must therefore hold required locks before calling it."
      
      One can see, for example, that this link claims to document
      skb_queue_head(), while instead describing __skb_queue_head().
      
      https://www.kernel.org/doc/html/latest/networking/kapi.html#c.skb_queue_head
      
      The correct documentation for skb_queue_head() is also included further
      down the page.
      
      This diff tested via:
      
        $ scripts/kernel-doc -rst include/linux/skbuff.h net/core/skbuff.c
      
      No new warnings were seen, and the output makes a little more sense.
      Signed-off-by: NBrian Norris <briannorris@chromium.org>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      4ea7b0cf
  21. 11 2月, 2019 1 次提交
    • W
      bpf: only adjust gso_size on bytestream protocols · b90efd22
      Willem de Bruijn 提交于
      bpf_skb_change_proto and bpf_skb_adjust_room change skb header length.
      For GSO packets they adjust gso_size to maintain the same MTU.
      
      The gso size can only be safely adjusted on bytestream protocols.
      Commit d02f51cb ("bpf: fix bpf_skb_adjust_net/bpf_skb_proto_xlat
      to deal with gso sctp skbs") excluded SKB_GSO_SCTP.
      
      Since then type SKB_GSO_UDP_L4 has been added, whose contents are one
      gso_size unit per datagram. Also exclude these.
      
      Move from a blacklist to a whitelist check to future proof against
      additional such new GSO types, e.g., for fraglist based GRO.
      
      Fixes: bec1f6f6 ("udp: generate gso with UDP_SEGMENT")
      Signed-off-by: NWillem de Bruijn <willemb@google.com>
      Signed-off-by: NAlexei Starovoitov <ast@kernel.org>
      b90efd22
  22. 04 2月, 2019 2 次提交
  23. 29 1月, 2019 1 次提交
  24. 19 1月, 2019 1 次提交
  25. 08 1月, 2019 1 次提交
  26. 22 12月, 2018 1 次提交
  27. 20 12月, 2018 2 次提交