All of lore.kernel.org
 help / color / mirror / Atom feed
From: Yanjun Zhu <yanjun.zhu-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org>
To: Sowmini Varadhan
	<sowmini.varadhan-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org>
Cc: santosh.shilimkar-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org,
	netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	rds-devel-N0ozoZBvEnrZJqsBc5GL+g@public.gmane.org,
	junxiao.bi-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org,
	joe.jin-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org
Subject: Re: [PATCH 1/5] rds: tcp: release the created connection
Date: Mon, 27 Mar 2017 16:05:45 +0800	[thread overview]
Message-ID: <58D8C7D9.1070509@oracle.com> (raw)
In-Reply-To: <20170327073756.GA21982-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org>



On 2017/3/27 15:37, Sowmini Varadhan wrote:
> On (03/27/17 03:06), Zhu Yanjun wrote:
>> Date: Mon, 27 Mar 2017 03:06:26 -0400
>> From: Zhu Yanjun <yanjun.zhu-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org>
>> To: yanjun.zhu-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org, santosh.shilimkar-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org,
>>   netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
>>   rds-devel-N0ozoZBvEnrZJqsBc5GL+g@public.gmane.org, junxiao.bi-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org, joe.jin-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org
>> Subject: [PATCH 1/5] rds: tcp: release the created connection
>> X-Mailer: git-send-email 2.7.4
>>
>> When some error occurs, the created connection should be destroyed.
> No please dont do this.
>
> This is the case when there are duelling connections. We want
> to reset the new (accept sock) and leave the old socket in place.
>
> How did you test this? Did you test it with network namespaces?
Sorry. I just made simple test. It seems that it worked well. Would you 
like to show me some test about this patch?

Thanks a lot.
Zhu Yanjun
>
> --Sowmini
>
>
>>   net/rds/tcp_listen.c | 1 +
>>
>> diff --git a/net/rds/tcp_listen.c b/net/rds/tcp_listen.c
>> index 5076788..58aa5bc 100644
>> --- a/net/rds/tcp_listen.c
>> +++ b/net/rds/tcp_listen.c
>> @@ -196,6 +196,7 @@ int rds_tcp_accept_one(struct socket *sock)
>>   rst_nsk:
>>   	/* reset the newly returned accept sock and bail */
>>   	kernel_sock_shutdown(new_sock, SHUT_RDWR);
>> +	rds_conn_destroy(conn);
>>   	ret = 0;
>>   out:
>>   	if (rs_tcp)
>> -- 
>> 2.7.4
>>
> --
> 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

--
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:[~2017-03-27  8:05 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-03-27  7:06 [PATCH 0/5] rds: trivial patches Zhu Yanjun
2017-03-27  7:06 ` [PATCH 2/5] rds: rdma: fix memory leak error Zhu Yanjun
     [not found] ` <1490598390-13812-1-git-send-email-yanjun.zhu-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org>
2017-03-27  7:06   ` [PATCH 1/5] rds: tcp: release the created connection Zhu Yanjun
2017-03-27  7:37     ` Sowmini Varadhan
     [not found]       ` <20170327073756.GA21982-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org>
2017-03-27  8:05         ` Yanjun Zhu [this message]
2017-03-27  9:17           ` Sowmini Varadhan
2017-03-27  7:06   ` [PATCH 3/5] rds: remove unnecessary returned value check Zhu Yanjun
2017-03-27  7:06   ` [PATCH 5/5] rds: ib: add the static type to the functions Zhu Yanjun
2017-03-27  7:06 ` [PATCH 4/5] rds: remove the unused variable Zhu Yanjun

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=58D8C7D9.1070509@oracle.com \
    --to=yanjun.zhu-qhclzuegtsvqt0dzr+alfa@public.gmane.org \
    --cc=joe.jin-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org \
    --cc=junxiao.bi-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org \
    --cc=linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=rds-devel-N0ozoZBvEnrZJqsBc5GL+g@public.gmane.org \
    --cc=santosh.shilimkar-QHcLZuEGTsvQT0dZR+AlfA@public.gmane.org \
    --cc=sowmini.varadhan-QHcLZuEGTsvQT0dZR+AlfA@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.