All of lore.kernel.org
 help / color / mirror / Atom feed
From: Sachin Prabhu <sprabhu-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
To: Pavel Shilovsky <piastryyy-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
Cc: linux-cifs <linux-cifs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>
Subject: Re: [PATCH] Call echo service immediately after socket reconnect
Date: Thu, 20 Oct 2016 19:55:50 -0400	[thread overview]
Message-ID: <1477007750.4752.3.camel@redhat.com> (raw)
In-Reply-To: <CAKywueQ=L5MunfYLGJ6NqBUq5fLbLuM5A7f93Kym+u7sqdm0OQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>

On Thu, 2016-10-20 at 13:30 -0700, Pavel Shilovsky wrote:
> 2016-10-20 6:14 GMT-07:00 Sachin Prabhu <sprabhu-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>:
> > 
> > Commit 4fcd1813e640 ("Fix reconnect to not defer smb3 session
> > reconnect
> > long after socket reconnect") changes the behaviour of the SMB2
> > echo
> > service and causes it to renegotiate after a socket reconnect.
> > However
> > under default settings, the echo service could take up to 120
> > seconds to
> > be scheduled.
> > 
> > The patch forces the echo service to be called immediately
> > resulting a
> > negotiate call being made immediately on reconnect.
> 
> Looks like a right thing to do. Comments are inlined below:
> 
> > 
> > ..
> > +       if (server->tcpStatus == CifsNeedNegotiate)
> > +               echo_interval = 0;
> 
> Suppose we are setting echo_interval to 0 above
> 
> > 
> > 
..
> then we are sending an echo message and re-queue the echo work with
> echo_interval==0:
> 
> rc = server->ops->echo ? server->ops->echo(server) : -ENOSYS;
> ....
> queue_delayed_work(cifsiod_wq, &server->echo, echo_interval);
> 
> Shouldn't we queue the echo work with server->echo_interval (not 0)
> here?
> 

Hello Pavel,

Yes, you are right. I had overlooked the second echo_interval in the
function. I've sent a version 2 of the patch.

Sachin Prabhu

  parent reply	other threads:[~2016-10-20 23:55 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-10-20 13:14 [PATCH] Call echo service immediately after socket reconnect Sachin Prabhu
     [not found] ` <1476969267-22325-1-git-send-email-sprabhu-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2016-10-20 20:30   ` Pavel Shilovsky
     [not found]     ` <CAKywueQ=L5MunfYLGJ6NqBUq5fLbLuM5A7f93Kym+u7sqdm0OQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2016-10-20 23:55       ` Sachin Prabhu [this message]
  -- strict thread matches above, loose matches on Subject: below --
2017-05-25 16:46 Pavel Shilovsky
2017-06-05 19:15 Pavel Shilovsky
2017-06-12 12:30 ` Greg KH
2017-06-12 19:08   ` Pavel Shilovskiy
2017-06-12 19:16     ` Greg KH
2017-06-12 19:44       ` Pavel Shilovskiy

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=1477007750.4752.3.camel@redhat.com \
    --to=sprabhu-h+wxahxf7alqt0dzr+alfa@public.gmane.org \
    --cc=linux-cifs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=piastryyy-Re5JQEeQqe8AvxtiuMwx3w@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.