From patchwork Thu Dec 10 22:47:08 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrew Morton X-Patchwork-Id: 7822751 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 0325CBEEE1 for ; Thu, 10 Dec 2015 22:49:54 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id DCA8A203AD for ; Thu, 10 Dec 2015 22:49:52 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id C294E2039E for ; Thu, 10 Dec 2015 22:49:51 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1a79zq-00045T-Vn; Thu, 10 Dec 2015 22:47:34 +0000 Received: from mail.linuxfoundation.org ([140.211.169.12]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1a79zn-000433-OW for linux-arm-kernel@lists.infradead.org; Thu, 10 Dec 2015 22:47:32 +0000 Received: from akpm3.mtv.corp.google.com (unknown [216.239.45.65]) by mail.linuxfoundation.org (Postfix) with ESMTPSA id A6A31DEC; Thu, 10 Dec 2015 22:47:09 +0000 (UTC) Date: Thu, 10 Dec 2015 14:47:08 -0800 From: Andrew Morton To: Mark Brown Subject: Re: next-20151210 build: 4 failures 43 warnings (next-20151210) Message-Id: <20151210144708.65b7111eb795ddabbfad1ed3@linux-foundation.org> In-Reply-To: <20151210165513.GO5727@sirena.org.uk> References: <20151210165513.GO5727@sirena.org.uk> X-Mailer: Sylpheed 3.4.1 (GTK+ 2.24.23; x86_64-pc-linux-gnu) Mime-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20151210_144731_872364_BEABEDB2 X-CRM114-Status: GOOD ( 15.20 ) X-Spam-Score: -4.2 (----) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Stephen Rothwell , linaro-kernel@lists.linaro.org, kernel-build-reports@lists.linaro.org, Catalin Marinas , Will Deacon , linux-next@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Vlastimil Babka Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP On Thu, 10 Dec 2015 16:55:13 +0000 Mark Brown wrote: > Today's -next fails to build most arm64 configs with some rather > spectacular errors below introduced by 02598e94ed5a78 (mm, printk: > introduce new format string for flags) from Andrew's tree. These in > turn stem from the fact that we introduce an inclusion of > linux/tracepoint.h into linux/mmdebug.h which through a chain of nested > inclusions means that we end up attempting to use definitions from > headers before they have finished including. Thanks. Further complexicating the include tree is something we don't need. I'll try moving the offending declarations into mm/internal.h, see how that goes. Including ../mm/internal.h into lib/vsprintf.c is a bit grubby, but I guess it makes sense - vsprintf is poking about in mm internals, so it gets to include mm's internal.h. Vlastimil, the patch is rather bloaty - it adds 1.2k for something which few people will use. I wonder if it should be conditioned by CONFIG_DEBUG_VM. From: Andrew Morton Subject: mm-printk-introduce-new-format-string-for-flags-fix-2 move declaration of trace_print_flags arrays into mm/internal.h Cc: "Kirill A. Shutemov" Cc: Joonsoo Kim Cc: Mel Gorman Cc: Michal Hocko Cc: Minchan Kim Cc: Rasmus Villemoes Cc: Sasha Levin Cc: Vlastimil Babka Signed-off-by: Andrew Morton --- include/linux/mmdebug.h | 6 ------ lib/vsprintf.c | 3 ++- mm/debug.c | 2 ++ mm/internal.h | 7 +++++++ 4 files changed, 11 insertions(+), 7 deletions(-) diff -puN include/linux/mmdebug.h~mm-printk-introduce-new-format-string-for-flags-fix-2 include/linux/mmdebug.h --- a/include/linux/mmdebug.h~mm-printk-introduce-new-format-string-for-flags-fix-2 +++ a/include/linux/mmdebug.h @@ -2,17 +2,11 @@ #define LINUX_MM_DEBUG_H 1 #include -#include -#include struct page; struct vm_area_struct; struct mm_struct; -extern const struct trace_print_flags pageflag_names[]; -extern const struct trace_print_flags vmaflag_names[]; -extern const struct trace_print_flags gfpflag_names[]; - extern void dump_page(struct page *page, const char *reason); extern void dump_page_badflags(struct page *page, const char *reason, unsigned long badflags); diff -puN lib/vsprintf.c~mm-printk-introduce-new-format-string-for-flags-fix-2 lib/vsprintf.c --- a/lib/vsprintf.c~mm-printk-introduce-new-format-string-for-flags-fix-2 +++ a/lib/vsprintf.c @@ -31,7 +31,8 @@ #include #include #include -#include + +#include "../mm/internal.h" /* For the trace_print_flags arrays */ #include /* for PAGE_SIZE */ #include /* for dereference_function_descriptor() */ diff -puN mm/debug.c~mm-printk-introduce-new-format-string-for-flags-fix-2 mm/debug.c --- a/mm/debug.c~mm-printk-introduce-new-format-string-for-flags-fix-2 +++ a/mm/debug.c @@ -13,6 +13,8 @@ #include #include +#include "internal.h" + char *migrate_reason_names[MR_TYPES] = { "compaction", "memory_failure", diff -puN mm/internal.h~mm-printk-introduce-new-format-string-for-flags-fix-2 mm/internal.h --- a/mm/internal.h~mm-printk-introduce-new-format-string-for-flags-fix-2 +++ a/mm/internal.h @@ -11,9 +11,11 @@ #ifndef __MM_INTERNAL_H #define __MM_INTERNAL_H +#include #include #include #include +#include /* * The set of flags that only affect watermark checking and reclaim @@ -441,4 +443,9 @@ static inline void try_to_unmap_flush_di } #endif /* CONFIG_ARCH_WANT_BATCHED_UNMAP_TLB_FLUSH */ + +extern const struct trace_print_flags pageflag_names[]; +extern const struct trace_print_flags vmaflag_names[]; +extern const struct trace_print_flags gfpflag_names[]; + #endif /* __MM_INTERNAL_H */