[ovs-git] [openvswitch/ovs] 3262e3: datapath: backport: OVS: Ignore negative headroom ...

GitHub noreply at github.com
Mon Aug 15 16:54:47 UTC 2016


  Branch: refs/heads/master
  Home:   https://github.com/openvswitch/ovs
  Commit: 3262e36909da58c316af909f2deb7fd0f04818cf
      https://github.com/openvswitch/ovs/commit/3262e36909da58c316af909f2deb7fd0f04818cf
  Author: Pravin B Shelar <pshelar at ovn.org>
  Date:   2016-08-15 (Mon, 15 Aug 2016)

  Changed paths:
    M datapath/vport-internal_dev.c

  Log Message:
  -----------
  datapath: backport: OVS: Ignore negative headroom value

Upstream commit:
    commit 5ef9f289c4e698054e5687edb54f0da3cdc9173a
    Author: Ian Wienand <iwienand at redhat.com>
    Date:   Wed Aug 3 15:44:57 2016 +1000

    OVS: Ignore negative headroom value

    net_device->ndo_set_rx_headroom (introduced in
    871b642adebe300be2e50aa5f65a418510f636ec) says

      "Setting a negtaive value reset the rx headroom
       to the default value".

    It seems that the OVS implementation in
    3a927bc7cf9d0fbe8f4a8189dd5f8440228f64e7 overlooked this and sets
    dev->needed_headroom unconditionally.

    This doesn't have an immediate effect, but can mess up later
    LL_RESERVED_SPACE calculations, such as done in
    net/ipv6/mcast.c:mld_newpack.  For reference, this issue was found
    from a skb_panic raised there after the length calculations had given
    the wrong result.

    Note the other current users of this interface
    (drivers/net/tun.c:tun_set_headroom and
    drivers/net/veth.c:veth_set_rx_headroom) are both checking this
    correctly thus need no modification.

    Thanks to Ben for some pointers from the crash dumps!

    Cc: Benjamin Poirier <bpoirier at suse.com>
    Cc: Paolo Abeni <pabeni at redhat.com>
    Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1361414
    Signed-off-by: Ian Wienand <iwienand at redhat.com>
    Signed-off-by: David S. Miller <davem at davemloft.net>

Signed-off-by: Pravin B Shelar <pshelar at ovn.org>
Acked-by: Jesse Gross <jesse at kernel.org>




More information about the git mailing list