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: 10546623 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id D0B971822 for ; Fri, 27 Jul 2018 05:43:14 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id B99762B58E for ; Fri, 27 Jul 2018 05:43:14 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id AA2902B591; Fri, 27 Jul 2018 05:43:14 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 62A692B58E for ; Fri, 27 Jul 2018 05:43:13 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1725988AbeG0HDX (ORCPT ); Fri, 27 Jul 2018 03:03:23 -0400 Received: from fllv0015.ext.ti.com ([198.47.19.141]:33312 "EHLO fllv0015.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725861AbeG0HDX (ORCPT ); Fri, 27 Jul 2018 03:03:23 -0400 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: CC: Nishanth Menon , Tero Kristo , , , , Suman Anna 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 Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP 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 --- To unsubscribe from this list: send the line "unsubscribe linux-omap" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html 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.