27 Nov, 2009

28 commits

  • Currently the UP/DOWN state of VLANs is synchronized to the state of the
    underlying device, meaning all VLANs are set down once the underlying
    device is set down. This causes all routes to the VLAN devices to vanish.

    Add a flag to specify a "loose binding" mode, in which only the operstate
    is transfered, but the VLAN device state is independant.

    Signed-off-by: Patrick McHardy
    Signed-off-by: David S. Miller

    Patrick McHardy
     
  • Signed-off-by: Ben Hutchings
    Signed-off-by: David S. Miller

    Ben Hutchings
     
  • Signed-off-by: Ben Hutchings
    Signed-off-by: David S. Miller

    Ben Hutchings
     
  • From: Steve Hodgson

    Currently we can set multicast hash immediately (in atomic context)
    but must delay setting MAC promiscuity. There is not that much
    point in deferring one but not the other, and setting the multicast
    hash on Siena will involve a firmware request. So process them
    both in efx_mac_work().

    Also, set the broadcast bit in the multicast hash in
    efx_set_multicast_list(), since this is required for both Falcon and
    Siena.

    Signed-off-by: Ben Hutchings
    Signed-off-by: David S. Miller

    Ben Hutchings
     
  • From: Steve Hodgson

    Only the XMAC on Falcon needs help from the driver to poll and reset
    the MAC-PHY link (XAUI); GMII is a simple parallel bus and on later
    NICs firmware takes care of the XAUI link. Also, an XMAC interrupt
    currently schedules a work item which simply clears a flag
    (efx_nic::mac_up) to be checked by the regular monitor (or the next
    link reconfiguration, if that is sooner).

    Rename the flag to xmac_poll_required, changing its sense. Remove the
    needless indirection and just set the flag immediately. Call
    falcon_xmac_poll() directly where required.

    Add a new generic operation mac_op::check_fault to check the link
    outside of regular monitoring, as required during self-tests.

    (Note that this leaves us with an unused work item, but we will
    immediately have another use for it.)

    Signed-off-by: Ben Hutchings
    Signed-off-by: David S. Miller

    Ben Hutchings
     
  • Signed-off-by: Ben Hutchings
    Signed-off-by: David S. Miller

    Ben Hutchings
     
  • From: Steve Hodgson

    Currently we initiate MAC stats DMA and busy-wait for completion when
    stats are requested. We can improve on this with a periodic timer to
    initiate and poll for stats, and opportunistically poll when stats are
    requested.

    Since efx_nic::stats_disable_count and efx_stats_{disable,enable}()
    are Falcon-specific, rename them and move them accordingly.

    Signed-off-by: Ben Hutchings
    Signed-off-by: David S. Miller

    Ben Hutchings
     
  • Although efx_init_port() is only called at probe time and so cannot
    race with port reconfiguration, most of the functions it calls can
    expect to be called with the MAC lock held.

    Signed-off-by: Ben Hutchings
    Signed-off-by: David S. Miller

    Ben Hutchings
     
  • Signed-off-by: Ben Hutchings
    Signed-off-by: David S. Miller

    Steve Hodgson
     
  • Signed-off-by: Ben Hutchings
    Signed-off-by: David S. Miller

    Ben Hutchings
     
  • Avoid overrunning the hardware limit of 4 concurrent RX queue flushes.
    Expand the queue flush state to support this. Make similar changes to
    TX flushing to keep the code symmetric.

    Signed-off-by: Ben Hutchings
    Signed-off-by: David S. Miller

    Ben Hutchings
     
  • Put all static information in struct falcon_board_type and replace it
    with a pointer in struct falcon_board. Simplify probing aocordingly.

    Signed-off-by: Ben Hutchings
    Signed-off-by: David S. Miller

    Ben Hutchings
     
  • Signed-off-by: Ben Hutchings
    Signed-off-by: David S. Miller

    Ben Hutchings
     
  • Signed-off-by: Ben Hutchings
    Signed-off-by: David S. Miller

    Ben Hutchings
     
  • Signed-off-by: Ben Hutchings
    Signed-off-by: David S. Miller

    Ben Hutchings
     
  • Although all the defined fields in these registers are within 32 bits,
    they are architecturally defined as 128-bit like most other Falcon
    registers. In particular, we must use efx_reado() to ensure proper
    locking when reading MD_STAT_REG.

    Signed-off-by: Ben Hutchings
    Signed-off-by: David S. Miller

    Ben Hutchings
     
  • These were accidentally undersized by a factor of 2, which limited
    performance.

    Signed-off-by: Ben Hutchings
    Signed-off-by: David S. Miller

    Ben Hutchings
     
  • In order to support all three modes of macvlan at
    runtime, extend the existing netlink protocol
    to allow choosing the mode per macvlan slave
    interface.

    This depends on a matching patch to iproute2
    in order to become accessible in user land.

    Signed-off-by: Arnd Bergmann
    Acked-by: Patrick McHardy
    Signed-off-by: David S. Miller

    Arnd Bergmann
     
  • This allows each macvlan slave device to be in one
    of three modes, depending on the use case:

    MACVLAN_PRIVATE:
    The device never communicates with any other device
    on the same upper_dev. This even includes frames
    coming back from a reflective relay, where supported
    by the adjacent bridge.

    MACVLAN_VEPA:
    The new Virtual Ethernet Port Aggregator (VEPA) mode,
    we assume that the adjacent bridge returns all frames
    where both source and destination are local to the
    macvlan port, i.e. the bridge is set up as a reflective
    relay.
    Broadcast frames coming in from the upper_dev get
    flooded to all macvlan interfaces in VEPA mode.
    We never deliver any frames locally.

    MACVLAN_BRIDGE:
    We provide the behavior of a simple bridge between
    different macvlan interfaces on the same port. Frames
    from one interface to another one get delivered directly
    and are not sent out externally. Broadcast frames get
    flooded to all other bridge ports and to the external
    interface, but when they come back from a reflective
    relay, we don't deliver them again.
    Since we know all the MAC addresses, the macvlan bridge
    mode does not require learning or STP like the bridge
    module does.

    Based on an earlier patch "macvlan: Reflect macvlan packets
    meant for other macvlan devices" by Eric Biederman.

    Signed-off-by: Arnd Bergmann
    Acked-by: Patrick McHardy
    Cc: Eric Biederman
    Signed-off-by: David S. Miller

    Arnd Bergmann
     
  • We have very similar code for rx statistics in
    two places in the macvlan driver, with a third
    one being added in the next patch.

    Consolidate them into one function to improve
    overall readability of the driver.

    Signed-off-by: Arnd Bergmann
    Acked-by: Patrick McHardy
    Signed-off-by: David S. Miller

    Arnd Bergmann
     
  • The veth driver contains code to forward an skb
    from the start_xmit function of one network
    device into the receive path of another device.

    Moving that code into a common location lets us
    reuse the code for direct forwarding of data
    between macvlan ports, and possibly in other
    drivers.

    Signed-off-by: Arnd Bergmann
    Acked-by: Patrick McHardy
    Signed-off-by: David S. Miller

    Arnd Bergmann
     
  • Signed-off-by: Simon Kagstrom
    Signed-off-by: David S. Miller

    Simon Kagstrom
     
  • Defaults to on (as before).

    Signed-off-by: Simon Kagstrom
    Signed-off-by: David S. Miller

    Simon Kagstrom
     
  • The velocity hardware can handle up to 7 memory segments. This can be
    turned on and off via ethtool. The support was removed in commit

    83c98a8cd04dd0f848574370594886ba3bf56750

    but is re-enabled and cleaned up here. It's off by default.

    Signed-off-by: Simon Kagstrom
    Signed-off-by: David S. Miller

    Simon Kagstrom
     
  • The VIA driver has changed the default for the DMA_LENGTH_DEF parameter.
    Together with adaptive interrupt supression and NAPI support, this
    improves performance quite a bit

    Signed-off-by: Simon Kagstrom
    Signed-off-by: David S. Miller

    Simon Kagstrom
     
  • This patch adds NAPI support for VIA velocity. The new velocity_poll
    function also pairs tx/rx handling twice which improves perforamance on
    some workloads (e.g., netperf UDP_STREAM) significantly (that part is
    from the VIA driver).

    Signed-off-by: Simon Kagstrom
    Signed-off-by: David S. Miller

    Simon Kagstrom
     
  • (Partially from the upstream VIA driver). Tweaking the number of
    frames-per-interrupt and timer-until-interrupt can reduce the amount of
    CPU work quite a lot.

    Signed-off-by: Simon Kagstrom
    Signed-off-by: David S. Miller

    Simon Kagstrom
     
  • (From the VIA driver). The current code does not guarantee 64-byte
    alignment since it simply does

    int add = skb->data & 63;

    skb->data += add;

    (via skb_reserve). So for example, if the skb->data address would be
    0x10, this would result in 32-byte alignment (0x10 + 0x10).

    Correct by adding

    64 - (skb->data & 63)

    instead.

    Signed-off-by: Simon Kagstrom
    Signed-off-by: David S. Miller

    Simon Kagstrom
     

26 Nov, 2009

7 commits


25 Nov, 2009

5 commits