Linux RDMA and InfiniBand development
 help / color / mirror / Atom feed
From: Yuval Shaia <yuval.shaia-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org>
To: Hal Rosenstock <hal-LDSdmyG8hGV8YrgS2mwiifqBs+8SCbDb@public.gmane.org>
Cc: sean.hefty-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org,
	linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: [PATCH v1] ibacm: Handle EP expiration time
Date: Mon, 19 Sep 2016 16:21:38 +0300	[thread overview]
Message-ID: <20160919132138.GA21320@yuval-lap.uk.oracle.com> (raw)
In-Reply-To: <387b0fc4-949f-b8e2-6ac3-136e5ab2e127-LDSdmyG8hGV8YrgS2mwiifqBs+8SCbDb@public.gmane.org>

On Mon, Sep 19, 2016 at 07:22:54AM -0400, Hal Rosenstock wrote:
> > +
> >  static struct acmp_dest *
> >  acmp_acquire_dest(struct acmp_ep *ep, uint8_t addr_type, const uint8_t *addr)
> >  {
> > @@ -366,6 +376,16 @@ acmp_acquire_dest(struct acmp_ep *ep, uint8_t addr_type, const uint8_t *addr)
> >  	acm_log(2, "%s\n", log_data);
> >  	lock_acquire(&ep->lock);
> >  	dest = acmp_get_dest(ep, addr_type, addr);
> > +	if (dest && dest->state == ACMP_READY &&
> > +	    dest->addr_timeout != 0xFFFFFFFFFFFFFFFF) {
> 
> Nit related to the timeout check:
> In acmp.c, (uint64_t)~0ULL is used in other places for this. Should this
> addr_timeout check be changed to some infinite or no timeout define
> along with the other occurrences for consistency and better code
> readability ?

Will do.

> 
> -- Hal
> 
> > +		acm_log(2, "Record valid for the next %ld minute(s)\n",
> > +			dest->addr_timeout - time_stamp_min());
> > +		if (time_stamp_min() >= dest->addr_timeout) {
> > +			acm_log(2, "Record expired\n");
> > +			acmp_remove_dest(ep, dest);
> > +			dest = NULL;
> > +		}
--
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

      parent reply	other threads:[~2016-09-19 13:21 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-09-19  7:46 [PATCH v1] ibacm: Handle EP expiration time Yuval Shaia
     [not found] ` <1474271168-22662-1-git-send-email-yuval.shaia-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org>
2016-09-19 11:22   ` Hal Rosenstock
     [not found]     ` <387b0fc4-949f-b8e2-6ac3-136e5ab2e127-LDSdmyG8hGV8YrgS2mwiifqBs+8SCbDb@public.gmane.org>
2016-09-19 13:21       ` Yuval Shaia [this message]

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=20160919132138.GA21320@yuval-lap.uk.oracle.com \
    --to=yuval.shaia-qhclzuegtsvqt0dzr+alfa@public.gmane.org \
    --cc=hal-LDSdmyG8hGV8YrgS2mwiifqBs+8SCbDb@public.gmane.org \
    --cc=linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=sean.hefty-ral2JQCrhuEAvxtiuMwx3w@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox