From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-it0-f72.google.com (mail-it0-f72.google.com [209.85.214.72]) by kanga.kvack.org (Postfix) with ESMTP id 9A8AB6B0038 for ; Tue, 3 Oct 2017 19:48:33 -0400 (EDT) Received: by mail-it0-f72.google.com with SMTP id v140so8755277ita.3 for ; Tue, 03 Oct 2017 16:48:33 -0700 (PDT) Received: from mail-sor-f65.google.com (mail-sor-f65.google.com. [209.85.220.65]) by mx.google.com with SMTPS id w132sor6113888itf.60.2017.10.03.16.48.32 for (Google Transport Security); Tue, 03 Oct 2017 16:48:32 -0700 (PDT) Date: Tue, 3 Oct 2017 18:48:28 -0500 From: Dennis Zhou Subject: Re: [PATCH] mm/percpu.c: use smarter memory allocation for struct pcpu_alloc_info Message-ID: <20171003234801.GA1571@Big-Sky.local> References: <20171003210540.GM3301751@devbig577.frc2.facebook.com> <20171003223642.GN3301751@devbig577.frc2.facebook.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20171003223642.GN3301751@devbig577.frc2.facebook.com> Sender: owner-linux-mm@kvack.org List-ID: To: Tejun Heo Cc: Nicolas Pitre , Christoph Lameter , linux-mm@kvack.org, linux-kernel@vger.kernel.org Hi Tejun, On Tue, Oct 03, 2017 at 03:36:42PM -0700, Tejun Heo wrote: > > Subject: [PATCH] percpu: don't forget to free the temporary struct pcpu_alloc_info > > So, IIRC, the error path is either boot fail or some serious bug in > arch code. It really doesn't matter whether we free a page or not. > In setup_per_cpu_area, a call to either pcpu_embed_first_chunk, pcpu_page_first_chunk, or pcpu_setup_first_chunk is made. The first two eventually call pcpu_setup_first_chunk with a pairing call to pcpu_free_alloc_info right after. This occurs in all implementations. It happens we don't have a pairing call to pcpu_free_alloc_info in the UP setup_per_cpu_area. Thanks, Dennis -- 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/ . Don't email: email@kvack.org