Netdev List
 help / color / mirror / Atom feed
From: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com>
To: David Miller <davem@davemloft.net>
Cc: netdev@vger.kernel.org, lucien.xin@gmail.com, nhorman@tuxdriver.com
Subject: Re: [PATCH v5 3/5] sctp: Use helper for sctp_ulpq_tail_event() when hooked up to ->enqueue_event
Date: Thu, 11 Apr 2019 19:18:11 -0300	[thread overview]
Message-ID: <20190411221811.GO10452@localhost.localdomain> (raw)
In-Reply-To: <20190411.150201.46148653005422499.davem@davemloft.net>

On Thu, Apr 11, 2019 at 03:02:01PM -0700, David Miller wrote:
> 
> This way we can make sure events sent this way to
> sctp_ulpq_tail_event() are on a list as well.  Now all such code paths
> are fully covered.
> 
> Signed-off-by: David S. Miller <davem@davemloft.net>

Acked-by: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com>

> ---
>  net/sctp/stream_interleave.c | 11 ++++++++++-
>  1 file changed, 10 insertions(+), 1 deletion(-)
> 
> diff --git a/net/sctp/stream_interleave.c b/net/sctp/stream_interleave.c
> index 102c6fefe38c..a6bc42121e35 100644
> --- a/net/sctp/stream_interleave.c
> +++ b/net/sctp/stream_interleave.c
> @@ -1298,6 +1298,15 @@ static void sctp_handle_iftsn(struct sctp_ulpq *ulpq, struct sctp_chunk *chunk)
>  			       ntohl(skip->mid), skip->flags);
>  }
>  
> +static int do_ulpq_tail_event(struct sctp_ulpq *ulpq, struct sctp_ulpevent *event)
> +{
> +	struct sk_buff_head temp;
> +
> +	skb_queue_head_init(&temp);
> +	__skb_queue_tail(&temp, sctp_event2skb(event));
> +	return sctp_ulpq_tail_event(ulpq, event);
> +}
> +
>  static struct sctp_stream_interleave sctp_stream_interleave_0 = {
>  	.data_chunk_len		= sizeof(struct sctp_data_chunk),
>  	.ftsn_chunk_len		= sizeof(struct sctp_fwdtsn_chunk),
> @@ -1306,7 +1315,7 @@ static struct sctp_stream_interleave sctp_stream_interleave_0 = {
>  	.assign_number		= sctp_chunk_assign_ssn,
>  	.validate_data		= sctp_validate_data,
>  	.ulpevent_data		= sctp_ulpq_tail_data,
> -	.enqueue_event		= sctp_ulpq_tail_event,
> +	.enqueue_event		= do_ulpq_tail_event,
>  	.renege_events		= sctp_ulpq_renege,
>  	.start_pd		= sctp_ulpq_partial_delivery,
>  	.abort_pd		= sctp_ulpq_abort_pd,
> -- 
> 2.20.1
> 

  reply	other threads:[~2019-04-11 22:18 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-04-11 22:02 [PATCH v5 3/5] sctp: Use helper for sctp_ulpq_tail_event() when hooked up to ->enqueue_event David Miller
2019-04-11 22:18 ` Marcelo Ricardo Leitner [this message]
  -- strict thread matches above, loose matches on Subject: below --
2019-04-10 21:20 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=20190411221811.GO10452@localhost.localdomain \
    --to=marcelo.leitner@gmail.com \
    --cc=davem@davemloft.net \
    --cc=lucien.xin@gmail.com \
    --cc=netdev@vger.kernel.org \
    --cc=nhorman@tuxdriver.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox