From: Tony Nguyen <anthony.l.nguyen@intel.com>
To: Dave Ertman <david.m.ertman@intel.com>,
<intel-wired-lan@lists.osuosl.org>
Cc: netdev@vger.kernel.org, bcreeley@amd.com,
daniel.machon@microchip.com, simon.horman@corigine.com
Subject: Re: [Intel-wired-lan] [PATCH iwl-next v5 06/10] ice: Flesh out implementation of support for SRIOV on bonded interface
Date: Fri, 16 Jun 2023 13:56:15 -0700 [thread overview]
Message-ID: <d34b0e13-1365-07db-d6bb-694625c8f82c@intel.com> (raw)
In-Reply-To: <20230615162932.762756-7-david.m.ertman@intel.com>
On 6/15/2023 9:29 AM, Dave Ertman wrote:
...
> /**
> @@ -622,6 +1324,69 @@ static void ice_lag_monitor_active(struct ice_lag *lag, void *ptr)
> static bool
> ice_lag_chk_comp(struct ice_lag *lag, void *ptr)
> {
> + struct net_device *event_netdev, *event_upper;
> + struct netdev_notifier_bonding_info *info;
> + struct netdev_bonding_info *bonding_info;
> + struct list_head *tmp;
> + int count = 0;
> +
> + if (!lag->primary)
> + return true;
> +
> + event_netdev = netdev_notifier_info_to_dev(ptr);
> + rcu_read_lock();
> + event_upper = netdev_master_upper_dev_get_rcu(event_netdev);
> + rcu_read_unlock();
> + if (event_upper != lag->upper_netdev)
> + return true;
> +
> + info = (struct netdev_notifier_bonding_info *)ptr;
> + bonding_info = &info->bonding_info;
> + lag->bond_mode = bonding_info->master.bond_mode;
> + if (lag->bond_mode != BOND_MODE_ACTIVEBACKUP) {
> + netdev_info(lag->netdev, "Bond Mode not ACTIVE-BACKUP\n");
> + return false;
> + }
> +
> + list_for_each(tmp, lag->netdev_head) {
> + struct ice_dcbx_cfg *dcb_cfg, *peer_dcb_cfg;
> + struct ice_lag_netdev_list *entry;
> + struct ice_netdev_priv *peer_np;
> + struct net_device *peer_netdev;
> + struct ice_vsi *vsi, *peer_vsi;
> +
> + entry = list_entry(tmp, struct ice_lag_netdev_list, node);
> + peer_netdev = entry->netdev;
> + if (!netif_is_ice(peer_netdev)) {
> + netdev_info(lag->netdev, "Found non-ice netdev in LAG\n");
> + return false;
> + }
> +
> + count++;
> + if (count > 2) {
> + netdev_info(lag->netdev, "Found more than two netdevs in LAG\n");
> + return false;
> + }
> +
> + peer_np = netdev_priv(peer_netdev);
> + vsi = ice_get_main_vsi(lag->pf);
> + peer_vsi = peer_np->vsi;
> + if (lag->pf->pdev->bus != peer_vsi->back->pdev->bus ||
> + lag->pf->pdev->slot != peer_vsi->back->pdev->slot) {
> + netdev_info(lag->netdev, "Found netdev on different device in LAG\n");
> + return false;
> + }
> +
> + dcb_cfg = &vsi->port_info->qos_cfg.local_dcbx_cfg;
> + peer_dcb_cfg = &peer_vsi->port_info->qos_cfg.local_dcbx_cfg;
> + if (memcmp(dcb_cfg, peer_dcb_cfg,
> + sizeof(struct ice_dcbx_cfg))) {
> + netdev_info(lag->netdev, "Found netdev with different DCB config in LAG\n");
> + return false;
> + }
> +
> + }
As you have to respin anyways...
CHECK: Blank lines aren't necessary before a close brace '}'
#893: FILE: drivers/net/ethernet/intel/ice/ice_lag.c:1388:
+
+ }
_______________________________________________
Intel-wired-lan mailing list
Intel-wired-lan@osuosl.org
https://lists.osuosl.org/mailman/listinfo/intel-wired-lan
next prev parent reply other threads:[~2023-06-16 20:56 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-06-15 16:29 [Intel-wired-lan] [PATCH iwl-next v5 00/10] Implement support for SRIOV + LAG Dave Ertman
2023-06-15 16:29 ` [Intel-wired-lan] [PATCH iwl-next v5 01/10] ice: Correctly initialize queue context values Dave Ertman
2023-06-15 16:29 ` [Intel-wired-lan] [PATCH iwl-next v5 02/10] ice: Add driver support for firmware changes for LAG Dave Ertman
2023-06-15 16:29 ` [Intel-wired-lan] [PATCH iwl-next v5 03/10] ice: changes to the interface with the HW and FW for SRIOV_VF+LAG Dave Ertman
2023-06-15 16:29 ` [Intel-wired-lan] [PATCH iwl-next v5 04/10] ice: implement lag netdev event handler Dave Ertman
2023-06-15 16:29 ` [Intel-wired-lan] [PATCH iwl-next v5 05/10] ice: process events created by " Dave Ertman
2023-06-16 20:47 ` Tony Nguyen
2023-06-20 16:07 ` Ertman, David M
2023-06-15 16:29 ` [Intel-wired-lan] [PATCH iwl-next v5 06/10] ice: Flesh out implementation of support for SRIOV on bonded interface Dave Ertman
2023-06-16 20:56 ` Tony Nguyen [this message]
2023-06-20 16:07 ` Ertman, David M
2023-06-15 16:29 ` [Intel-wired-lan] [PATCH iwl-next v5 07/10] ice: support non-standard teardown of bond interface Dave Ertman
2023-06-15 16:29 ` [Intel-wired-lan] [PATCH iwl-next v5 08/10] ice: enforce interface eligibility and add messaging for SRIOV LAG Dave Ertman
2023-06-15 16:29 ` [Intel-wired-lan] [PATCH iwl-next v5 09/10] ice: enforce no DCB config changing when in bond Dave Ertman
2023-06-15 16:29 ` [Intel-wired-lan] [PATCH iwl-next v5 10/10] ice: update reset path for SRIOV LAG support Dave Ertman
-- strict thread matches above, loose matches on Subject: below --
2023-06-20 18:34 [Intel-wired-lan] [PATCH iwl-next v5 00/10] Implement support for SRIOV + LAG Dave Ertman
2023-06-20 18:34 ` [Intel-wired-lan] [PATCH iwl-next v5 06/10] ice: Flesh out implementation of support for SRIOV on bonded interface Dave Ertman
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=d34b0e13-1365-07db-d6bb-694625c8f82c@intel.com \
--to=anthony.l.nguyen@intel.com \
--cc=bcreeley@amd.com \
--cc=daniel.machon@microchip.com \
--cc=david.m.ertman@intel.com \
--cc=intel-wired-lan@lists.osuosl.org \
--cc=netdev@vger.kernel.org \
--cc=simon.horman@corigine.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