From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-it1-f199.google.com (mail-it1-f199.google.com [209.85.166.199]) by kanga.kvack.org (Postfix) with ESMTP id 202FD6B000A for ; Thu, 4 Oct 2018 23:26:19 -0400 (EDT) Received: by mail-it1-f199.google.com with SMTP id w132-v6so774260ita.6 for ; Thu, 04 Oct 2018 20:26:19 -0700 (PDT) Received: from gate.crashing.org (gate.crashing.org. [63.228.1.57]) by mx.google.com with ESMTPS id j207-v6si550506ita.80.2018.10.04.20.26.17 for (version=TLS1 cipher=AES128-SHA bits=128/128); Thu, 04 Oct 2018 20:26:18 -0700 (PDT) Message-ID: <8891277c7de92e93d3bfc409df95810ee6f103cd.camel@kernel.crashing.org> Subject: Re: [PATCH] memblock: stop using implicit alignement to SMP_CACHE_BYTES From: Benjamin Herrenschmidt Date: Fri, 05 Oct 2018 13:25:38 +1000 In-Reply-To: <1538687224-17535-1-git-send-email-rppt@linux.vnet.ibm.com> References: <1538687224-17535-1-git-send-email-rppt@linux.vnet.ibm.com> Content-Type: text/plain; charset="UTF-8" Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Sender: owner-linux-mm@kvack.org List-ID: To: Mike Rapoport , linux-mm@kvack.org Cc: linux-mips@linux-mips.org, Michal Hocko , linux-ia64@vger.kernel.org, Catalin Marinas , Richard Weinberger , Russell King , Ingo Molnar , Geert Uytterhoeven , Matt Turner , linux-um@lists.infradead.org, linux-m68k@vger.kernel.org, Thomas Gleixner , Guan Xuetao , linux-arm-kernel@lists.infradead.org, Chris Zankel , Michal Simek , Tony Luck , linux-kernel@vger.kernel.org, Paul Burton , linux-alpha@vger.kernel.org, Andrew Morton , linuxppc-dev@lists.ozlabs.org On Fri, 2018-10-05 at 00:07 +0300, Mike Rapoport wrote: > When a memblock allocation APIs are called with align = 0, the alignment is > implicitly set to SMP_CACHE_BYTES. > > Replace all such uses of memblock APIs with the 'align' parameter explicitly > set to SMP_CACHE_BYTES and stop implicit alignment assignment in the > memblock internal allocation functions. > > For the case when memblock APIs are used via helper functions, e.g. like > iommu_arena_new_node() in Alpha, the helper functions were detected with > Coccinelle's help and then manually examined and updated where appropriate. > > The direct memblock APIs users were updated using the semantic patch below: What is the purpose of this ? It sounds rather counter-intuitive... Ben.