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_NONE,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 66DF9C43462 for ; Fri, 16 Apr 2021 14:10:47 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id E0C24611AC for ; Fri, 16 Apr 2021 14:10:46 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org E0C24611AC 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 5BE898D0002; Fri, 16 Apr 2021 10:10:46 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 56EE38D0001; Fri, 16 Apr 2021 10:10:46 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 40F6B8D0002; Fri, 16 Apr 2021 10:10:46 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0227.hostedemail.com [216.40.44.227]) by kanga.kvack.org (Postfix) with ESMTP id 201DD8D0001 for ; Fri, 16 Apr 2021 10:10:46 -0400 (EDT) Received: from smtpin16.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay05.hostedemail.com (Postfix) with ESMTP id B3ACF18045E74 for ; Fri, 16 Apr 2021 14:10:45 +0000 (UTC) X-FDA: 78038416050.16.6FE6190 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by imf09.hostedemail.com (Postfix) with ESMTP id 8092F600012C for ; Fri, 16 Apr 2021 14:10:41 +0000 (UTC) Received: by mail.kernel.org (Postfix) with ESMTPSA id A7BA0611AC for ; Fri, 16 Apr 2021 14:10:42 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1618582242; bh=1s9sCrJo44Veolfwl+MwQWl66gowBJVDh4jCcMWmw20=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=bWtljR/0v+ciclhWmYZDIUGhhvFJ3qQ7nO0uU82MghhOsGFdSMyacApx9Rv+nHL6X W5cY5QnPwP6g7dxd13lON+NP7T3wxEgswnDncwfQXbUpDa1noe9/ic1qeaxTeqr1An xJUGxVeiTwbDQol4BcT+uJeJ/K8GtjgPzMatA+QGLBn8/pwaCrhafWYek6SKXGeGJX JrnAkRBsacpGTrsZXVT6wqIi5rnqa1PtXSpagwrGhkYyDEvybabUi7RBZVXZcudA+H 4dZgdBI6yZkxxw1SMBUj5RKBCe9Uqk2xt0sX7dm9fywiRJ0wfW8Bx5Y3FStVzaPeVS VyQ7HbK3kn2jA== Received: by mail-wm1-f42.google.com with SMTP id k4-20020a7bc4040000b02901331d89fb83so2187191wmi.5 for ; Fri, 16 Apr 2021 07:10:42 -0700 (PDT) X-Gm-Message-State: AOAM5332RRBcz8B8nSFZo0ayeGCvpb/USWx+MgAnCdf4EFAeGDCz/rEI r4d6sOrutjI6hdO9T2ofPCaL88J7RMQc3Io5goA= X-Google-Smtp-Source: ABdhPJwer78kcpt2KUTk7pLNWv4YpxxYqG4ncdMLFchwkUndSOMZjtA8z9tZUxzlPor4R9hASXWQZTamma1KWyeXMwk= X-Received: by 2002:a7b:c14a:: with SMTP id z10mr8250595wmi.75.1618582241293; Fri, 16 Apr 2021 07:10:41 -0700 (PDT) MIME-Version: 1.0 References: <20210409185105.188284-3-willy@infradead.org> <202104100656.N7EVvkNZ-lkp@intel.com> <20210410024313.GX2531743@casper.infradead.org> <20210410082158.79ad09a6@carbon> In-Reply-To: From: Arnd Bergmann Date: Fri, 16 Apr 2021 16:10:37 +0200 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: Bogus struct page layout on 32-bit To: Grygorii Strashko Cc: Ilias Apalodimas , Jesper Dangaard Brouer , Christoph Hellwig , Matthew Wilcox , kernel test robot , Linux-MM , kbuild-all@lists.01.org, clang-built-linux@googlegroups.com, open list , linux-fsdevel@vger.kernel.org, Michael Ellerman , Benjamin Herrenschmidt , Paul Mackerras , linuxppc-dev@lists.ozlabs.org, Linux ARM , "David S. Miller" , Matteo Croce , "netdev@vger.kernel.org" Content-Type: text/plain; charset="UTF-8" X-Rspamd-Server: rspam01 X-Rspamd-Queue-Id: 8092F600012C X-Stat-Signature: s4m8sbkdmkjmajheeo6c5tn5cndo8jj3 Received-SPF: none (kernel.org>: No applicable sender policy available) receiver=imf09; identity=mailfrom; envelope-from=""; helo=mail.kernel.org; client-ip=198.145.29.99 X-HE-DKIM-Result: pass/pass X-HE-Tag: 1618582241-706825 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 Fri, Apr 16, 2021 at 11:27 AM 'Grygorii Strashko' via Clang Built Linux wrote: > On 10/04/2021 11:52, Ilias Apalodimas wrote: > > +CC Grygorii for the cpsw part as Ivan's email is not valid anymore > The TI platforms am3/4/5 (cpsw) and Keystone 2 (netcp) can do only 32bit DMA even in case of LPAE (dma-ranges are used). > Originally, as I remember, CONFIG_ARCH_DMA_ADDR_T_64BIT has not been selected for the LPAE case > on TI platforms and the fact that it became set is the result of multi-paltform/allXXXconfig/DMA > optimizations and unification. > (just checked - not set in 4.14) > > Probable commit 4965a68780c5 ("arch: define the ARCH_DMA_ADDR_T_64BIT config symbol in lib/Kconfig"). I completely missed this change in the past, and I don't really agree with it either. Most 32-bit Arm platforms are in fact limited to 32-bit DMA, even when they have MMIO or RAM areas above the 4GB boundary that require LPAE. > The TI drivers have been updated, finally to accept ARCH_DMA_ADDR_T_64BIT=y by using > things like (__force u32) for example. > > Honestly, I've done sanity check of CPSW with LPAE=y (ARCH_DMA_ADDR_T_64BIT=y) very long time ago. This is of course a good idea, drivers should work with any combination of 32-bit or 64-bit phys_addr_t and dma_addr_t. Arnd