Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp300754imm; Thu, 6 Sep 2018 02:41:28 -0700 (PDT) X-Google-Smtp-Source: ANB0VdY+UjmoJE3qAkawq2aTEPuny1zGxuBcU+g0HLwLk31JA1dRqzQdKj9/m1qpaDr2sNEGF7gT X-Received: by 2002:a63:5358:: with SMTP id t24-v6mr1813940pgl.208.1536226888896; Thu, 06 Sep 2018 02:41:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1536226888; cv=none; d=google.com; s=arc-20160816; b=oQiLBcfBr07xPepD750cG1as6A7WgiSF7Vg+2Gm+T6Yyc/12M4mLL6yZVvjLyqnsaR KRVwPFcBOcJrKZWTr+B+yWohDF8IWu2PCch222tWnyM62i8DI5hHFTtlGtAjhG5aL1mk KaiqZG49SRQkxf00hhyXx98rL2+AIVYMRVVaUy2UURro5rsVUwYK7XP7V1eIuD5EtehF dyCuOaq/IzG2xhxSqn+hgk0csJKKOLNQ6yO7TmoEr8jJ8/RaNCdaLCE+BK7fWyMolajW Cx0z59iNU9dIrB5OUB16POOQKxGaoA1nsymSA1M+smGEbknmoPPTx7+MfJ+OdgpP0agd kyBQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=mCuvGoPBT7ElinsJP1eqFxQFMPm6lWEjKiAzlHJoEHA=; b=TGrIsDbfTrtSK0CZ49dZi07ICT/UXfhnuOuC6di2Fcw1n/D2E5qnWGdMatlXBgmc3m xLkJR2K1+XDC3LW6J5F76ykI+nQ3BE6ALMBP8GkG5Q7cvSVfkHR09TulDDpSNIYCxc5P jEhwwOyLEwnHGNRqq7i3TJEdzkng2fwupeus2aSpyV5OdMdBXf8iBqC4OCkkSBuxIqwh UyoBKIOEtTt4YM+bXdMzRUsnUjkKRQ2EJ/UuvhBuhvskWKXFWsoAoFFXf+lyQuauCqxX jQPVwTsZ/EgKaDbDzVIa++jpAoL3+FR/KTUcPa6Na5t6ByNjDQdMlvJASuWy/J00fjZN X7VA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id u13-v6si4715526pgg.263.2018.09.06.02.41.13; Thu, 06 Sep 2018 02:41:28 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727819AbeIFM1b (ORCPT + 99 others); Thu, 6 Sep 2018 08:27:31 -0400 Received: from mx2.suse.de ([195.135.220.15]:60844 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1725819AbeIFM1b (ORCPT ); Thu, 6 Sep 2018 08:27:31 -0400 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.220.254]) by mx1.suse.de (Postfix) with ESMTP id 7D165ADF4; Thu, 6 Sep 2018 07:53:19 +0000 (UTC) Date: Thu, 6 Sep 2018 09:53:19 +0200 From: Michal Hocko To: Mike Rapoport Cc: linux-mm@kvack.org, Andrew Morton , "David S. Miller" , Greg Kroah-Hartman , Ingo Molnar , Michael Ellerman , Paul Burton , Thomas Gleixner , Tony Luck , linux-ia64@vger.kernel.org, linux-mips@linux-mips.org, linuxppc-dev@lists.ozlabs.org, sparclinux@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [RFC PATCH 11/29] memblock: replace alloc_bootmem_pages_nopanic with memblock_alloc_nopanic Message-ID: <20180906075319.GT14951@dhcp22.suse.cz> References: <1536163184-26356-1-git-send-email-rppt@linux.vnet.ibm.com> <1536163184-26356-12-git-send-email-rppt@linux.vnet.ibm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1536163184-26356-12-git-send-email-rppt@linux.vnet.ibm.com> User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed 05-09-18 18:59:26, Mike Rapoport wrote: > The alloc_bootmem_pages_nopanic(size) is a shortcut for > __alloc_bootmem_nopanic(x, PAGE_SIZE, BOOTMEM_LOW_LIMIT) and can be > replaced by memblock_alloc_nopanic(size, PAGE_SIZE) It is not so straightforward because you really have to go deep down the callpath to see they are doing the same thing essentially. > Signed-off-by: Mike Rapoport Acked-by: Michal Hocko > --- > drivers/usb/early/xhci-dbc.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/usb/early/xhci-dbc.c b/drivers/usb/early/xhci-dbc.c > index e15e896..16df968 100644 > --- a/drivers/usb/early/xhci-dbc.c > +++ b/drivers/usb/early/xhci-dbc.c > @@ -94,7 +94,7 @@ static void * __init xdbc_get_page(dma_addr_t *dma_addr) > { > void *virt; > > - virt = alloc_bootmem_pages_nopanic(PAGE_SIZE); > + virt = memblock_alloc_nopanic(PAGE_SIZE, PAGE_SIZE); > if (!virt) > return NULL; > > -- > 2.7.4 > -- Michal Hocko SUSE Labs