Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp1050444pxb; Fri, 22 Jan 2021 06:08:30 -0800 (PST) X-Google-Smtp-Source: ABdhPJz6VhdAIbDwgaKNE2tscDvRpPdcu9C4iRfaBnhZDJbnR3fJ87cPoyTuHU6YpgUP43Md7PVS X-Received: by 2002:a17:906:2755:: with SMTP id a21mr3114677ejd.374.1611324510286; Fri, 22 Jan 2021 06:08:30 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1611324510; cv=none; d=google.com; s=arc-20160816; b=jsYhzNcUVModgcx7nBlJspl/D7yb3kFfnqE1M1iG2FD3xLtPPOi9u47rzpS06A+obe EuGo9oQizl0xwm4H+SW2D73x2xwTmUhgku9GMvGmT9iiz4Epx5Q19UHxSYKenRu980qR wNzMQFZKwWT33GFiC3M3LxQ+kCkZUTnL0iNWntn5IyPncWRUiDEHKfVv5wpNBEswFe9P 8e2AsdtbdVCS4uog/2p26NTncg7dabnliDRXjMWjSeJrcmQd9luZIbvOZ/8TpGAW1eyu M0L55+SF/aWhH7zNvzHMJaWRQAhGOWWQZQADmZjnNJi2/ZZvq9QKjcBgHUkLhupsS+bY dSfw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:references:in-reply-to:message-id:date:subject :cc:to:from:dkim-signature; bh=OYKXe0LwvkCV6oYZjgb0l0tdopJgegZlST8zSrtCleo=; b=KYfhK9sPspCeNOLc3e4z1LVnjJKlD4OOEhKJ5O6fFYwa9n6umGg3Nfgjcx0J7Ka3R2 CBE4RfVT3+iEnZTYgOYGTJnFHhS3pmyEenqUmpIiVbAHW7Yb5Fn88DLEyjfShik8XE6/ 9/WgMPIFa1Pcpse0t+KWhwszf1VQaOaQ9msCnoV4Dj0thcToBCYNgAV8qP+MXn8ueqAG Yd+XBLY97p5mnlev6ipuDc4eMvTfjLuKMpPoREklSBC+NFIUayxTbl+jugdVctCutNpc Q3nP1CUflnYrKVusyUTHwYrUHI0xl4k94Xbwff8sqfFEgYiRgnFszqb5OGHDiVpx8ajK Qivw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=G7xscyVG; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id d7si3586008edv.185.2021.01.22.06.08.02; Fri, 22 Jan 2021 06:08:30 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=G7xscyVG; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728230AbhAVODU (ORCPT + 99 others); Fri, 22 Jan 2021 09:03:20 -0500 Received: from us-smtp-delivery-124.mimecast.com ([63.128.21.124]:34348 "EHLO us-smtp-delivery-124.mimecast.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728102AbhAVOBm (ORCPT ); Fri, 22 Jan 2021 09:01:42 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1611324016; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:in-reply-to:in-reply-to:references:references; bh=OYKXe0LwvkCV6oYZjgb0l0tdopJgegZlST8zSrtCleo=; b=G7xscyVGbAyQNn++4tv8/Z/p6wBcWV9/KGvCAPvmSkdFqJ/OKN84dteWKE3mQ0AOztOFo/ G+5KIlfLvVnQ+G+1OzCEdfBfi+J/f3NN2RE3vto+WR3PdA0y9GtS/pK1SxssyPpchuWrS1 aQyvUxGqpeTa+VQ1ofYEZ+16QhqU1U4= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-50-SzsDFnbcM0eOXizJp8UA6A-1; Fri, 22 Jan 2021 09:00:11 -0500 X-MC-Unique: SzsDFnbcM0eOXizJp8UA6A-1 Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id ABDD1806661; Fri, 22 Jan 2021 14:00:10 +0000 (UTC) Received: from MiWiFi-R3L-srv.redhat.com (ovpn-12-114.pek2.redhat.com [10.72.12.114]) by smtp.corp.redhat.com (Postfix) with ESMTP id 2FE0519C59; Fri, 22 Jan 2021 14:00:07 +0000 (UTC) From: Baoquan He To: linux-kernel@vger.kernel.org Cc: linux-mm@kvack.org, akpm@linux-foundation.org, rppt@kernel.org, david@redhat.com, bhe@redhat.com, lkp@intel.com Subject: [PATCH v5 1/5] mm: fix prototype warning from kernel test robot Date: Fri, 22 Jan 2021 21:59:52 +0800 Message-Id: <20210122135956.5946-2-bhe@redhat.com> In-Reply-To: <20210122135956.5946-1-bhe@redhat.com> References: <20210122135956.5946-1-bhe@redhat.com> X-Scanned-By: MIMEDefang 2.84 on 10.5.11.23 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Kernel test robot calling make with 'W=1' is triggering warning like below for memmap_init_zone() function. mm/page_alloc.c:6259:23: warning: no previous prototype for 'memmap_init_zone' [-Wmissing-prototypes] 6259 | void __meminit __weak memmap_init_zone(unsigned long size, int nid, | ^~~~~~~~~~~~~~~~ Fix it by adding the function declaration in include/linux/mm.h. Since memmap_init_zone() has a generic version with '__weak', the declaratoin in ia64 header file can be simply removed. Signed-off-by: Baoquan He Reported-by: kernel test robot --- arch/ia64/include/asm/pgtable.h | 6 ------ include/linux/mm.h | 2 ++ 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/arch/ia64/include/asm/pgtable.h b/arch/ia64/include/asm/pgtable.h index 779b6972aa84..9b4efe89e62d 100644 --- a/arch/ia64/include/asm/pgtable.h +++ b/arch/ia64/include/asm/pgtable.h @@ -517,12 +517,6 @@ extern struct page *zero_page_memmap_ptr; __changed; \ }) #endif - -# ifdef CONFIG_VIRTUAL_MEM_MAP - /* arch mem_map init routine is needed due to holes in a virtual mem_map */ - extern void memmap_init (unsigned long size, int nid, unsigned long zone, - unsigned long start_pfn); -# endif /* CONFIG_VIRTUAL_MEM_MAP */ # endif /* !__ASSEMBLY__ */ /* diff --git a/include/linux/mm.h b/include/linux/mm.h index 3dac7bc667ee..3d82b4f7cabc 100644 --- a/include/linux/mm.h +++ b/include/linux/mm.h @@ -2401,6 +2401,8 @@ extern void set_dma_reserve(unsigned long new_dma_reserve); extern void memmap_init_zone(unsigned long, int, unsigned long, unsigned long, unsigned long, enum meminit_context, struct vmem_altmap *, int migratetype); +extern void memmap_init(unsigned long size, int nid, + unsigned long zone, unsigned long range_start_pfn); extern void setup_per_zone_wmarks(void); extern int __meminit init_per_zone_wmark_min(void); extern void mem_init(void); -- 2.17.2