All of lore.kernel.org
 help / color / mirror / Atom feed
From: Amir Shehata <amir.shehata.whamcloud@gmail.com>
To: lustre-devel@lists.lustre.org
Subject: [lustre-devel] [PATCH 20/34] lnet: discard ni_cpt_list
Date: Thu, 13 Sep 2018 12:33:01 -0700	[thread overview]
Message-ID: <CAAqp6i3CZTW_YbqeLc6p955AbKgbZbxNw2LCmA53-LoJ0JXDKg@mail.gmail.com> (raw)
In-Reply-To: <874levqn9z.fsf@notabene.neil.brown.name>

did you read my response to that question? Pasted below:

---
This area was re-implemented. There is no need for ni_cptlist any longer. I
looked at the current code and it's not being used.
Originally it was being used to place the the ni on a global list:
ln_nis_cpt. Which was traversed when attempting to calculate the cpt for a
NID using lnet_cpt_of_nid_locked(). However that latter function has been
re-implemented due to how MR works now. So there is not need for ni_cptlist.
___

thanks
amir

On Wed, 12 Sep 2018 at 17:35, NeilBrown <neilb@suse.com> wrote:

> On Wed, Sep 12 2018, Doug Oucharek wrote:
>
> > I'm assuming that a future patch will be chaining the NI structure on to
> the NET structure it belongs to.  This patch is just not chaining the NIs
> on a global NIS list anymore.  As such, ni_cptlist is being "repurposed".
>
> The NI is already chained onto the NET through
>  lnet_net.net_ni_list and lnet_ni.ni_netlist
>
> ni_cptlist is not used even in current master.
> It is never added to any list, but lnet_ni_unlink_locked() does remove
> it from a list.  Is that code wrong (should be checking ni_netlist), or
> is it cruft that should be removed?
>
> Thanks,
> NeilBrown
>
> >
> > Reviewed-by: Doug Oucharek <dougso@me.com>
> >
> > Doug
> >
> > ?On 9/6/18, 5:54 PM, "NeilBrown" <neilb@suse.com> wrote:
> >
> >     This isn't used any more.
> >     The new comment is odd - this is no net_ni_cpt !!
> >     The ni_cptlist linkage is no longer used - should it go too?
> >
> >     This is part of
> >         8cbb8cd3e771e7f7e0f99cafc19fad32770dc015
> >            LU-7734 lnet: Multi-Rail local NI split
> >
> >     Signed-off-by: NeilBrown <neilb@suse.com>
> >     ---
> >      .../staging/lustre/include/linux/lnet/lib-types.h  |    4 +---
> >      drivers/staging/lustre/lnet/lnet/api-ni.c          |    7 -------
> >      2 files changed, 1 insertion(+), 10 deletions(-)
> >
> >     diff --git a/drivers/staging/lustre/include/linux/lnet/lib-types.h
> b/drivers/staging/lustre/include/linux/lnet/lib-types.h
> >     index 6c34ecf22021..dc15fa75a9d2 100644
> >     --- a/drivers/staging/lustre/include/linux/lnet/lib-types.h
> >     +++ b/drivers/staging/lustre/include/linux/lnet/lib-types.h
> >     @@ -305,7 +305,7 @@ struct lnet_net {
> >      struct lnet_ni {
> >       /* chain on the lnet_net structure */
> >       struct list_head          ni_netlist;
> >     - /* chain on ln_nis_cpt */
> >     + /* chain on net_ni_cpt */
> >       struct list_head        ni_cptlist;
> >
> >       spinlock_t              ni_lock;
> >     @@ -671,8 +671,6 @@ struct lnet {
> >
> >       /* LND instances */
> >       struct list_head                ln_nets;
> >     - /* NIs bond on specific CPT(s) */
> >     - struct list_head                ln_nis_cpt;
> >       /* the loopback NI */
> >       struct lnet_ni                  *ln_loni;
> >       /* network zombie list */
> >     diff --git a/drivers/staging/lustre/lnet/lnet/api-ni.c
> b/drivers/staging/lustre/lnet/lnet/api-ni.c
> >     index 546d5101360f..960f235df5e7 100644
> >     --- a/drivers/staging/lustre/lnet/lnet/api-ni.c
> >     +++ b/drivers/staging/lustre/lnet/lnet/api-ni.c
> >     @@ -538,7 +538,6 @@ lnet_prepare(lnet_pid_t requested_pid)
> >
> >       INIT_LIST_HEAD(&the_lnet.ln_test_peers);
> >       INIT_LIST_HEAD(&the_lnet.ln_nets);
> >     - INIT_LIST_HEAD(&the_lnet.ln_nis_cpt);
> >       INIT_LIST_HEAD(&the_lnet.ln_routers);
> >       INIT_LIST_HEAD(&the_lnet.ln_drop_rules);
> >       INIT_LIST_HEAD(&the_lnet.ln_delay_rules);
> >     @@ -616,7 +615,6 @@ lnet_unprepare(void)
> >       LASSERT(!the_lnet.ln_refcount);
> >       LASSERT(list_empty(&the_lnet.ln_test_peers));
> >       LASSERT(list_empty(&the_lnet.ln_nets));
> >     - LASSERT(list_empty(&the_lnet.ln_nis_cpt));
> >
> >       lnet_portals_destroy();
> >
> >     @@ -1294,11 +1292,6 @@ lnet_startup_lndni(struct lnet_ni *ni, struct
> lnet_lnd_tunables *tun)
> >       /* refcount for ln_nis */
> >       lnet_ni_addref_locked(ni, 0);
> >       list_add_tail(&ni->ni_net->net_list, &the_lnet.ln_nets);
> >     - if (ni->ni_cpts) {
> >     -         lnet_ni_addref_locked(ni, 0);
> >     -         list_add_tail(&ni->ni_cptlist, &the_lnet.ln_nis_cpt);
> >     - }
> >     -
> >       lnet_net_unlock(LNET_LOCK_EX);
> >
> >       ni->ni_state = LNET_NI_STATE_ACTIVE;
> >
> >
> >
> _______________________________________________
> lustre-devel mailing list
> lustre-devel at lists.lustre.org
> http://lists.lustre.org/listinfo.cgi/lustre-devel-lustre.org
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lustre.org/pipermail/lustre-devel-lustre.org/attachments/20180913/3e1b2e4f/attachment.html>

  reply	other threads:[~2018-09-13 19:33 UTC|newest]

Thread overview: 98+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-09-07  0:49 [lustre-devel] [PATCH 00/34] Beginning of multi-rail support for drivers/staging/lustre NeilBrown
2018-09-07  0:49 ` [lustre-devel] [PATCH 11/34] lnet: pass tun to lnet_startup_lndni, instead of full conf NeilBrown
2018-09-11 18:31   ` Amir Shehata
2018-09-12  4:03     ` NeilBrown
2018-09-12  3:30   ` Doug Oucharek
2018-09-07  0:49 ` [lustre-devel] [PATCH 12/34] lnet: split lnet_startup_lndni NeilBrown
2018-09-12  3:39   ` Doug Oucharek
2018-09-07  0:49 ` [lustre-devel] [PATCH 16/34] lnet: lnet_shutdown_lndnets - remove some cleanup code NeilBrown
2018-09-07  0:49 ` [lustre-devel] [PATCH 18/34] lnet: add ni_state NeilBrown
2018-09-12  3:59   ` Doug Oucharek
2018-09-12  4:25     ` NeilBrown
2018-09-07  0:49 ` [lustre-devel] [PATCH 14/34] lnet: rename lnet_find_net_locked to lnet_find_rnet_locked NeilBrown
2018-09-12  3:40   ` Doug Oucharek
2018-09-07  0:49 ` [lustre-devel] [PATCH 09/34] lnet: add list of cpts to lnet_net NeilBrown
2018-09-10 23:28   ` Doug Oucharek
2018-09-12  2:16     ` NeilBrown
2018-09-11  1:02   ` James Simmons
2018-09-07  0:49 ` [lustre-devel] [PATCH 06/34] lnet: store separate xmit/recv net-interface in each message NeilBrown
2018-09-10 23:24   ` Doug Oucharek
2018-09-10 23:29   ` James Simmons
2018-09-10 23:36   ` James Simmons
2018-09-07  0:49 ` [lustre-devel] [PATCH 03/34] lnet: struct lnet_ni: move ni_lnd to lnet_net NeilBrown
2018-09-10 23:04   ` Doug Oucharek
2018-09-10 23:19     ` James Simmons
2018-09-10 23:19       ` Doug Oucharek
2018-09-10 23:19     ` James Simmons
2018-09-10 23:24   ` James Simmons
2018-09-10 23:25   ` James Simmons
2018-09-07  0:49 ` [lustre-devel] [PATCH 15/34] lnet: extend zombie handling to nets and nis NeilBrown
2018-09-12  3:53   ` Doug Oucharek
2018-09-12  4:10     ` NeilBrown
2018-09-07  0:49 ` [lustre-devel] [PATCH 02/34] lnet: Create struct lnet_net NeilBrown
2018-09-10 22:56   ` Doug Oucharek
2018-09-10 23:23   ` James Simmons
2018-09-07  0:49 ` [lustre-devel] [PATCH 04/34] lnet: embed lnd_tunables in lnet_ni NeilBrown
2018-09-10 23:08   ` Doug Oucharek
2018-09-07  0:49 ` [lustre-devel] [PATCH 05/34] lnet: begin separating "networks" from "network interfaces" NeilBrown
2018-09-10 23:18   ` Doug Oucharek
2018-09-12  2:48     ` NeilBrown
2018-09-10 23:27   ` James Simmons
2018-09-07  0:49 ` [lustre-devel] [PATCH 13/34] lnet: reverse order of lnet_startup_lnd{net, ni} NeilBrown
2018-09-12  3:39   ` Doug Oucharek
2018-09-07  0:49 ` [lustre-devel] [PATCH 10/34] lnet: add ni arg to lnet_cpt_of_nid() NeilBrown
2018-09-10 23:32   ` Doug Oucharek
2018-09-11  1:03   ` James Simmons
2018-09-07  0:49 ` [lustre-devel] [PATCH 01/34] struct lnet_ni - reformat comments NeilBrown
2018-09-10 22:49   ` Doug Oucharek
2018-09-10 23:17   ` James Simmons
2018-09-12  2:44     ` NeilBrown
2018-09-07  0:49 ` [lustre-devel] [PATCH 07/34] lnet: change lnet_peer to reference the net, rather than ni NeilBrown
2018-09-10 23:17   ` James Simmons
2018-09-12  2:56     ` NeilBrown
2018-09-07  0:49 ` [lustre-devel] [PATCH 08/34] lnet: add cpt to lnet_match_info NeilBrown
2018-09-10 23:25   ` Doug Oucharek
2018-09-11  1:01   ` James Simmons
2018-09-11  1:01   ` [lustre-devel] BRe: " James Simmons
2018-09-07  0:49 ` [lustre-devel] [PATCH 17/34] lnet: move lnet_shutdown_lndnets down to after first use NeilBrown
2018-09-12  3:55   ` Doug Oucharek
2018-09-07  0:49 ` [lustre-devel] [PATCH 20/34] lnet: discard ni_cpt_list NeilBrown
2018-09-12  4:07   ` Doug Oucharek
2018-09-12  5:48     ` NeilBrown
2018-09-13 19:33       ` Amir Shehata [this message]
2018-09-24  6:03         ` NeilBrown
2018-09-12 16:29   ` Amir Shehata
2018-09-07  0:49 ` [lustre-devel] [PATCH 34/34] lnet: introduce use_tcp_bonding mod param NeilBrown
2018-09-12  4:54   ` Doug Oucharek
2018-09-07  0:49 ` [lustre-devel] [PATCH 28/34] lnet: add checks to ensure network interface names are unique NeilBrown
2018-09-12  4:39   ` Doug Oucharek
2018-09-07  0:49 ` [lustre-devel] [PATCH 27/34] lnet: make it possible to add a new interface to a network NeilBrown
2018-09-12  4:38   ` Doug Oucharek
2018-09-07  0:49 ` [lustre-devel] [PATCH 30/34] lnet: fix typo NeilBrown
2018-09-12  4:47   ` Doug Oucharek
2018-09-07  0:49 ` [lustre-devel] [PATCH 33/34] Completely re-write lnet_parse_networks() NeilBrown
2018-09-12  4:54   ` Doug Oucharek
2018-09-07  0:49 ` [lustre-devel] [PATCH 32/34] lnet: lnet_dyn_del_ni: fix ping_info count NeilBrown
2018-09-12  4:49   ` Doug Oucharek
2018-09-07  0:49 ` [lustre-devel] [PATCH 22/34] lnet: don't take reference in lnet_XX2ni_locked() NeilBrown
2018-09-12  4:18   ` Doug Oucharek
2018-09-07  0:49 ` [lustre-devel] [PATCH 29/34] lnet: track tunables in lnet_startup_lndnet() NeilBrown
2018-09-12  4:47   ` Doug Oucharek
2018-09-07  0:49 ` [lustre-devel] [PATCH 23/34] lnet: don't need lock to test ln_shutdown NeilBrown
2018-09-12  4:27   ` Doug Oucharek
2018-09-12  5:54     ` NeilBrown
2018-09-07  0:49 ` [lustre-devel] [PATCH 26/34] lnet: only valid lnd_type when net_id is unique NeilBrown
2018-09-12  4:34   ` Doug Oucharek
2018-09-07  0:49 ` [lustre-devel] [PATCH 31/34] lnet: lnet_dyn_add_ni: fix ping_info count NeilBrown
2018-09-12  4:48   ` Doug Oucharek
2018-09-07  0:49 ` [lustre-devel] [PATCH 19/34] lnet: simplify lnet_islocalnet() NeilBrown
2018-09-12  4:02   ` Doug Oucharek
2018-09-07  0:49 ` [lustre-devel] [PATCH 25/34] lnet: swap 'then' and 'else' branches in lnet_startup_lndnet NeilBrown
2018-09-12  4:32   ` Doug Oucharek
2018-09-07  0:49 ` [lustre-devel] [PATCH 24/34] lnet: don't take lock over lnet_net_unique() NeilBrown
2018-09-12  4:29   ` Doug Oucharek
2018-09-07  0:49 ` [lustre-devel] [PATCH 21/34] lnet: add net_ni_added NeilBrown
2018-09-12  4:15   ` Doug Oucharek
2018-09-10 23:10 ` [lustre-devel] [PATCH 00/34] Beginning of multi-rail support for drivers/staging/lustre James Simmons
2018-09-24  6:58   ` NeilBrown
2018-09-29 22:35     ` James Simmons

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=CAAqp6i3CZTW_YbqeLc6p955AbKgbZbxNw2LCmA53-LoJ0JXDKg@mail.gmail.com \
    --to=amir.shehata.whamcloud@gmail.com \
    --cc=lustre-devel@lists.lustre.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.