All of lore.kernel.org
 help / color / mirror / Atom feed
From: Leon Romanovsky <leon-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
To: dledford-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org
Cc: linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: [PATCH rdma-next 0/5] mlx5 IB RoCE LAG
Date: Sun, 18 Sep 2016 13:08:11 +0300	[thread overview]
Message-ID: <1474193296-28062-1-git-send-email-leon@kernel.org> (raw)

This feature keeps track, using netdev LAG events,
of the bonding and link status of each port's PF netdev.

When both of the card's PF netdevs are enslaved exclusively
to the same bond master, LAG state is active.
Bond mode must be one of:
1 (active-backup), 2 (XOR), or 4 (802.3ad).

During LAG, a single IB device is present for both ports.
This allows for load balancing and high availability to be
managed by the driver, abstracting it away from ULPs.
Such an IB device is given a name of "mlx5_bond_X".

LAG mode is determined by the bond driver.
In load balancing (modes 2 and 4), QPs are assigned to ports
in a round-robin fashion, on QP transition from RESET->INIT.
In high availability (mode 1), all QPs are assigned to the active
slave, determined by bond driver.

Please note that if the link state of a port becomes down when
mode is load balancing, all QPs will be moved to the other port,
and will be moved back once both ports are up again.

This feature itself split into mlx5_core and mlx5_ib parts, while mlx5_core was
already submitted and accepted:
  1) mlx5_core: Implements RoCE LAG infrastructure and API.
    a) Bond device LAG events tracking.
    b) Decisions as to whether LAG state is active.
    c) Firmware commands to enter and exit LAG state.
    d) Manages HA behavior.
  2) mlx5_ib: Uses core infrastructure to implement RoCE LAG.
    a) Chooses an "mlx5_bond_X" device name when LAG is active.
    b) Implements QP load balancing.
    c) Merges steering, such that both port's traffic arrives on
       PF0's root flow table. This is used for processing
       both port's usermode Ethernet traffic on PF0.
    d) Creates a special flow table that diverts all
       non-usermode Ethernet traffic received on port 2
       back to PF1's root flow table (since non-usermode Ethernet
       should not be affected by LAG).

Available in the "topic/roce-lag-mlx5" topic branch of this git repo:
git://git.kernel.org/pub/scm/linux/kernel/git/leon/linux-rdma.git

Or for browsing:
https://git.kernel.org/cgit/linux/kernel/git/leon/linux-rdma.git/log/?h=topic/roce-lag-mlx5

Thanks

Aviv Heller (5):
  IB/mlx5: Port events in RoCE now rely on netdev events
  IB/mlx5: Merge vports flow steering during LAG
  IB/mlx5: Port status track LAG master, when LAG is active
  IB/mlx5: Set unique device name on LAG
  IB/mlx5: LAG QP load balancing

 drivers/infiniband/hw/mlx5/main.c    | 150 +++++++++++++++++++++++++++++++----
 drivers/infiniband/hw/mlx5/mlx5_ib.h |   2 +
 drivers/infiniband/hw/mlx5/qp.c      |  61 ++++++++++++--
 3 files changed, 191 insertions(+), 22 deletions(-)

--
2.7.4

--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

             reply	other threads:[~2016-09-18 10:08 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-09-18 10:08 Leon Romanovsky [this message]
     [not found] ` <1474193296-28062-1-git-send-email-leon-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
2016-09-18 10:08   ` [PATCH rdma-next 1/5] IB/mlx5: Port events in RoCE now rely on netdev events Leon Romanovsky
2016-09-18 10:08   ` [PATCH rdma-next 2/5] IB/mlx5: Merge vports flow steering during LAG Leon Romanovsky
2016-09-18 10:08   ` [PATCH rdma-next 3/5] IB/mlx5: Port status track LAG master, when LAG is active Leon Romanovsky
2016-09-18 10:08   ` [PATCH rdma-next 4/5] IB/mlx5: Set unique device name on LAG Leon Romanovsky
2016-09-18 10:08   ` [PATCH rdma-next 5/5] IB/mlx5: LAG QP load balancing Leon Romanovsky

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1474193296-28062-1-git-send-email-leon@kernel.org \
    --to=leon-dgejt+ai2ygdnm+yrofe0a@public.gmane.org \
    --cc=dledford-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org \
    --cc=linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.