From patchwork Fri Jul 27 05:42:35 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "J, KEERTHY" X-Patchwork-Id: 949990 Return-Path: X-Original-To: incoming-imx@patchwork.ozlabs.org Delivered-To: patchwork-incoming-imx@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=none (mailfrom) smtp.mailfrom=lists.infradead.org (client-ip=2607:7c80:54:e::133; helo=bombadil.infradead.org; envelope-from=linux-arm-kernel-bounces+incoming-imx=patchwork.ozlabs.org@lists.infradead.org; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=quarantine dis=none) header.from=ti.com Authentication-Results: ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="F3wpClFp"; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=ti.com header.i=@ti.com header.b="RQxuR9S0"; dkim-atps=neutral Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:e::133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 41cHtw2qL6z9ryn for ; Fri, 27 Jul 2018 15:43:20 +1000 (AEST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Date:Message-ID:Subject: From:To:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=ovQFoRk/Fj8OACwcyGG0bAg5Hwfee1H5OvwJvosfTDA=; b=F3wpClFppPiJWj Wcj6Gp0kX9KYGEiyZ5LubpYNbB7wrG4A6QLZl99LoGjU98OmUSBMiEcO6ZDoPWCa9qnyB+TYiH2tX 0vJMPd+Y9VMsnFKAeyJezWS89sMp1nd5NNS6O/YnLxp0z/PbdBH/3u4tM70rEaq1IubHPpNoIMEqY 6DtBwIsi+SoL27j6tlpjta1awMGSyDjbY/8HsHoPTtLsMv1a56+Zgsb8nj6TqpPpP8Br4ACcnGEQN xUAPLu5NZkOCECnuwdsLyhpgW4y8gSZk/is0vios0Tyi6+UMxliCqGDuVNuQv+k8CAI8eyoyizXqK mGL/MKaXVHXbWl+jB82A==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1fivWz-00065f-AY; Fri, 27 Jul 2018 05:43:13 +0000 Received: from fllv0015.ext.ti.com ([198.47.19.141]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1fivWv-00064i-Fn for linux-arm-kernel@lists.infradead.org; Fri, 27 Jul 2018 05:43:11 +0000 Received: from dlelxv90.itg.ti.com ([172.17.2.17]) by fllv0015.ext.ti.com (8.15.2/8.15.2) with ESMTP id w6R5gd3o117204; Fri, 27 Jul 2018 00:42:39 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ti.com; s=ti-com-17Q1; t=1532670159; bh=D4NeL9HDeTRqS6Yi3iMlaatPoDeikaS0Fxw6kxSxMuc=; h=To:CC:From:Subject:Date; b=RQxuR9S0kG4PFVdt2KkSSVPNuAVTMhbZo1aaC62WApuReh3ZxoRd2y8d8a39VuxWp 272Rp1XjsAP72a+BkduWU275dr7upQBslZaWbzv7oxR2pevGwqH0a2N9fGtMzbWujb +4NJkaD7pfDUXMHiClQNWXuHStCUaa64KuQDwmeY= Received: from DLEE104.ent.ti.com (dlee104.ent.ti.com [157.170.170.34]) by dlelxv90.itg.ti.com (8.14.3/8.13.8) with ESMTP id w6R5gd1l002272; Fri, 27 Jul 2018 00:42:39 -0500 Received: from DLEE115.ent.ti.com (157.170.170.26) by DLEE104.ent.ti.com (157.170.170.34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1466.3; Fri, 27 Jul 2018 00:42:38 -0500 Received: from dlep32.itg.ti.com (157.170.170.100) by DLEE115.ent.ti.com (157.170.170.26) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.1.1466.3 via Frontend Transport; Fri, 27 Jul 2018 00:42:38 -0500 Received: from [172.24.191.45] (ileax41-snat.itg.ti.com [10.172.224.153]) by dlep32.itg.ti.com (8.14.3/8.13.8) with ESMTP id w6R5gaxh006247; Fri, 27 Jul 2018 00:42:36 -0500 To: From: Keerthy Subject: ARM: Build failures with CONFIG_HAVE_RCU_TABLE_FREE=y on linux-next Message-ID: <8a8db414-4723-14f2-ef9d-c10aecc80278@ti.com> Date: Fri, 27 Jul 2018 11:12:35 +0530 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.5.0 MIME-Version: 1.0 Content-Language: en-US X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20180726_224309_607264_38F6BECF X-CRM114-Status: GOOD ( 12.42 ) X-Spam-Score: -0.1 (/) X-Spam-Report: SpamAssassin version 3.4.1 on bombadil.infradead.org summary: Content analysis details: (-0.1 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 SPF_PASS SPF: sender matches SPF record -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Nishanth Menon , tony@atomide.com, Tero Kristo , linux-omap@vger.kernel.org, linux-arm-kernel@lists.infradead.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+incoming-imx=patchwork.ozlabs.org@lists.infradead.org List-Id: linux-imx-kernel.lists.patchwork.ozlabs.org Hi Russell, commit 2ff6ddf19c0ec40633bd14d8fe28a289816bd98d Author: Rik van Riel Date: Mon Jul 16 15:03:32 2018 -0400 x86/mm/tlb: Leave lazy TLB mode at page table free time On linux-next introduces tlb_flush_remove_tables_local and tlb_flush_remove_tables functions that are more or less for x86 only. I see build failures for standalone dra7 K2 defconfigs and NOT in case of omap2plus_defconfig, reason being CONFIG_HAVE_RCU_TABLE_FREE is defined for the failing defconfigs. I looked at arch/arm/Kconfig which has: select HAVE_RCU_TABLE_FREE if (SMP && ARM_LPAE) So in case of K2G/Keystone/dra7 both SMP and LPAE are defined and hence CONFIG_HAVE_RCU_TABLE_FREE is defined which gives me the following build errors: ti_sdk_dra7x_release_defconfig + make -j16 ARCH=arm O=/home/lcpdbld/jenkins_ws/workspace/linux_next_compile/build_out/kernel/ti_s dk_dra7x_release_defconfig :1332:2: warning: #warning syscall io_pgetevents not implemented [-Wcpp] :1338:2: warning: #warning syscall open_tree not implemented [-Wcpp] :1341:2: warning: #warning syscall move_mount not implemented [-Wcpp] :1344:2: warning: #warning syscall fsopen not implemented [-Wcpp] :1347:2: warning: #warning syscall fsmount not implemented [-Wcpp] :1350:2: warning: #warning syscall fspick not implemented [-Wcpp] :1353:2: warning: #warning syscall fsinfo not implemented [-Wcpp] /scratch/lcpdbld/jenkins_ws/workspace/linux_next_compile/linux- kernel/mm/memory.c: In function ‘tlb_remove_table_smp_sync’: /scratch/lcpdbld/jenkins_ws/workspace/linux_next_compile/linux- kernel/mm/memory.c:339:2: error: implicit declaration of function ‘tlb_flush_remove_tables_local’; did you mean ‘tlb_remove_table’? [- Werror=implicit-function-declaration] tlb_flush_remove_tables_local(mm); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~ tlb_remove_table /scratch/lcpdbld/jenkins_ws/workspace/linux_next_compile/linux- kernel/mm/memory.c: In function ‘tlb_table_flush’: /scratch/lcpdbld/jenkins_ws/workspace/linux_next_compile/linux- kernel/mm/memory.c:372:2: error: implicit declaration of function ‘tlb_flush_remove_tables’; did you mean ‘tlb_remove_table’? [-Werror=implicit- function-declaration] tlb_flush_remove_tables(tlb->mm); ^~~~~~~~~~~~~~~~~~~~~~~ tlb_remove_table cc1: some warnings being treated as errors make[2]: *** [mm/memory.o] Error 1 make[2]: *** Waiting for unfinished jobs.... make[1]: *** [mm] Error 2 make[1]: *** Waiting for unfinished jobs.... make: *** [sub-make] Error 2 I could fix the above errors with the hunk below: Regards, Keerthy diff --git a/arch/arm/include/asm/tlb.h b/arch/arm/include/asm/tlb.h index d5562f9..638f2c4 100644 --- a/arch/arm/include/asm/tlb.h +++ b/arch/arm/include/asm/tlb.h @@ -35,6 +35,15 @@ #define MMU_GATHER_BUNDLE 8 +/* + * Used to flush the TLB when page tables are removed, when lazy + * TLB mode may cause a CPU to retain intermediate translations + * pointing to about-to-be-freed page table memory. + */ +#ifndef HAVE_TLB_FLUSH_REMOVE_TABLES +#define tlb_flush_remove_tables(mm) do {} while (0) +#define tlb_flush_remove_tables_local(mm) do {} while (0) +#endif I am sure there is a better way to fix this. Let me know if this can be fixed in a better way.