linux-next.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Stephen Rothwell <sfr@canb.auug.org.au>
To: David Miller <davem@davemloft.net>,
	Networking <netdev@vger.kernel.org>,
	Doug Ledford <dledford@redhat.com>,
	Jason Gunthorpe <jgg@mellanox.com>,
	Leon Romanovsky <leon@kernel.org>,
	Eric Dumazet <edumazet@google.com>
Cc: Linux Next Mailing List <linux-next@vger.kernel.org>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	Maor Gottlieb <maorg@mellanox.com>,
	Saeed Mahameed <saeedm@mellanox.com>
Subject: linux-next: manual merge of the net-next tree with the rdma tree
Date: Fri, 8 May 2020 13:18:51 +1000	[thread overview]
Message-ID: <20200508131851.5818d84d@canb.auug.org.au> (raw)

[-- Attachment #1: Type: text/plain, Size: 3760 bytes --]

Hi all,

Today's linux-next merge of the net-next tree got a conflict in:

  drivers/net/bonding/bond_main.c

between commits:

  ed7d4f023b1a ("bonding: Rename slave_arr to usable_slaves")
  c071d91d2a89 ("bonding: Add helper function to get the xmit slave based on hash")
  29d5bbccb3a1 ("bonding: Add helper function to get the xmit slave in rr mode")

from the rdma and mlx5-next trees and commit:

  ae46f184bc1f ("bonding: propagate transmit status")

from the net-next tree.

I fixed it up (I think - see below) and can carry the fix as
necessary. This is now fixed as far as linux-next is concerned, but any
non trivial conflicts should be mentioned to your upstream maintainer
when your tree is submitted for merging.  You may also want to consider
cooperating with the maintainer of the conflicting tree to minimise any
particularly complex conflicts.

-- 
Cheers,
Stephen Rothwell

diff --cc drivers/net/bonding/bond_main.c
index 39b1ad7edbb4,4f9e7c421f57..000000000000
--- a/drivers/net/bonding/bond_main.c
+++ b/drivers/net/bonding/bond_main.c
@@@ -4022,32 -4024,12 +4022,30 @@@ static struct slave *bond_xmit_roundrob
  non_igmp:
  	slave_cnt = READ_ONCE(bond->slave_cnt);
  	if (likely(slave_cnt)) {
 -		slave_id = bond_rr_gen_slave_id(bond);
 -		return bond_xmit_slave_id(bond, skb, slave_id % slave_cnt);
 +		slave_id = bond_rr_gen_slave_id(bond) % slave_cnt;
 +		return bond_get_slave_by_id(bond, slave_id);
  	}
 +	return NULL;
 +}
 +
 +static netdev_tx_t bond_xmit_roundrobin(struct sk_buff *skb,
 +					struct net_device *bond_dev)
 +{
 +	struct bonding *bond = netdev_priv(bond_dev);
 +	struct slave *slave;
 +
 +	slave = bond_xmit_roundrobin_slave_get(bond, skb);
 +	if (slave)
- 		bond_dev_queue_xmit(bond, skb, slave->dev);
- 	else
- 		bond_tx_drop(bond_dev, skb);
- 	return NETDEV_TX_OK;
++		return bond_dev_queue_xmit(bond, skb, slave->dev);
+ 	return bond_tx_drop(bond_dev, skb);
  }
  
 +static struct slave *bond_xmit_activebackup_slave_get(struct bonding *bond,
 +						      struct sk_buff *skb)
 +{
 +	return rcu_dereference(bond->curr_active_slave);
 +}
 +
  /* In active-backup mode, we know that bond->curr_active_slave is always valid if
   * the bond has a usable interface.
   */
@@@ -4057,13 -4039,11 +4055,11 @@@ static netdev_tx_t bond_xmit_activeback
  	struct bonding *bond = netdev_priv(bond_dev);
  	struct slave *slave;
  
 -	slave = rcu_dereference(bond->curr_active_slave);
 +	slave = bond_xmit_activebackup_slave_get(bond, skb);
  	if (slave)
- 		bond_dev_queue_xmit(bond, skb, slave->dev);
- 	else
- 		bond_tx_drop(bond_dev, skb);
+ 		return bond_dev_queue_xmit(bond, skb, slave->dev);
  
- 	return NETDEV_TX_OK;
+ 	return bond_tx_drop(bond_dev, skb);
  }
  
  /* Use this to update slave_array when (a) it's not appropriate to update
@@@ -4254,17 -4178,17 +4250,14 @@@ static netdev_tx_t bond_3ad_xor_xmit(st
  				     struct net_device *dev)
  {
  	struct bonding *bond = netdev_priv(dev);
 -	struct slave *slave;
  	struct bond_up_slave *slaves;
 -	unsigned int count;
 +	struct slave *slave;
  
 -	slaves = rcu_dereference(bond->slave_arr);
 -	count = slaves ? READ_ONCE(slaves->count) : 0;
 -	if (likely(count)) {
 -		slave = slaves->arr[bond_xmit_hash(bond, skb) % count];
 +	slaves = rcu_dereference(bond->usable_slaves);
 +	slave = bond_xmit_3ad_xor_slave_get(bond, skb, slaves);
 +	if (likely(slave))
- 		bond_dev_queue_xmit(bond, skb, slave->dev);
- 	else
- 		bond_tx_drop(dev, skb);
- 
- 	return NETDEV_TX_OK;
+ 		return bond_dev_queue_xmit(bond, skb, slave->dev);
 -	}
+ 	return bond_tx_drop(dev, skb);
  }
  
  /* in broadcast mode, we send everything to all usable interfaces. */

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

             reply	other threads:[~2020-05-08  3:18 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-05-08  3:18 Stephen Rothwell [this message]
2020-05-08 12:35 ` linux-next: manual merge of the net-next tree with the rdma tree Jason Gunthorpe
2020-05-09  7:49   ` Saeed Mahameed
2020-05-09  7:40 ` Saeed Mahameed
  -- strict thread matches above, loose matches on Subject: below --
2021-10-28  0:56 Stephen Rothwell
2021-10-28  7:48 ` Saeed Mahameed
2021-10-19 23:34 Stephen Rothwell
2019-06-20  2:15 Stephen Rothwell
2019-02-27  0:25 Stephen Rothwell
2019-02-27 16:24 ` Doug Ledford
2019-02-28  9:05   ` Leon Romanovsky
2019-02-18  0:05 Stephen Rothwell
2019-02-18 10:48 ` Leon Romanovsky
2018-08-02  2:05 Stephen Rothwell
2018-08-15 23:45 ` Stephen Rothwell
2018-07-27  2:33 Stephen Rothwell
2018-07-27  2:48 ` Jason Gunthorpe
2018-07-27  3:28   ` Stephen Rothwell
2018-07-27  3:45     ` Stephen Rothwell
2018-07-27  5:03       ` Parav Pandit
2018-07-27  4:57     ` Parav Pandit
2018-07-27  5:09       ` Stephen Rothwell
2018-07-31 21:12         ` Parav Pandit
2018-08-01  5:33           ` Stephen Rothwell
2018-08-01 17:13             ` Jason Gunthorpe
2018-08-01 18:30               ` Parav Pandit
2018-07-02  0:21 Stephen Rothwell
2018-08-15 23:41 ` Stephen Rothwell

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=20200508131851.5818d84d@canb.auug.org.au \
    --to=sfr@canb.auug.org.au \
    --cc=davem@davemloft.net \
    --cc=dledford@redhat.com \
    --cc=edumazet@google.com \
    --cc=jgg@mellanox.com \
    --cc=leon@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-next@vger.kernel.org \
    --cc=maorg@mellanox.com \
    --cc=netdev@vger.kernel.org \
    --cc=saeedm@mellanox.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).