From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753067Ab3AYV1j (ORCPT ); Fri, 25 Jan 2013 16:27:39 -0500 Received: from mx1.redhat.com ([209.132.183.28]:12131 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751878Ab3AYV1h (ORCPT ); Fri, 25 Jan 2013 16:27:37 -0500 Message-ID: <5102F88F.5010303@redhat.com> Date: Fri, 25 Jan 2013 16:26:39 -0500 From: Rik van Riel User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/17.0 Thunderbird/17.0 MIME-Version: 1.0 To: Seth Jennings CC: Greg Kroah-Hartman , Andrew Morton , Nitin Gupta , Minchan Kim , Konrad Rzeszutek Wilk , Dan Magenheimer , Robert Jennings , Jenifer Hopper , Mel Gorman , Johannes Weiner , Larry Woodman , linux-mm@kvack.org, linux-kernel@vger.kernel.org, devel@driverdev.osuosl.org Subject: Re: [PATCHv2 1/9] staging: zsmalloc: add gfp flags to zs_create_pool References: <1357590280-31535-1-git-send-email-sjenning@linux.vnet.ibm.com> <1357590280-31535-2-git-send-email-sjenning@linux.vnet.ibm.com> In-Reply-To: <1357590280-31535-2-git-send-email-sjenning@linux.vnet.ibm.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 01/07/2013 03:24 PM, Seth Jennings wrote: > zs_create_pool() currently takes a gfp flags argument > that is used when growing the memory pool. However > it is not used in allocating the metadata for the pool > itself. That is currently hardcoded to GFP_KERNEL. > > zswap calls zs_create_pool() at swapon time which is done > in atomic context, resulting in a "might sleep" warning. > > This patch changes the meaning of the flags argument in > zs_create_pool() to mean the flags for the metadata allocation, > and adds a flags argument to zs_malloc that will be used for > memory pool growth if required. > > Signed-off-by: Seth Jennings Acked-by: Rik van Riel -- All rights reversed