All of lore.kernel.org
 help / color / mirror / Atom feed
From: Wang Weidong <wangweidong1@huawei.com>
To: Daniel Borkmann <dborkman@redhat.com>
Cc: David Miller <davem@davemloft.net>,
	Neil Horman <nhorman@tuxdriver.com>,
	Vlad Yasevich <vyasevich@gmail.com>,
	Michael Tuexen <Michael.Tuexen@lurchi.franken.de>,
	linux-sctp@vger.kernel.org, netdev@vger.kernel.org,
	dingtianhong@huawei.com
Subject: Re: [PATCH] sctp: disable max_burst when the max_burst is 0
Date: Wed, 04 Dec 2013 09:16:16 +0000	[thread overview]
Message-ID: <529EF2E0.7080606@huawei.com> (raw)
In-Reply-To: <529EEE70.7090801@redhat.com>

On 2013/12/4 16:57, Daniel Borkmann wrote:
> On 12/03/2013 07:30 AM, Wang Weidong wrote:
>> As Michael pointed out that when max_burst is 0, it just disable
>> max_burst. It declared in rfc6458#section-8.1.24. so add the check
>> in sctp_transport_burst_limited, when it 0, just do nothing.
>>
>> Suggested-by: Vlad Yasevich <vyasevich@gmail.com>
>> Suggested-by: Michael Tuexen <Michael.Tuexen@lurchi.franken.de>
>> Signed-off-by: Wang Weidong <wangweidong1@huawei.com>
>> ---
>>   net/sctp/transport.c | 3 ++-
>>   1 file changed, 2 insertions(+), 1 deletion(-)
>>
>> diff --git a/net/sctp/transport.c b/net/sctp/transport.c
>> index e332efb..e580e34 100644
>> --- a/net/sctp/transport.c
>> +++ b/net/sctp/transport.c
>> @@ -573,7 +573,8 @@ void sctp_transport_burst_limited(struct sctp_transport *t)
>>       u32 old_cwnd = t->cwnd;
>>       u32 max_burst_bytes;
>>
>> -    if (t->burst_limited)
>> +    /* if the max_burst is 0, do notihing */
>> +    if (t->burst_limited || !asoc->max_burst)
>>           return;
> 
> Minor nitpick ... you can remove the comment as it contains a typo and
> basically says what the code is doing anyway, so you could instead make
> the code a bit more clear for readers e.g. "asoc->max_burst = 0".
> 
Nice, Thanks for pointing it out for me. I will fix it in v2.

Regards.

>>       max_burst_bytes = t->flight_size + (asoc->max_burst * asoc->pathmtu);
>>
> 
> .
> 



WARNING: multiple messages have this Message-ID (diff)
From: Wang Weidong <wangweidong1@huawei.com>
To: Daniel Borkmann <dborkman@redhat.com>
Cc: David Miller <davem@davemloft.net>,
	Neil Horman <nhorman@tuxdriver.com>,
	Vlad Yasevich <vyasevich@gmail.com>,
	Michael Tuexen <Michael.Tuexen@lurchi.franken.de>,
	<linux-sctp@vger.kernel.org>, <netdev@vger.kernel.org>,
	<dingtianhong@huawei.com>
Subject: Re: [PATCH] sctp: disable max_burst when the max_burst is 0
Date: Wed, 4 Dec 2013 17:16:16 +0800	[thread overview]
Message-ID: <529EF2E0.7080606@huawei.com> (raw)
In-Reply-To: <529EEE70.7090801@redhat.com>

On 2013/12/4 16:57, Daniel Borkmann wrote:
> On 12/03/2013 07:30 AM, Wang Weidong wrote:
>> As Michael pointed out that when max_burst is 0, it just disable
>> max_burst. It declared in rfc6458#section-8.1.24. so add the check
>> in sctp_transport_burst_limited, when it 0, just do nothing.
>>
>> Suggested-by: Vlad Yasevich <vyasevich@gmail.com>
>> Suggested-by: Michael Tuexen <Michael.Tuexen@lurchi.franken.de>
>> Signed-off-by: Wang Weidong <wangweidong1@huawei.com>
>> ---
>>   net/sctp/transport.c | 3 ++-
>>   1 file changed, 2 insertions(+), 1 deletion(-)
>>
>> diff --git a/net/sctp/transport.c b/net/sctp/transport.c
>> index e332efb..e580e34 100644
>> --- a/net/sctp/transport.c
>> +++ b/net/sctp/transport.c
>> @@ -573,7 +573,8 @@ void sctp_transport_burst_limited(struct sctp_transport *t)
>>       u32 old_cwnd = t->cwnd;
>>       u32 max_burst_bytes;
>>
>> -    if (t->burst_limited)
>> +    /* if the max_burst is 0, do notihing */
>> +    if (t->burst_limited || !asoc->max_burst)
>>           return;
> 
> Minor nitpick ... you can remove the comment as it contains a typo and
> basically says what the code is doing anyway, so you could instead make
> the code a bit more clear for readers e.g. "asoc->max_burst == 0".
> 
Nice, Thanks for pointing it out for me. I will fix it in v2.

Regards.

>>       max_burst_bytes = t->flight_size + (asoc->max_burst * asoc->pathmtu);
>>
> 
> .
> 

  reply	other threads:[~2013-12-04  9:16 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-12-02  6:51 [PATCH] sctp: make the max_burst min value to 1 Wang Weidong
2013-12-02  6:51 ` Wang Weidong
2013-12-02 11:56 ` Neil Horman
2013-12-02 11:56   ` Neil Horman
2013-12-02 12:03   ` Wang Weidong
2013-12-02 12:03     ` Wang Weidong
2013-12-02 14:51     ` Vlad Yasevich
2013-12-02 14:51       ` Vlad Yasevich
2013-12-03  1:35       ` Wang Weidong
2013-12-03  1:35         ` Wang Weidong
2013-12-02 13:08   ` Michael Tuexen
2013-12-02 13:08     ` Michael Tuexen
2013-12-03  6:30     ` [PATCH] sctp: disable max_burst when the max_burst is 0 Wang Weidong
2013-12-03  6:30       ` Wang Weidong
2013-12-04  8:57       ` Daniel Borkmann
2013-12-04  8:57         ` Daniel Borkmann
2013-12-04  9:16         ` Wang Weidong [this message]
2013-12-04  9:16           ` Wang Weidong
2013-12-04  9:32 ` [PATCH v2] " Wang Weidong
2013-12-04  9:32   ` Wang Weidong
2013-12-04 11:45   ` Neil Horman
2013-12-04 11:45     ` Neil Horman
2013-12-04 14:28   ` Vlad Yasevich
2013-12-04 14:28     ` Vlad Yasevich
2013-12-06  1:56   ` David Miller
2013-12-06  1:56     ` David Miller

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=529EF2E0.7080606@huawei.com \
    --to=wangweidong1@huawei.com \
    --cc=Michael.Tuexen@lurchi.franken.de \
    --cc=davem@davemloft.net \
    --cc=dborkman@redhat.com \
    --cc=dingtianhong@huawei.com \
    --cc=linux-sctp@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=nhorman@tuxdriver.com \
    --cc=vyasevich@gmail.com \
    /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.