Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755785AbZFBPFx (ORCPT ); Tue, 2 Jun 2009 11:05:53 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1755441AbZFBPFm (ORCPT ); Tue, 2 Jun 2009 11:05:42 -0400 Received: from smtp3.ultrahosting.com ([74.213.175.254]:40486 "EHLO smtp.ultrahosting.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1755231AbZFBPFl (ORCPT ); Tue, 2 Jun 2009 11:05:41 -0400 Date: Tue, 2 Jun 2009 11:05:09 -0400 (EDT) From: Christoph Lameter X-X-Sender: cl@gentwo.org To: Linus Torvalds cc: Alan Cox , Pekka Enberg , "Larry H." , linux-kernel@vger.kernel.org, linux-mm@kvack.org, Rik van Riel Subject: Re: [PATCH] Use kzfree in tty buffer management to enforce data sanitization In-Reply-To: Message-ID: References: <20090531015537.GA8941@oblivion.subreption.com> <84144f020905302324r5e342f2dlfd711241ecfc8374@mail.gmail.com> <20090531112630.2c7f4f1d@lxorguk.ukuu.org.uk> User-Agent: Alpine 1.10 (DEB 962 2008-03-14) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 916 Lines: 19 On Sun, 31 May 2009, Linus Torvalds wrote: > I suspect the "use page allocator" is historical - ie the tty layer > originally always did that, and then when people wanted to suppotr smaller > areas than one page, they added the special case. I have this dim memory > of the _original_ kmalloc not handling page-sized allocations well (due to > embedded size/pointer overheads), but I think all current allocators are > perfectly happy to allocate PAGE_SIZE buffers without slop. > > If I'm right, then we could just use kmalloc/kfree unconditionally. Pekka? Yes. They do that in various ways. SLOB/SLUB will fall back to the page allocator for large allocation sizes. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/