From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.0 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 05562C433ED for ; Wed, 21 Apr 2021 08:58:42 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 84D1C6143D for ; Wed, 21 Apr 2021 08:58:41 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 84D1C6143D Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id E3B036B006C; Wed, 21 Apr 2021 04:58:40 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id DEA836B006E; Wed, 21 Apr 2021 04:58:40 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id C66C46B0070; Wed, 21 Apr 2021 04:58:40 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0139.hostedemail.com [216.40.44.139]) by kanga.kvack.org (Postfix) with ESMTP id AA70D6B006C for ; Wed, 21 Apr 2021 04:58:40 -0400 (EDT) Received: from smtpin09.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay02.hostedemail.com (Postfix) with ESMTP id 5F8303658 for ; Wed, 21 Apr 2021 08:58:40 +0000 (UTC) X-FDA: 78055773600.09.1C5B884 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by imf12.hostedemail.com (Postfix) with ESMTP id D531113A for ; Wed, 21 Apr 2021 08:58:31 +0000 (UTC) Received: by mail.kernel.org (Postfix) with ESMTPSA id D77C861448 for ; Wed, 21 Apr 2021 08:58:38 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1618995518; bh=64KJf6xIhQSnl3PhQoQ0a9YdaBe+gMwA8Np6LwW1+/4=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=KspKrNpocGC+THW2FQf8l/RTxYj9VsuAMN9o6fRqaCIHROlddiUnVoGVbSJevcK8P t9Ih4ay4gNZRHVDqglHOGunFJvorx346JxWj8TRSdxkGT0Mx+bIg6kSOy9/tw6wrli AyoCGd/Aj4lwDeEU4D5FwKzcgcMb/8X46RKGEXUG2g1sE3gyPvvaBF9LVNzp8ElJtH nxpWNiCTcCzxZsHmOA3b5MzE1AlJaFRQLBbGl79XxBJRzbOZ0HNJnsSBV2Azw6FIoW hMQ03qhaDP19GOcFUHxal2wg+Dsk2MwLLe7C5x4sfsipcA0LcpO/cD4GZh1Ilzc8Wj Fofb7CfADu1kg== Received: by mail-wm1-f52.google.com with SMTP id t14-20020a05600c198eb029012eeb3edfaeso825949wmq.2 for ; Wed, 21 Apr 2021 01:58:38 -0700 (PDT) X-Gm-Message-State: AOAM533ewFJd/MbdFmRImVgixr6glXYxznXfZ9KK2CkT3sAJuLYgpZnV cH6bIdQVgFOsmy1StHH6fGgcfucH/xA1AcuWQUw= X-Google-Smtp-Source: ABdhPJzfODrhPhGfivkqeugtVvYFeuZiRdEx50xM7G3CMPJPgDkMCFmpfx3SbcIBA3tmKParqz5KGFeTEwP9bSV2emc= X-Received: by 2002:a05:600c:2282:: with SMTP id 2mr8921317wmf.84.1618995517297; Wed, 21 Apr 2021 01:58:37 -0700 (PDT) MIME-Version: 1.0 References: <20210416230724.2519198-1-willy@infradead.org> <20210416230724.2519198-2-willy@infradead.org> <20210417024522.GP2531743@casper.infradead.org> <9f99b0a0-f1c1-f3b0-5f84-3a4bfc711725@synopsys.com> <20210420031029.GI2531743@casper.infradead.org> <8d0fce1c-be7c-1c9b-bf5c-0c531db496ac@synopsys.com> <5c41d562589b497ca3c1047e0e18b3a1@AcuMS.aculab.com> In-Reply-To: <5c41d562589b497ca3c1047e0e18b3a1@AcuMS.aculab.com> From: Arnd Bergmann Date: Wed, 21 Apr 2021 10:58:18 +0200 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH 1/2] mm: Fix struct page layout on 32-bit systems To: David Laight Cc: Vineet Gupta , Matthew Wilcox , "grygorii.strashko@ti.com" , "netdev@vger.kernel.org" , "ilias.apalodimas@linaro.org" , "linux-kernel@vger.kernel.org" , "linux-mips@vger.kernel.org" , "mhocko@kernel.org" , "linux-mm@kvack.org" , "mgorman@suse.de" , "brouer@redhat.com" , "mcroce@linux.microsoft.com" , "linux-snps-arc@lists.infradead.org" , "linuxppc-dev@lists.ozlabs.org" , "hch@lst.de" , "linux-arm-kernel@lists.infradead.org" Content-Type: text/plain; charset="UTF-8" X-Rspamd-Server: rspam03 X-Rspamd-Queue-Id: D531113A X-Stat-Signature: dzmq1r46ocpznodw3cxr9ag6s9badouz Received-SPF: none (kernel.org>: No applicable sender policy available) receiver=imf12; identity=mailfrom; envelope-from=""; helo=mail.kernel.org; client-ip=198.145.29.99 X-HE-DKIM-Result: pass/pass X-HE-Tag: 1618995511-357770 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Wed, Apr 21, 2021 at 10:43 AM David Laight wrote: > From: Arnd Bergmann Sent: 20 April 2021 22:20 > > On Tue, Apr 20, 2021 at 11:14 PM Vineet Gupta wrote: > > > On 4/20/21 12:07 AM, Arnd Bergmann wrote: > > > > > > > > > > which means that half the 32-bit architectures do this. This may > > > > cause more problems when arc and/or microblaze want to support > > > > 64-bit kernels and compat mode in the future on their latest hardware, > > > > as that means duplicating the x86 specific hacks we have for compat. > > > > > > > > What is alignof(u64) on 64-bit arc? > > > > > > $ echo 'int a = __alignof__(long long);' | arc64-linux-gnu-gcc -xc - > > > -Wall -S -o - | grep -A1 a: | tail -n 1 | cut -f 3 > > > 8 > > > > Ok, good. > > That test doesn't prove anything. > Try running on x86: > $ echo 'int a = __alignof__(long long);' | gcc -xc - -Wall -S -o - -m32 > a: > .long 8 Right, I had wondered about that one after I sent the email. > Using '__alignof__(struct {long long x;})' does give the expected 4. > > __alignof__() returns the preferred alignment, not the enforced > alignmnet - go figure. I checked the others as well now, and i386 is the only one that changed here: m68k still has '2', while arc/csky/h8300/microblaze/ nios2/or1k/sh/i386 all have '4' and the rest have '8'. Arnd