From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail6.bemta12.messagelabs.com (mail6.bemta12.messagelabs.com [216.82.250.247]) by kanga.kvack.org (Postfix) with ESMTP id 069F76B0022 for ; Sat, 28 May 2011 13:37:24 -0400 (EDT) From: Joe Perches Subject: [TRIVIAL PATCH next 14/15] mm: Convert vmalloc/memset to vzalloc Date: Sat, 28 May 2011 10:36:34 -0700 Message-Id: In-Reply-To: References: Sender: owner-linux-mm@kvack.org List-ID: To: Balbir Singh , Daisuke Nishimura , KAMEZAWA Hiroyuki , Paul Menage , Li Zefan , Jiri Kosina Cc: linux-mm@kvack.org, containers@lists.linux-foundation.org, linux-kernel@vger.kernel.org Signed-off-by: Joe Perches --- mm/page_cgroup.c | 3 +-- 1 files changed, 1 insertions(+), 2 deletions(-) diff --git a/mm/page_cgroup.c b/mm/page_cgroup.c index 74ccff6..dbb28fd 100644 --- a/mm/page_cgroup.c +++ b/mm/page_cgroup.c @@ -478,11 +478,10 @@ int swap_cgroup_swapon(int type, unsigned long max_pages) length = DIV_ROUND_UP(max_pages, SC_PER_PAGE); array_size = length * sizeof(void *); - array = vmalloc(array_size); + array = vzalloc(array_size); if (!array) goto nomem; - memset(array, 0, array_size); ctrl = &swap_cgroup_ctrl[type]; mutex_lock(&swap_cgroup_mutex); ctrl->length = length; -- 1.7.5.rc3.dirty -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@kvack.org. For more info on Linux MM, see: http://www.linux-mm.org/ . Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/ Don't email: email@kvack.org