From patchwork Sun Jun 4 11:59:51 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Yury Norov X-Patchwork-Id: 9764847 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 0AA1E602BF for ; Sun, 4 Jun 2017 12:07:05 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id EFFDE28111 for ; Sun, 4 Jun 2017 12:07:04 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id E2F0628498; Sun, 4 Jun 2017 12:07:04 +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=-1.9 required=2.0 tests=BAD_ENC_HEADER,BAYES_00, DKIM_SIGNED,DKIM_VALID autolearn=unavailable version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [65.50.211.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 3B84128111 for ; Sun, 4 Jun 2017 12:07:04 +0000 (UTC) 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:References:In-Reply-To: Message-Id:Date:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=vXnZcP4IUtqtNIxxa2iyJsYnsZDdNxHIko7IaA0kl1c=; b=I4ZTWi1L4SFUZr /7xcWbYf6BH8Ad4Jj4a0G4TM/h1LIzlWTl9j71Jf1xe2Tai7AcBP+tzvQgYOoNKCYb3J39U02Zh4U P0PTzCZKFIoB6vbqcQizmgfQ06MMKPWHTF9ynIZGTkWcwJiU9lDdg4YW0jHPXT8X1inNznjMm4MsI Z8sZNvtmTlvWWNqIdxCVeMSmlqVUtT97uYz1RfAbsQGJtR2R3osiEPitb8h88O4HCoeuXWJaneax5 Eic8tbGOy/LPuRyqBGFzZ3zOlxQDhcv1unhxCpDjDKoPPl6bIr/g7vQN5x/t97AWAcy4NyNK7bask t6HHaF3tHNmTS+a7fXnQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.87 #1 (Red Hat Linux)) id 1dHUJ9-0004C5-3a; Sun, 04 Jun 2017 12:06:59 +0000 Received: from mail-sn1nam02on0068.outbound.protection.outlook.com ([104.47.36.68] helo=NAM02-SN1-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.87 #1 (Red Hat Linux)) id 1dHUDX-0007LR-S6 for linux-arm-kernel@lists.infradead.org; Sun, 04 Jun 2017 12:01:13 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=CAVIUMNETWORKS.onmicrosoft.com; s=selector1-cavium-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=eL+vyg6pDt98FvxMOZRhQzFW3SKLf+yxuJ2TiCzyQX8=; b=KKCWk7azoo8Np/3unMmZhxT5Hu9lcgi341cKj64Xb5xpxhzNiMGcfdOTfwePY/38klWCXKmHpLOy86Jkrehg1Oef/8qSghZYRqmIGE5TiI1zKf7q+RIXDL+nJ39bvw0hcMYT5JyTZlkPNCzU25hg86UqRHBxTv/eJ/e+fUFJmCg= Authentication-Results: arm.com; dkim=none (message not signed) header.d=none; arm.com; dmarc=none action=none header.from=caviumnetworks.com; Received: from localhost (176.59.55.28) by BN3PR0701MB1267.namprd07.prod.outlook.com (10.160.118.141) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1143.10; Sun, 4 Jun 2017 12:00:49 +0000 From: Yury Norov To: Catalin Marinas , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-doc@vger.kernel.org, Arnd Bergmann Subject: [PATCH 02/20] 32-bit ABI: introduce ARCH_32BIT_OFF_T config option Date: Sun, 4 Jun 2017 14:59:51 +0300 Message-Id: <20170604120009.342-3-ynorov@caviumnetworks.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20170604120009.342-1-ynorov@caviumnetworks.com> References: <20170604120009.342-1-ynorov@caviumnetworks.com> MIME-Version: 1.0 X-Originating-IP: [176.59.55.28] X-ClientProxiedBy: HE1PR09CA0069.eurprd09.prod.outlook.com (10.174.50.141) To BN3PR0701MB1267.namprd07.prod.outlook.com (10.160.118.141) X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: BN3PR0701MB1267: X-MS-Office365-Filtering-Correlation-Id: fec9b72e-3fc6-4a42-a8a9-08d4ab4157aa X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(22001)(201703131423075)(201703031133081); SRVR:BN3PR0701MB1267; X-Microsoft-Exchange-Diagnostics: 1; BN3PR0701MB1267; 3:EQ/SVZe88P4q8YCcI2vRgirJvpvvZX5FkdheqJpmSaGAaJu/J7E6kvjZ2m1vg8TSTQvsUDNXVpYUpjDHSZKCM1fdjN+P0xPkgDNJXjBVTbraPLLfEhNwkOnYY8BDdvGFCmxntq5hlswsm28W8q+xs0+5vSB723wiFSQAeZPQdv7DytGCbTEEC7YxF4QFYe/FjV90kmEIfq3aE+H/r2z+GoYg1MfGlLTHte8sSXqz6ec8Oq3NX79RX+UwMxVt4/sO5PNwdgmncw9X3gkuDkZZDecUw6L8mFImmltiCqanlLPtUsQrh3YP4dnZhTm54xrIrLwaoEz6aK8o0S7V7501LQ==; 25:Zr9dlSAvh1N8rkKDAEwRAgt1kiAtzgJZAhZ/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Gwf1imBLo+KgtlObBGXVk8b7gPrcRlu+gGg/oDSN4co0wiBHR8U2dOMhzKoi+7TGJuo8g1ors51uQWB3XDtinbv8/0DjVcxkssyRF1mabd2RqgsYF0J/+Y9Qwcz3Vy+LAPlWRvo2mc4rvXk3yL8CC7oojoblzSmh4xSuOGN9hiZaiDhJIxeK2KKqc4TwaVQW8SaEgGrMPfQjtwb2xbTryp5TbXdrlZ2c88R2rySjsXIu95aHJniNxHGlungO3hdUhu8WuQixHEwio= X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(5213294742642); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6040450)(601004)(2401047)(8121501046)(5005006)(100000703101)(100105400095)(93006095)(10201501046)(3002001)(6041248)(20161123558100)(20161123560025)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(20161123555025)(20161123562025)(20161123564025)(6072148)(100000704101)(100105200095)(100000705101)(100105500095); SRVR:BN3PR0701MB1267; BCL:0; PCL:0; RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(100000804101)(100110200095)(100000805101)(100110500095); SRVR:BN3PR0701MB1267; X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; BN3PR0701MB1267; 4:BRLUHV/+sNeyqn3NYF7d6qBBHlyVo2lLzIMdo05s?= =?us-ascii?Q?Qn4IuTMeRT/KXHuU5853B9MESAWyQNIhOD5jnqU2/C3PZDzhdo7/GPOnC0Bq?= =?us-ascii?Q?N/D9TCQnWDyCTZBpU9V3QlnUmcn3ULEqC7ho56+Gt6TbhFZrpPO1cr/iDuBf?= =?us-ascii?Q?fYPEey+lT9jCvGiPMICo9XfqposOqw1o37D4YH3DwM8C50IQTFVtPA4UmJHY?= =?us-ascii?Q?KOVGouzA93T2fK0ersGC34EvLbf1cvpQJtQkKkm0/oVAsabG5JmiHS6EKQxA?= =?us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2fecVkx/8fPBWx+GPkw=3D=3D?= X-Forefront-PRVS: 03283976A6 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(4630300001)(6069001)(6009001)(39400400002)(39850400002)(39410400002)(575784001)(2906002)(72206003)(6666003)(189998001)(2950100002)(42882006)(5003940100001)(478600001)(66066001)(6486002)(53936002)(54906002)(50986999)(76176999)(47776003)(38730400002)(6496005)(48376002)(50466002)(5660300001)(7416002)(76506005)(8676002)(81166006)(36756003)(305945005)(42186005)(33646002)(4326008)(50226002)(25786009)(1076002)(6116002)(3846002)(15760500002); DIR:OUT; SFP:1101; SCL:1; SRVR:BN3PR0701MB1267; H:localhost; FPR:; SPF:None; MLV:sfv; LANG:en; X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; BN3PR0701MB1267; 23:tvhpB5uC8bIPvJ+t59qZRWzD9uJXR4GEdIGp4Ij?= =?us-ascii?Q?cMn95AYbEFNBImX4gH4qEWr/w6U2Rw7WcGLNNM2BZ/7h+1Aik7fTStdFuSpH?= =?us-ascii?Q?/nUKXH/UEyuEPzNq5dur0jqK2Ke4PsBa3B/vlac85J54Ye01CGymV69pHJGa?= =?us-ascii?Q?GN7tmLVgb95SW2ytSRYVr9/Qh8Iv58cKBiZwNRQTzGDuqenWG8ho0gw0E2wL?= =?us-ascii?Q?Hcevgpz5eOTZcvIGpFdA6i4iVoKcDGfdsHJoaR8U0CqwYodeTKfZviNftjCY?= =?us-ascii?Q?X6LEKhuo3lIgcOze0VQDGdFYIzuRoCb6dKe2A3iW5s8RrH2YjlD7hrKeIP4n?= =?us-ascii?Q?Bxcc7YpeerPMfbJObKgW9gm3tJ/SiFy0sFsPQOeU5bjXDiLUjQGoq1FDJFCQ?= =?us-ascii?Q?HOAPE0frEi7sZOhxaVV2RHqeUWCo2Da0tsDfLhyYlUho4graHnppeRV9mcZA?= =?us-ascii?Q?JK3TLrVI+BxPnx17PB44D17ZfPShwmddmMuNRHNRr1jpdo+Kg9l1sNN3Uzf5?=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icAyoflbdUjaiwN55GMCzIxyUAne05RhWE0MrnNNhvpS2z2FqNHfKG/3TmfS/AqkUpfKSG5h1l+tXsHp1fksxQFjn/MFR6VYmSml2Isze53gHvrYOHSBok2mf9RjjNZ2/DZiBbzuRqYxOWVCZbepTPe65qURwv0frxVaTQN647jlWv0m1lajTV+PZkFyVKiHJClQj5weg== X-Microsoft-Exchange-Diagnostics: 1; BN3PR0701MB1267; 5:T7b1mI0WBOW2M3r5rKxCVzmtg8gYwR2PUaPp5erBIqaMlHlFUJDg4WXHa3QG61qab84rc6B98KnAcOQjLFLZzQsrJ480jlU0mt+nX7P63r0oayJGX2QUtylznwjrcpdsgPfYQBKrEYWwbpTLbLgV2XAbQvBTVYfj20UyNIRgdq5YCuSOVbY2vOfo71P+nwF/8eaN33PGarFCMC0inMisuTJR0cTdeSKQsbr5jKdUdWLvHDZRFzWQOEixOmfdA/o6WiO2Boou/cSvvrvwcEElg7pXP+GKYDGwa8rAx+XOJlEnrwQV1QA6ydvVqur3m7S1zPGQxRFqxNgUD+xVqnTI+Zj19v0EauP4gcPdjzqmG6L2v/xmKsopCFtpYObRpcfqXCpg9mU/xKuts3fIqBu5k9hUPEgLzbP3K0cj69HtibUjd2TVXbMXJpc7iGWkuImB+8lU+pRtAyXPu+3k6bF1ZaKQ/ty/6WY4KylTXKA8JG4W1Vpo0MrJiZl76wGq7aUk; 24:UP1IZfCD0Nm0KUr1k9W2a/t8UXfOg889V7YnT3eWKdeskU4XweuKrT3CvkDg0NolA86VWyCBR179JSbSrCwgbAl9WPUpMPif8q62PEd1XbA= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; BN3PR0701MB1267; 7:8NyOIuk16q22aMLTSOLBmM1f/YXwXSnGg43oyq3NHDdqrzf0GDG+O4SfpK6lyyb/rhJPeMGStuxzTLfVTufgngDe85nNAXheo7daFxivhAZvAUpBbCj1Nw7TOabAw8vkLccJxWn+V+qHVpxJLOQk2bUe9sakzFy06PSSbeEgFmm/QFwz2ENSNcPSHxbq5gteA/syZyqFsttF8Wxsjc4/9AoFIGf++gqU9V3L3kFgDxuah3bld8xxMqPzJB6UFLRYhxmCN2qd1FPzePKKJVNHM5hzGMBLNkXkMqmEvvdYXDD7PGLHox4+emDJgvyJSehgmjQwUAZRdDUENMtTNxw9Nw== X-OriginatorOrg: caviumnetworks.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 04 Jun 2017 12:00:49.3404 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: BN3PR0701MB1267 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20170604_050112_061988_4DA2894D X-CRM114-Status: UNSURE ( 9.89 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Andrew Pinski , Heiko Carstens , Chris Metcalf , Yury Norov , philipp.tomsich@theobroma-systems.com, Joseph Myers , zhouchengming1@huawei.com, Steve Ellcey , Prasun.Kapoor@caviumnetworks.com, Andreas Schwab , agraf@suse.de, szabolcs.nagy@arm.com, geert@linux-m68k.org, Adam Borowski , manuel.montezelo@gmail.com, Chris Metcalf , Andrew Pinski , linyongting@huawei.com, klimov.linux@gmail.com, broonie@kernel.org, Bamvor Zhangjian , Maxim Kuvyrkov , Florian Weimer , Nathan_Lynch@mentor.com, Ramana Radhakrishnan , schwidefsky@de.ibm.com, davem@davemloft.net, christoph.muellner@theobroma-systems.com Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP All new 32-bit architectures should have 64-bit off_t type, but existing architectures has 32-bit ones. To handle it, new config option is added to arch/Kconfig that defaults ARCH_32BIT_OFF_T to be disabled for non-64 bit architectures. All existing 32-bit architectures enable it explicitly here. New option affects force_o_largefile() behaviour. Namely, if off_t is 64-bits long, we have no reason to reject user to open big files. Note that even if architectures has only 64-bit off_t in the kernel (arc, c6x, h8300, hexagon, metag, nios2, openrisc, tile32 and unicore32), a libc may use 32-bit off_t, and therefore want to limit the file size to 4GB unless specified differently in the open flags. Signed-off-by: Yury Norov Acked-by: Arnd Bergmann --- arch/Kconfig | 4 ++++ arch/arc/Kconfig | 1 + arch/arm/Kconfig | 1 + arch/blackfin/Kconfig | 1 + arch/cris/Kconfig | 1 + arch/frv/Kconfig | 1 + arch/h8300/Kconfig | 1 + arch/hexagon/Kconfig | 1 + arch/m32r/Kconfig | 1 + arch/m68k/Kconfig | 1 + arch/metag/Kconfig | 1 + arch/microblaze/Kconfig | 1 + arch/mips/Kconfig | 1 + arch/mn10300/Kconfig | 1 + arch/nios2/Kconfig | 1 + arch/openrisc/Kconfig | 1 + arch/parisc/Kconfig | 1 + arch/powerpc/Kconfig | 1 + arch/score/Kconfig | 1 + arch/sh/Kconfig | 1 + arch/sparc/Kconfig | 1 + arch/tile/Kconfig | 1 + arch/unicore32/Kconfig | 1 + arch/x86/Kconfig | 1 + arch/x86/um/Kconfig | 1 + arch/xtensa/Kconfig | 1 + include/linux/fcntl.h | 2 +- 27 files changed, 30 insertions(+), 1 deletion(-) diff --git a/arch/Kconfig b/arch/Kconfig index 3eac97a4c7b3..7adcd88529ef 100644 --- a/arch/Kconfig +++ b/arch/Kconfig @@ -246,6 +246,10 @@ config ARCH_THREAD_STACK_ALLOCATOR config ARCH_WANTS_DYNAMIC_TASK_STRUCT bool +config ARCH_32BIT_OFF_T + bool + depends on !64BIT + config HAVE_REGS_AND_STACK_ACCESS_API bool help diff --git a/arch/arc/Kconfig b/arch/arc/Kconfig index a5459698f0ee..cab9c53e0354 100644 --- a/arch/arc/Kconfig +++ b/arch/arc/Kconfig @@ -11,6 +11,7 @@ config ARC select ARC_TIMERS select ARCH_HAS_SG_CHAIN select ARCH_SUPPORTS_ATOMIC_RMW if ARC_HAS_LLSC + select ARCH_32BIT_OFF_T select BUILDTIME_EXTABLE_SORT select CLONE_BACKWARDS select COMMON_CLK diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index 4c1a35f15838..39e685e591ad 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig @@ -1,6 +1,7 @@ config ARM bool default y + select ARCH_32BIT_OFF_T select ARCH_CLOCKSOURCE_DATA select ARCH_HAS_DEBUG_VIRTUAL select ARCH_HAS_DEVMEM_IS_ALLOWED diff --git a/arch/blackfin/Kconfig b/arch/blackfin/Kconfig index 3c1bd640042a..26418e78f06b 100644 --- a/arch/blackfin/Kconfig +++ b/arch/blackfin/Kconfig @@ -12,6 +12,7 @@ config RWSEM_XCHGADD_ALGORITHM config BLACKFIN def_bool y + select ARCH_32BIT_OFF_T select HAVE_ARCH_KGDB select HAVE_ARCH_TRACEHOOK select HAVE_DYNAMIC_FTRACE diff --git a/arch/cris/Kconfig b/arch/cris/Kconfig index 71b758dc3a96..8c059f07ddb6 100644 --- a/arch/cris/Kconfig +++ b/arch/cris/Kconfig @@ -50,6 +50,7 @@ config LOCKDEP_SUPPORT config CRIS bool default y + select ARCH_32BIT_OFF_T select HAVE_IDE select GENERIC_ATOMIC64 select HAVE_UID16 diff --git a/arch/frv/Kconfig b/arch/frv/Kconfig index eefd9a4ed156..2f1490448fd4 100644 --- a/arch/frv/Kconfig +++ b/arch/frv/Kconfig @@ -1,6 +1,7 @@ config FRV bool default y + select ARCH_32BIT_OFF_T select HAVE_IDE select HAVE_ARCH_TRACEHOOK select HAVE_PERF_EVENTS diff --git a/arch/h8300/Kconfig b/arch/h8300/Kconfig index 3ae852507e57..29bbcb1c8676 100644 --- a/arch/h8300/Kconfig +++ b/arch/h8300/Kconfig @@ -1,5 +1,6 @@ config H8300 def_bool y + select ARCH_32BIT_OFF_T select GENERIC_ATOMIC64 select HAVE_UID16 select VIRT_TO_BUS diff --git a/arch/hexagon/Kconfig b/arch/hexagon/Kconfig index 1941e4baaee6..bbcea8c33e44 100644 --- a/arch/hexagon/Kconfig +++ b/arch/hexagon/Kconfig @@ -3,6 +3,7 @@ comment "Linux Kernel Configuration for Hexagon" config HEXAGON def_bool y + select ARCH_32BIT_OFF_T select HAVE_OPROFILE # Other pending projects/to-do items. # select HAVE_REGS_AND_STACK_ACCESS_API diff --git a/arch/m32r/Kconfig b/arch/m32r/Kconfig index 95474460b367..d6d19f6ba39d 100644 --- a/arch/m32r/Kconfig +++ b/arch/m32r/Kconfig @@ -1,6 +1,7 @@ config M32R bool default y + select ARCH_32BIT_OFF_T select HAVE_IDE select HAVE_OPROFILE select INIT_ALL_POSSIBLE diff --git a/arch/m68k/Kconfig b/arch/m68k/Kconfig index d140206d5d29..ed6f90ca2d31 100644 --- a/arch/m68k/Kconfig +++ b/arch/m68k/Kconfig @@ -1,6 +1,7 @@ config M68K bool default y + select ARCH_32BIT_OFF_T select ARCH_MIGHT_HAVE_PC_PARPORT if ISA select HAVE_IDE select HAVE_AOUT if MMU diff --git a/arch/metag/Kconfig b/arch/metag/Kconfig index 5b7a45d99cfb..c337192e3c3b 100644 --- a/arch/metag/Kconfig +++ b/arch/metag/Kconfig @@ -1,5 +1,6 @@ config METAG def_bool y + select ARCH_32BIT_OFF_T select EMBEDDED select GENERIC_ATOMIC64 select GENERIC_CLOCKEVENTS diff --git a/arch/microblaze/Kconfig b/arch/microblaze/Kconfig index 85885a501dce..643025c9f752 100644 --- a/arch/microblaze/Kconfig +++ b/arch/microblaze/Kconfig @@ -1,5 +1,6 @@ config MICROBLAZE def_bool y + select ARCH_32BIT_OFF_T select ARCH_HAS_GCOV_PROFILE_ALL select ARCH_MIGHT_HAVE_PC_PARPORT select ARCH_WANT_IPC_PARSE_VERSION diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig index 6abcef37ce06..4a50d1e6f3ee 100644 --- a/arch/mips/Kconfig +++ b/arch/mips/Kconfig @@ -1,6 +1,7 @@ config MIPS bool default y + select ARCH_32BIT_OFF_T if !64BIT select ARCH_BINFMT_ELF_STATE select ARCH_CLOCKSOURCE_DATA select ARCH_DISCARD_MEMBLOCK diff --git a/arch/mn10300/Kconfig b/arch/mn10300/Kconfig index 38e3494bfb63..75f226e6e819 100644 --- a/arch/mn10300/Kconfig +++ b/arch/mn10300/Kconfig @@ -1,5 +1,6 @@ config MN10300 def_bool y + select ARCH_32BIT_OFF_T select HAVE_EXIT_THREAD select HAVE_OPROFILE select HAVE_UID16 diff --git a/arch/nios2/Kconfig b/arch/nios2/Kconfig index a72d5f0de692..c6f19d7fbfd1 100644 --- a/arch/nios2/Kconfig +++ b/arch/nios2/Kconfig @@ -1,5 +1,6 @@ config NIOS2 def_bool y + select ARCH_32BIT_OFF_T select CLKSRC_OF select GENERIC_ATOMIC64 select GENERIC_CLOCKEVENTS diff --git a/arch/openrisc/Kconfig b/arch/openrisc/Kconfig index 1e95920b0737..5539d0842724 100644 --- a/arch/openrisc/Kconfig +++ b/arch/openrisc/Kconfig @@ -5,6 +5,7 @@ config OPENRISC def_bool y + select ARCH_32BIT_OFF_T select OF select OF_EARLY_FLATTREE select IRQ_DOMAIN diff --git a/arch/parisc/Kconfig b/arch/parisc/Kconfig index 531da9eb8f43..a9f430b86103 100644 --- a/arch/parisc/Kconfig +++ b/arch/parisc/Kconfig @@ -1,5 +1,6 @@ config PARISC def_bool y + select ARCH_32BIT_OFF_T if !64BIT select ARCH_MIGHT_HAVE_PC_PARPORT select HAVE_IDE select HAVE_OPROFILE diff --git a/arch/powerpc/Kconfig b/arch/powerpc/Kconfig index a81460b5d6d6..4480d9c0bdb1 100644 --- a/arch/powerpc/Kconfig +++ b/arch/powerpc/Kconfig @@ -130,6 +130,7 @@ config PPC # # Please keep this list sorted alphabetically. # + select ARCH_32BIT_OFF_T if PPC32 select ARCH_HAS_DEVMEM_IS_ALLOWED select ARCH_HAS_DMA_SET_COHERENT_MASK select ARCH_HAS_ELF_RANDOMIZE diff --git a/arch/score/Kconfig b/arch/score/Kconfig index 507d63181389..0a9484bbddf5 100644 --- a/arch/score/Kconfig +++ b/arch/score/Kconfig @@ -2,6 +2,7 @@ menu "Machine selection" config SCORE def_bool y + select ARCH_32BIT_OFF_T select GENERIC_IRQ_SHOW select GENERIC_IOMAP select GENERIC_ATOMIC64 diff --git a/arch/sh/Kconfig b/arch/sh/Kconfig index ee086958b2b2..1f99eb3212d2 100644 --- a/arch/sh/Kconfig +++ b/arch/sh/Kconfig @@ -56,6 +56,7 @@ config SUPERH config SUPERH32 def_bool ARCH = "sh" + select ARCH_32BIT_OFF_T select HAVE_KPROBES select HAVE_KRETPROBES select HAVE_IOREMAP_PROT if MMU && !X2TLB diff --git a/arch/sparc/Kconfig b/arch/sparc/Kconfig index 1a83ec901446..617b7aabddeb 100644 --- a/arch/sparc/Kconfig +++ b/arch/sparc/Kconfig @@ -48,6 +48,7 @@ config SPARC config SPARC32 def_bool !64BIT + select ARCH_32BIT_OFF_T select GENERIC_ATOMIC64 select CLZ_TAB select HAVE_UID16 diff --git a/arch/tile/Kconfig b/arch/tile/Kconfig index 4583c0320059..845dcbd8235e 100644 --- a/arch/tile/Kconfig +++ b/arch/tile/Kconfig @@ -3,6 +3,7 @@ config TILE def_bool y + select ARCH_32BIT_OFF_T if !64BIT select ARCH_HAS_DEVMEM_IS_ALLOWED select ARCH_HAVE_NMI_SAFE_CMPXCHG select ARCH_WANT_FRAME_POINTERS diff --git a/arch/unicore32/Kconfig b/arch/unicore32/Kconfig index 0a3bfd1fefcd..9629fd827d6b 100644 --- a/arch/unicore32/Kconfig +++ b/arch/unicore32/Kconfig @@ -1,5 +1,6 @@ config UNICORE32 def_bool y + select ARCH_32BIT_OFF_T select ARCH_HAS_DEVMEM_IS_ALLOWED select ARCH_MIGHT_HAVE_PC_PARPORT select ARCH_MIGHT_HAVE_PC_SERIO diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig index f00fa5176f72..bd343f8a45ad 100644 --- a/arch/x86/Kconfig +++ b/arch/x86/Kconfig @@ -43,6 +43,7 @@ config X86 select ACPI_LEGACY_TABLES_LOOKUP if ACPI select ACPI_SYSTEM_POWER_STATES_SUPPORT if ACPI select ANON_INODES + select ARCH_32BIT_OFF_T if X86_32 select ARCH_CLOCKSOURCE_DATA select ARCH_DISCARD_MEMBLOCK select ARCH_HAS_ACPI_TABLE_UPGRADE if ACPI diff --git a/arch/x86/um/Kconfig b/arch/x86/um/Kconfig index ed56a1c4ae73..8436bcd9beba 100644 --- a/arch/x86/um/Kconfig +++ b/arch/x86/um/Kconfig @@ -21,6 +21,7 @@ config 64BIT config X86_32 def_bool !64BIT select HAVE_AOUT + select ARCH_32BIT_OFF_T select ARCH_WANT_IPC_PARSE_VERSION select MODULES_USE_ELF_REL select CLONE_BACKWARDS diff --git a/arch/xtensa/Kconfig b/arch/xtensa/Kconfig index f4126cf997a4..683f24e0b6a7 100644 --- a/arch/xtensa/Kconfig +++ b/arch/xtensa/Kconfig @@ -3,6 +3,7 @@ config ZONE_DMA config XTENSA def_bool y + select ARCH_32BIT_OFF_T select ARCH_WANT_FRAME_POINTERS select ARCH_WANT_IPC_PARSE_VERSION select BUILDTIME_EXTABLE_SORT diff --git a/include/linux/fcntl.h b/include/linux/fcntl.h index 1b48d9c9a561..297993c92490 100644 --- a/include/linux/fcntl.h +++ b/include/linux/fcntl.h @@ -11,7 +11,7 @@ O_NOATIME | O_CLOEXEC | O_PATH | __O_TMPFILE) #ifndef force_o_largefile -#define force_o_largefile() (BITS_PER_LONG != 32) +#define force_o_largefile() (!IS_ENABLED(CONFIG_ARCH_32BIT_OFF_T)) #endif #if BITS_PER_LONG == 32