From 77a6e853d7aee01b540216a0b950a06ba60771a7 Mon Sep 17 00:00:00 2001 From: Cong Wang Date: Sun, 3 Mar 2013 16:28:27 +0000 Subject: [PATCH] --- yaml --- r: 360823 b: refs/heads/master c: 3f736868b47687d1336fe88185560b22bb92021e h: refs/heads/master i: 360821: d061751089eb8f2b560bdd9f53d3edcc19719a49 360819: 0dfb99770c6b723e8f4c7fcf56ffcb0780d8ec4e 360815: 52377a28336c11f381d3365225a77c30517a0a1a v: v3 --- [refs] | 2 +- trunk/net/sctp/ssnmap.c | 8 +++----- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/[refs] b/[refs] index 504df2c33f05..f8c02f93f7ce 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: ece6b0a2b25652d684a7ced4ae680a863af041e0 +refs/heads/master: 3f736868b47687d1336fe88185560b22bb92021e diff --git a/trunk/net/sctp/ssnmap.c b/trunk/net/sctp/ssnmap.c index 442ad4ed6315..825ea94415b3 100644 --- a/trunk/net/sctp/ssnmap.c +++ b/trunk/net/sctp/ssnmap.c @@ -41,8 +41,6 @@ #include #include -#define MAX_KMALLOC_SIZE 131072 - static struct sctp_ssnmap *sctp_ssnmap_init(struct sctp_ssnmap *map, __u16 in, __u16 out); @@ -65,7 +63,7 @@ struct sctp_ssnmap *sctp_ssnmap_new(__u16 in, __u16 out, int size; size = sctp_ssnmap_size(in, out); - if (size <= MAX_KMALLOC_SIZE) + if (size <= KMALLOC_MAX_SIZE) retval = kmalloc(size, gfp); else retval = (struct sctp_ssnmap *) @@ -82,7 +80,7 @@ struct sctp_ssnmap *sctp_ssnmap_new(__u16 in, __u16 out, return retval; fail_map: - if (size <= MAX_KMALLOC_SIZE) + if (size <= KMALLOC_MAX_SIZE) kfree(retval); else free_pages((unsigned long)retval, get_order(size)); @@ -124,7 +122,7 @@ void sctp_ssnmap_free(struct sctp_ssnmap *map) int size; size = sctp_ssnmap_size(map->in.len, map->out.len); - if (size <= MAX_KMALLOC_SIZE) + if (size <= KMALLOC_MAX_SIZE) kfree(map); else free_pages((unsigned long)map, get_order(size));