提交 c79c0666 编写于 作者: X Xin Long 提交者: David S. Miller

sctp: remove the local_bh_disable/enable in sctp_endpoint_lookup_assoc

sctp_endpoint_lookup_assoc is called in the protection of sock lock
there is no need to call local_bh_disable in this function. so remove
them.
Signed-off-by: NXin Long <lucien.xin@gmail.com>
Signed-off-by: NMarcelo Ricardo Leitner <marcelo.leitner@gmail.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 b5eff712
...@@ -317,7 +317,7 @@ struct sctp_endpoint *sctp_endpoint_is_match(struct sctp_endpoint *ep, ...@@ -317,7 +317,7 @@ struct sctp_endpoint *sctp_endpoint_is_match(struct sctp_endpoint *ep,
* We lookup the transport from hashtable at first, then get association * We lookup the transport from hashtable at first, then get association
* through t->assoc. * through t->assoc.
*/ */
static struct sctp_association *__sctp_endpoint_lookup_assoc( struct sctp_association *sctp_endpoint_lookup_assoc(
const struct sctp_endpoint *ep, const struct sctp_endpoint *ep,
const union sctp_addr *paddr, const union sctp_addr *paddr,
struct sctp_transport **transport) struct sctp_transport **transport)
...@@ -342,21 +342,6 @@ static struct sctp_association *__sctp_endpoint_lookup_assoc( ...@@ -342,21 +342,6 @@ static struct sctp_association *__sctp_endpoint_lookup_assoc(
return asoc; return asoc;
} }
/* Lookup association on an endpoint based on a peer address. BH-safe. */
struct sctp_association *sctp_endpoint_lookup_assoc(
const struct sctp_endpoint *ep,
const union sctp_addr *paddr,
struct sctp_transport **transport)
{
struct sctp_association *asoc;
local_bh_disable();
asoc = __sctp_endpoint_lookup_assoc(ep, paddr, transport);
local_bh_enable();
return asoc;
}
/* Look for any peeled off association from the endpoint that matches the /* Look for any peeled off association from the endpoint that matches the
* given peer address. * given peer address.
*/ */
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册