Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp2764233pxk; Sun, 6 Sep 2020 12:34:47 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyDmPljsqFR23fEv5TlFa5OsN2pziX5uUkQt6J+DSVWEfla2E9Tgb14N1+TfrDtHAgjFOOF X-Received: by 2002:a50:875b:: with SMTP id 27mr18319688edv.117.1599420887294; Sun, 06 Sep 2020 12:34:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1599420887; cv=none; d=google.com; s=arc-20160816; b=EIrqzZJfJBALNf2Xh+DG65qs97LTaDokEeY67pJ3LIbVqCdTZg7vyjvPv/Gbxq94NJ lRdFMsklaczGdQkleAD2XMeHW6UPxM8TZ1KXsM4pKnByS6VsvBdnS02a1v+QKZtp7hZG 5/CEz/SgyJ3rtbGVyLTixyfq7U8XNmD9DApJE9ckfdF2em9eiqfozIoMjdkUtyCfI2es 71yLJ1tEoErPnQ53uj8TVJcqfXmV1QnjSqMHpYZZVtOCilMT4nmZH0KCM+meQrileCgE nS9cgds2FhPq6OY+A6o0UYP/XkV+s+ZBie0hq7cRYt1EYzTj1hxewiP1FJk9lGlOt8dz QVtQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:mime-version:user-agent:date:message-id:subject :from:cc:to:dkim-signature; bh=GbMNrkLBxGmNSVmZdqvsvL+gwMutalvbb1INFje9QKQ=; b=w8BQzdTjMZivDL//C8joxI9j6g75cy0YhtED31xQ8uhuj1RUlMV7Q3ydicTDNZA9L4 O93byVmrfwm3GOGQ2XAnbGrKPDyHy/2rmPmcEHhlvq20ga7onPcqsZq7Vb+U9eZbYknT TZJ8ZRxhiwKuygJ1QcPuvGGVm0pa1xbS8BzpR2E4A5XCFj23BiwyiL4bXcHh07QR+IOG 5zfiixuC20+NkY3F1wSX04JsnB6VmFmXFESoKbsx8I42E7d8gK3KHhkhET8UTFP1xYPv AagApfqX3ohjTHd/SkXVyPlAw7RWkYMqDBee6fvPpY7atKjKRqyZlx7mvWur7mGq43Ou 1lWg== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@infradead.org header.s=merlin.20170209 header.b="M/d59Iyt"; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id v23si4840165edr.208.2020.09.06.12.34.25; Sun, 06 Sep 2020 12:34:47 -0700 (PDT) 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=fail header.i=@infradead.org header.s=merlin.20170209 header.b="M/d59Iyt"; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726357AbgIFTdk (ORCPT + 99 others); Sun, 6 Sep 2020 15:33:40 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38642 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726063AbgIFTdj (ORCPT ); Sun, 6 Sep 2020 15:33:39 -0400 Received: from merlin.infradead.org (merlin.infradead.org [IPv6:2001:8b0:10b:1231::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9F11AC061573 for ; Sun, 6 Sep 2020 12:33:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=merlin.20170209; h=Content-Transfer-Encoding:Content-Type: MIME-Version:Date:Message-ID:Subject:From:Cc:To:Sender:Reply-To:Content-ID: Content-Description:In-Reply-To:References; bh=GbMNrkLBxGmNSVmZdqvsvL+gwMutalvbb1INFje9QKQ=; b=M/d59IytXM0oQwpJsuioibpx+G JdOQuOdeWKI1hPzNl2vg7Oo58qEooKKWr3WQAgELONs3Qx6WzqQjS8xPOL71//MmivEsFyQ2Y2UXv s+5RPJzgL1tRNM1oaPY7774rTQKly1oKa6jlJ/gpZAf60GRVK/lh1exGG3EEOjTMbHxAfa6oAI8Wb 619XizF4SdSAuwHwOxuMcVZeHEJdk7o5QeesCCL+MUVx4uUgMmC9f0CgHSOampVtGNE9SkXaqkFFl xfs1s2VawYiMpY2p9TbhK/O9nAvLO4ZVmoFR1wiWEKGlk4dI3ilpZS8JSnnYkMIlAVU/dtuCDdj+n FIrOMdgQ==; Received: from [2601:1c0:6280:3f0::19c2] by merlin.infradead.org with esmtpsa (Exim 4.92.3 #3 (Red Hat Linux)) id 1kF0PZ-0002sU-R6; Sun, 06 Sep 2020 19:33:14 +0000 To: LKML , Linux MM , Andrew Morton Cc: Michal Nazarewicz , Wen Congyang , Michal Simek , Christoph Hellwig , Mike Rapoport , kernel test robot From: Randy Dunlap Subject: [PATCH] : provide stubs for MEMORY_ISOLATION not set (for Microblaze) Message-ID: <1f6b42e6-b6b5-40e3-92b4-77bd610d3e49@infradead.org> Date: Sun, 6 Sep 2020 12:33:08 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.11.0 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Randy Dunlap Fix build errors in Microblaze when CONFIG_MEMORY_ISOLATION is not set/enabled by adding stubs for 3 missing functions. Fixes these build errors: gcc-9.3.0-nolibc/microblaze-linux/bin/microblaze-linux-ld: mm/page_alloc.o: in function `alloc_contig_range': (.text+0xa0c0): undefined reference to `start_isolate_page_range' gcc-9.3.0-nolibc/microblaze-linux/bin/microblaze-linux-ld: (.text+0xa2bc): undefined reference to `test_pages_isolated' gcc-9.3.0-nolibc/microblaze-linux/bin/microblaze-linux-ld: (.text+0xa378): undefined reference to `undo_isolate_page_range' Fixes: 0815f3d81d76 ("mm: page_isolation: MIGRATE_CMA isolation functions added") # v3.10 Fixes: b023f46813cd ("memory-hotplug: skip HWPoisoned page when offlining pages") # v3.10 Reported-by: kernel test robot Signed-off-by: Randy Dunlap Cc: Michal Nazarewicz Cc: Wen Congyang Cc: Michal Simek Cc: Christoph Hellwig Cc: Andrew Morton Cc: Mike Rapoport Cc: linux-mm@kvack.org --- include/linux/page-isolation.h | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) --- linux-next-20200903.orig/include/linux/page-isolation.h +++ linux-next-20200903/include/linux/page-isolation.h @@ -28,6 +28,22 @@ static inline bool is_migrate_isolate(in { return false; } +static inline int test_pages_isolated(unsigned long start_pfn, + unsigned long end_pfn, int isol_flags) +{ + return 0; +} +static inline int +start_isolate_page_range(unsigned long start_pfn, unsigned long end_pfn, + unsigned migratetype, int flags) +{ + return 0; +} +static inline void +undo_isolate_page_range(unsigned long start_pfn, unsigned long end_pfn, + unsigned migratetype) +{ +} #endif #define MEMORY_OFFLINE 0x1