* [PATCH net-next] sctp: remove the unused sctp_assoc_is_match function
@ 2018-04-25 9:46 Xin Long
2018-04-25 11:49 ` Neil Horman
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: Xin Long @ 2018-04-25 9:46 UTC (permalink / raw)
To: network dev, linux-sctp; +Cc: Marcelo Ricardo Leitner, Neil Horman, davem
After Commit 4f0087812648 ("sctp: apply rhashtable api to send/recv
path"), there's no place using sctp_assoc_is_match, so remove it.
Signed-off-by: Xin Long <lucien.xin@gmail.com>
---
include/net/sctp/structs.h | 4 ----
net/sctp/associola.c | 25 -------------------------
2 files changed, 29 deletions(-)
diff --git a/include/net/sctp/structs.h b/include/net/sctp/structs.h
index a0ec462..05594b2 100644
--- a/include/net/sctp/structs.h
+++ b/include/net/sctp/structs.h
@@ -2091,10 +2091,6 @@ void sctp_assoc_control_transport(struct sctp_association *asoc,
enum sctp_transport_cmd command,
sctp_sn_error_t error);
struct sctp_transport *sctp_assoc_lookup_tsn(struct sctp_association *, __u32);
-struct sctp_transport *sctp_assoc_is_match(struct sctp_association *,
- struct net *,
- const union sctp_addr *,
- const union sctp_addr *);
void sctp_assoc_migrate(struct sctp_association *, struct sock *);
int sctp_assoc_update(struct sctp_association *old,
struct sctp_association *new);
diff --git a/net/sctp/associola.c b/net/sctp/associola.c
index 837806d..a8f3b08 100644
--- a/net/sctp/associola.c
+++ b/net/sctp/associola.c
@@ -988,31 +988,6 @@ struct sctp_transport *sctp_assoc_lookup_tsn(struct sctp_association *asoc,
return match;
}
-/* Is this the association we are looking for? */
-struct sctp_transport *sctp_assoc_is_match(struct sctp_association *asoc,
- struct net *net,
- const union sctp_addr *laddr,
- const union sctp_addr *paddr)
-{
- struct sctp_transport *transport;
-
- if ((htons(asoc->base.bind_addr.port) == laddr->v4.sin_port) &&
- (htons(asoc->peer.port) == paddr->v4.sin_port) &&
- net_eq(sock_net(asoc->base.sk), net)) {
- transport = sctp_assoc_lookup_paddr(asoc, paddr);
- if (!transport)
- goto out;
-
- if (sctp_bind_addr_match(&asoc->base.bind_addr, laddr,
- sctp_sk(asoc->base.sk)))
- goto out;
- }
- transport = NULL;
-
-out:
- return transport;
-}
-
/* Do delayed input processing. This is scheduled by sctp_rcv(). */
static void sctp_assoc_bh_rcv(struct work_struct *work)
{
--
2.1.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH net-next] sctp: remove the unused sctp_assoc_is_match function
2018-04-25 9:46 [PATCH net-next] sctp: remove the unused sctp_assoc_is_match function Xin Long
@ 2018-04-25 11:49 ` Neil Horman
2018-04-25 13:41 ` Marcelo Ricardo Leitner
2018-04-25 18:12 ` David Miller
2 siblings, 0 replies; 4+ messages in thread
From: Neil Horman @ 2018-04-25 11:49 UTC (permalink / raw)
To: Xin Long; +Cc: network dev, linux-sctp, Marcelo Ricardo Leitner, davem
On Wed, Apr 25, 2018 at 05:46:47PM +0800, Xin Long wrote:
> After Commit 4f0087812648 ("sctp: apply rhashtable api to send/recv
> path"), there's no place using sctp_assoc_is_match, so remove it.
>
> Signed-off-by: Xin Long <lucien.xin@gmail.com>
> ---
> include/net/sctp/structs.h | 4 ----
> net/sctp/associola.c | 25 -------------------------
> 2 files changed, 29 deletions(-)
>
> diff --git a/include/net/sctp/structs.h b/include/net/sctp/structs.h
> index a0ec462..05594b2 100644
> --- a/include/net/sctp/structs.h
> +++ b/include/net/sctp/structs.h
> @@ -2091,10 +2091,6 @@ void sctp_assoc_control_transport(struct sctp_association *asoc,
> enum sctp_transport_cmd command,
> sctp_sn_error_t error);
> struct sctp_transport *sctp_assoc_lookup_tsn(struct sctp_association *, __u32);
> -struct sctp_transport *sctp_assoc_is_match(struct sctp_association *,
> - struct net *,
> - const union sctp_addr *,
> - const union sctp_addr *);
> void sctp_assoc_migrate(struct sctp_association *, struct sock *);
> int sctp_assoc_update(struct sctp_association *old,
> struct sctp_association *new);
> diff --git a/net/sctp/associola.c b/net/sctp/associola.c
> index 837806d..a8f3b08 100644
> --- a/net/sctp/associola.c
> +++ b/net/sctp/associola.c
> @@ -988,31 +988,6 @@ struct sctp_transport *sctp_assoc_lookup_tsn(struct sctp_association *asoc,
> return match;
> }
>
> -/* Is this the association we are looking for? */
> -struct sctp_transport *sctp_assoc_is_match(struct sctp_association *asoc,
> - struct net *net,
> - const union sctp_addr *laddr,
> - const union sctp_addr *paddr)
> -{
> - struct sctp_transport *transport;
> -
> - if ((htons(asoc->base.bind_addr.port) == laddr->v4.sin_port) &&
> - (htons(asoc->peer.port) == paddr->v4.sin_port) &&
> - net_eq(sock_net(asoc->base.sk), net)) {
> - transport = sctp_assoc_lookup_paddr(asoc, paddr);
> - if (!transport)
> - goto out;
> -
> - if (sctp_bind_addr_match(&asoc->base.bind_addr, laddr,
> - sctp_sk(asoc->base.sk)))
> - goto out;
> - }
> - transport = NULL;
> -
> -out:
> - return transport;
> -}
> -
> /* Do delayed input processing. This is scheduled by sctp_rcv(). */
> static void sctp_assoc_bh_rcv(struct work_struct *work)
> {
> --
> 2.1.0
>
>
Acked-by: Neil Horman <nhorman@tuxdriver.com>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH net-next] sctp: remove the unused sctp_assoc_is_match function
2018-04-25 9:46 [PATCH net-next] sctp: remove the unused sctp_assoc_is_match function Xin Long
2018-04-25 11:49 ` Neil Horman
@ 2018-04-25 13:41 ` Marcelo Ricardo Leitner
2018-04-25 18:12 ` David Miller
2 siblings, 0 replies; 4+ messages in thread
From: Marcelo Ricardo Leitner @ 2018-04-25 13:41 UTC (permalink / raw)
To: Xin Long; +Cc: network dev, linux-sctp, Neil Horman, davem
On Wed, Apr 25, 2018 at 05:46:47PM +0800, Xin Long wrote:
> After Commit 4f0087812648 ("sctp: apply rhashtable api to send/recv
> path"), there's no place using sctp_assoc_is_match, so remove it.
>
> Signed-off-by: Xin Long <lucien.xin@gmail.com>
Acked-by: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com>
> ---
> include/net/sctp/structs.h | 4 ----
> net/sctp/associola.c | 25 -------------------------
> 2 files changed, 29 deletions(-)
>
> diff --git a/include/net/sctp/structs.h b/include/net/sctp/structs.h
> index a0ec462..05594b2 100644
> --- a/include/net/sctp/structs.h
> +++ b/include/net/sctp/structs.h
> @@ -2091,10 +2091,6 @@ void sctp_assoc_control_transport(struct sctp_association *asoc,
> enum sctp_transport_cmd command,
> sctp_sn_error_t error);
> struct sctp_transport *sctp_assoc_lookup_tsn(struct sctp_association *, __u32);
> -struct sctp_transport *sctp_assoc_is_match(struct sctp_association *,
> - struct net *,
> - const union sctp_addr *,
> - const union sctp_addr *);
> void sctp_assoc_migrate(struct sctp_association *, struct sock *);
> int sctp_assoc_update(struct sctp_association *old,
> struct sctp_association *new);
> diff --git a/net/sctp/associola.c b/net/sctp/associola.c
> index 837806d..a8f3b08 100644
> --- a/net/sctp/associola.c
> +++ b/net/sctp/associola.c
> @@ -988,31 +988,6 @@ struct sctp_transport *sctp_assoc_lookup_tsn(struct sctp_association *asoc,
> return match;
> }
>
> -/* Is this the association we are looking for? */
> -struct sctp_transport *sctp_assoc_is_match(struct sctp_association *asoc,
> - struct net *net,
> - const union sctp_addr *laddr,
> - const union sctp_addr *paddr)
> -{
> - struct sctp_transport *transport;
> -
> - if ((htons(asoc->base.bind_addr.port) == laddr->v4.sin_port) &&
> - (htons(asoc->peer.port) == paddr->v4.sin_port) &&
> - net_eq(sock_net(asoc->base.sk), net)) {
> - transport = sctp_assoc_lookup_paddr(asoc, paddr);
> - if (!transport)
> - goto out;
> -
> - if (sctp_bind_addr_match(&asoc->base.bind_addr, laddr,
> - sctp_sk(asoc->base.sk)))
> - goto out;
> - }
> - transport = NULL;
> -
> -out:
> - return transport;
> -}
> -
> /* Do delayed input processing. This is scheduled by sctp_rcv(). */
> static void sctp_assoc_bh_rcv(struct work_struct *work)
> {
> --
> 2.1.0
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-sctp" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH net-next] sctp: remove the unused sctp_assoc_is_match function
2018-04-25 9:46 [PATCH net-next] sctp: remove the unused sctp_assoc_is_match function Xin Long
2018-04-25 11:49 ` Neil Horman
2018-04-25 13:41 ` Marcelo Ricardo Leitner
@ 2018-04-25 18:12 ` David Miller
2 siblings, 0 replies; 4+ messages in thread
From: David Miller @ 2018-04-25 18:12 UTC (permalink / raw)
To: lucien.xin; +Cc: netdev, linux-sctp, marcelo.leitner, nhorman
From: Xin Long <lucien.xin@gmail.com>
Date: Wed, 25 Apr 2018 17:46:47 +0800
> After Commit 4f0087812648 ("sctp: apply rhashtable api to send/recv
> path"), there's no place using sctp_assoc_is_match, so remove it.
>
> Signed-off-by: Xin Long <lucien.xin@gmail.com>
Applied.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2018-04-25 18:12 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-04-25 9:46 [PATCH net-next] sctp: remove the unused sctp_assoc_is_match function Xin Long
2018-04-25 11:49 ` Neil Horman
2018-04-25 13:41 ` Marcelo Ricardo Leitner
2018-04-25 18:12 ` David Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).