[PATCH] gfp flags annotations - part 1
[deliverable/linux.git] / net / sctp / endpointola.c
index e47ac0d1a6d64f679bf963113b1989d93e4d4c44..96984f7a2d697ca0e847f6ab9af3443dacc66389 100644 (file)
@@ -68,7 +68,7 @@ static void sctp_endpoint_bh_rcv(struct sctp_endpoint *ep);
  */
 static struct sctp_endpoint *sctp_endpoint_init(struct sctp_endpoint *ep,
                                                struct sock *sk,
-                                               unsigned int __nocast gfp)
+                                               gfp_t gfp)
 {
        struct sctp_sock *sp = sctp_sk(sk);
        memset(ep, 0, sizeof(struct sctp_endpoint));
@@ -138,8 +138,7 @@ static struct sctp_endpoint *sctp_endpoint_init(struct sctp_endpoint *ep,
 /* Create a sctp_endpoint with all that boring stuff initialized.
  * Returns NULL if there isn't enough memory.
  */
-struct sctp_endpoint *sctp_endpoint_new(struct sock *sk,
-                                       unsigned int __nocast gfp)
+struct sctp_endpoint *sctp_endpoint_new(struct sock *sk, gfp_t gfp)
 {
        struct sctp_endpoint *ep;
 
@@ -193,8 +192,7 @@ static void sctp_endpoint_destroy(struct sctp_endpoint *ep)
        sctp_unhash_endpoint(ep);
 
        /* Free up the HMAC transform. */
-       if (sctp_sk(ep->base.sk)->hmac)
-               sctp_crypto_free_tfm(sctp_sk(ep->base.sk)->hmac);
+       sctp_crypto_free_tfm(sctp_sk(ep->base.sk)->hmac);
 
        /* Cleanup. */
        sctp_inq_free(&ep->base.inqueue);
This page took 0.036707 seconds and 5 git commands to generate.