Re: [PATCH] Call echo service immediately after socket reconnect

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 2016-10-20 at 13:30 -0700, Pavel Shilovsky wrote:
> 2016-10-20 6:14 GMT-07:00 Sachin Prabhu <sprabhu@xxxxxxxxxx>:
> > 
> > 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
--
To unsubscribe from this list: send the line "unsubscribe linux-cifs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux