Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757395AbcJNA7R (ORCPT ); Thu, 13 Oct 2016 20:59:17 -0400 Received: from sender153-mail.zoho.com ([74.201.84.153]:25371 "EHLO sender153-mail.zoho.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755218AbcJNA7J (ORCPT ); Thu, 13 Oct 2016 20:59:09 -0400 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=zapps768; d=zoho.com; h=subject:to:references:cc:from:message-id:date:user-agent:mime-version:in-reply-to:content-type; b=pR3HfQjTPPFoU0URHsSBtAt+edk8daPFhTQ3X7/uc2IV4iuNbcVNU1MqPzQwH+JqV0dJ0d+pE6J5 ZwR4StIwI4vziqzELxL5XxkwwPLTnEUYBT5YRkb94P3H+jE08kuD Subject: Re: [RFC PATCH 1/1] mm/percpu.c: fix memory leakage issue when allocate a odd alignment area To: Tejun Heo References: <20161013233139.GE32534@mtj.duckdns.org> <20161014002843.GH32534@mtj.duckdns.org> Cc: zijun_hu@htc.com, linux-mm@kvack.org, linux-kernel@vger.kernel.org From: zijun_hu Message-ID: <330464cd-a7d4-f1e1-da93-a6fd172ee561@zoho.com> Date: Fri, 14 Oct 2016 08:58:53 +0800 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.4.0 MIME-Version: 1.0 In-Reply-To: <20161014002843.GH32534@mtj.duckdns.org> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 385 Lines: 14 On 2016/10/14 8:28, Tejun Heo wrote: > Hello, > > On Fri, Oct 14, 2016 at 08:23:06AM +0800, zijun_hu wrote: >> for the current code, only power of 2 alignment value can works well >> >> is it acceptable to performing a power of 2 checking and returning error code >> if fail? > > Yeah, just add is_power_of_2() test to the existing sanity check. > > Thanks. > okay. i will do that