From patchwork Fri Apr 29 13:42:18 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steven Rostedt X-Patchwork-Id: 8982571 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 2DE92BF29F for ; Fri, 29 Apr 2016 13:43:57 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 45029201CE for ; Fri, 29 Apr 2016 13:43:56 +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 5D5C6200E8 for ; Fri, 29 Apr 2016 13:43:55 +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 1aw8gx-0003eH-Ob; Fri, 29 Apr 2016 13:42:47 +0000 Received: from smtprelay0222.hostedemail.com ([216.40.44.222] helo=smtprelay.hostedemail.com) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1aw8gv-0003Y5-AX for linux-arm-kernel@lists.infradead.org; Fri, 29 Apr 2016 13:42:45 +0000 Received: from filter.hostedemail.com (unknown [216.40.38.60]) by smtprelay07.hostedemail.com (Postfix) with ESMTP id 43AD9C1F7F; Fri, 29 Apr 2016 13:42:21 +0000 (UTC) X-Session-Marker: 726F737465647440676F6F646D69732E6F7267 X-Spam-Summary: 2, 0, 0, , d41d8cd98f00b204, rostedt@goodmis.org, :::::::::::::::::::::::, RULES_HIT:41:355:379:541:599:800:960:973:988:989:1260:1277:1311:1313:1314:1345:1359:1431:1437:1515:1516:1518:1534:1541:1593:1594:1711:1730:1747:1777:1792:2393:2553:2559:2562:3138:3139:3140:3141:3142:3352:3622:3865:3868:3871:4321:4470:5007:6261:6742:7903:10004:10400:10848:10967:11026:11232:11657:11658:11914:12043:12296:12438:12517:12519:12555:12740:13069:13311:13357:13439:14181:14659:14721:21080:21433:21434:30054:30090:30091, 0, RBL:none, CacheIP:none, Bayesian:0.5, 0.5, 0.5, Netcheck:none, DomainCache:0, MSF:not bulk, SPF:fn, MSBL:0, DNSBL:none, Custom_rules:0:0:0, LFtime:2, LUA_SUMMARY:none X-HE-Tag: tub36_316abecd7335b X-Filterd-Recvd-Size: 2342 Received: from gandalf.local.home (cpe-67-246-153-56.stny.res.rr.com [67.246.153.56]) (Authenticated sender: rostedt@goodmis.org) by omf04.hostedemail.com (Postfix) with ESMTPA; Fri, 29 Apr 2016 13:42:19 +0000 (UTC) Date: Fri, 29 Apr 2016 09:42:18 -0400 From: Steven Rostedt To: Arnd Bergmann Subject: Re: [PATCH] sched/core: don't include asm/mmu_context from drivers Message-ID: <20160429094218.61b26849@gandalf.local.home> In-Reply-To: <1461919995-21001-1-git-send-email-arnd@arndb.de> References: <1461919995-21001-1-git-send-email-arnd@arndb.de> X-Mailer: Claws Mail 3.13.2 (GTK+ 2.24.30; 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-20160429_064245_448717_01F4ADE9 X-CRM114-Status: GOOD ( 10.06 ) X-Spam-Score: -1.9 (-) 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: Russell King , Ard Biesheuvel , Peter Zijlstra , Frederic Weisbecker , linux-kernel@vger.kernel.org, Ingo Molnar , Andy Lutomirski , Thomas Gleixner , Borislav Petkov , Mel Gorman , linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-5.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, 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 Fri, 29 Apr 2016 10:52:32 +0200 Arnd Bergmann wrote: > This reverts the earlier fix attempt and works around the problem > by including both linux/mmu_context.h and asm/mmu_context.h from > kernel/sched/core.c. This is not a good solution but seems less > hacky than the alternatives. What about simply not compiling finish_arch_post_lock_switch() when building modules? (untested, not compiled or anything) Signed-off-by: Steven Rostedt Acked-by: Russell King diff --git a/arch/arm/include/asm/mmu_context.h b/arch/arm/include/asm/mmu_context.h index fa5b42d44985..3f22d1b6bac8 100644 --- a/arch/arm/include/asm/mmu_context.h +++ b/arch/arm/include/asm/mmu_context.h @@ -66,6 +66,7 @@ static inline void check_and_switch_context(struct mm_struct *mm, cpu_switch_mm(mm->pgd, mm); } +#ifndef MODULE #define finish_arch_post_lock_switch \ finish_arch_post_lock_switch static inline void finish_arch_post_lock_switch(void) @@ -87,6 +88,7 @@ static inline void finish_arch_post_lock_switch(void) preempt_enable_no_resched(); } } +#endif /* !MODULE */ #endif /* CONFIG_MMU */