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=-7.5 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, MENTIONS_GIT_HOSTING,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=unavailable 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 C8F75C49ED7 for ; Fri, 13 Sep 2019 09:26:00 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 98A72206A4 for ; Fri, 13 Sep 2019 09:26:00 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="CnyL27c/" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 98A72206A4 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=suse.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org 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:In-Reply-To:MIME-Version:Date: Message-ID:From:References:To:Subject:Reply-To:Content-ID:Content-Description :Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=ywaA8W0FvaEI1YxJe4SLtO7KlZgnaUDwn2/y+67G1tU=; b=CnyL27c/eWXkPJ SyoY8YHklRb7fWDUfHuc7PvG184XPiDFHSH+0d2Frf9qefisgrQ0q+IQ8+nH0BFVy7Fq/AqPQaxKf 0hpJohBbgY320PCYh/l+gTs/w0sHirSo3kn0Eyv4DMRTzdUNdSFYa1iG+bHyfF8WsSwQmCSY/lI3T DdXgxAnSArL03hMhfmLpdUAlgdm/4TG/XOE+pODp9Nkg2r5sa/Pwzknn/ZoqilZ0AIjserdTvlS3F BAa8w58tP0w5HUCM79YFZZeyIUYwEr1IHhwLD7p2+Kt74IHHlNpvFe7wpiKnSlV/VuqZ+y0Z9M/Ha Il4NJOisqfewInlrON2Q==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.2 #3 (Red Hat Linux)) id 1i8hpx-00009s-LN; Fri, 13 Sep 2019 09:25:53 +0000 Received: from mx2.suse.de ([195.135.220.15] helo=mx1.suse.de) by bombadil.infradead.org with esmtps (Exim 4.92.2 #3 (Red Hat Linux)) id 1i8hpt-000095-BP; Fri, 13 Sep 2019 09:25:51 +0000 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.220.254]) by mx1.suse.de (Postfix) with ESMTP id 0C277AE8B; Fri, 13 Sep 2019 09:25:46 +0000 (UTC) Subject: Re: [PATCH v5 0/4] Raspberry Pi 4 DMA addressing support To: Stefan Wahren , catalin.marinas@arm.com, marc.zyngier@arm.com, Matthias Brugger , robh+dt@kernel.org, linux-mm@kvack.org, linux-arm-kernel@lists.infradead.org, linux-riscv@lists.infradead.org, hch@lst.de, Nicolas Saenz Julienne References: <20190909095807.18709-1-nsaenzjulienne@suse.de> <5a8af6e9-6b90-ce26-ebd7-9ee626c9fa0e@gmx.net> <3f9af46e-2e1a-771f-57f2-86a53caaf94a@suse.com> <09f82f88-a13a-b441-b723-7bb061a2f1e3@gmail.com> <2c3e1ef3-0dba-9f79-52e2-314b6b500e14@gmx.net> <4a6f965b-c988-5839-169f-9f24a0e7a567@suse.com> <48a6b72d-d554-b563-5ed6-9a79db5fb4ab@gmx.net> From: Matthias Brugger Openpgp: preference=signencrypt Autocrypt: addr=mbrugger@suse.com; prefer-encrypt=mutual; keydata= mQINBFP1zgUBEAC21D6hk7//0kOmsUrE3eZ55kjc9DmFPKIz6l4NggqwQjBNRHIMh04BbCMY fL3eT7ZsYV5nur7zctmJ+vbszoOASXUpfq8M+S5hU2w7sBaVk5rpH9yW8CUWz2+ZpQXPJcFa OhLZuSKB1F5JcvLbETRjNzNU7B3TdS2+zkgQQdEyt7Ij2HXGLJ2w+yG2GuR9/iyCJRf10Okq gTh//XESJZ8S6KlOWbLXRE+yfkKDXQx2Jr1XuVvM3zPqH5FMg8reRVFsQ+vI0b+OlyekT/Xe 0Hwvqkev95GG6x7yseJwI+2ydDH6M5O7fPKFW5mzAdDE2g/K9B4e2tYK6/rA7Fq4cqiAw1+u EgO44+eFgv082xtBez5WNkGn18vtw0LW3ESmKh19u6kEGoi0WZwslCNaGFrS4M7OH+aOJeqK fx5dIv2CEbxc6xnHY7dwkcHikTA4QdbdFeUSuj4YhIZ+0QlDVtS1QEXyvZbZky7ur9rHkZvP ZqlUsLJ2nOqsmahMTIQ8Mgx9SLEShWqD4kOF4zNfPJsgEMB49KbS2o9jxbGB+JKupjNddfxZ HlH1KF8QwCMZEYaTNogrVazuEJzx6JdRpR3sFda/0x5qjTadwIW6Cl9tkqe2h391dOGX1eOA 1ntn9O/39KqSrWNGvm+1raHK+Ev1yPtn0Wxn+0oy1tl67TxUjQARAQABtCRNYXR0aGlhcyBC cnVnZ2VyIDxtYnJ1Z2dlckBzdXNlLmNvbT6JAjgEEwECACIFAlV6iM0CGwMGCwkIBwMCBhUI AgkKCwQWAgMBAh4BAheAAAoJENkUC7JWEwLx6isQAIMGBgJnFWovDS7ClZtjz1LgoY8skcMU ghUZY4Z/rwwPqmMPbY8KYDdOFA+kMTEiAHOR+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n1wI8BcqCwWk0 wqYEBbB4GRUkCKyhB5fnQ4/7/XUCtXRy/585N8mPT8rAVclppiHctRA0gssE3GRKuEIuXx1S DnchsfHg18gCCrEtYZ9czwNjVoV1Tv2lpzTTk+6HEJaQpMnPeAKbOeehq3gYKcvmDL+bRCTj mXg8WrBZdUuj0BCDYqneaUgVnp+wQogA3mHGVs281v1XZmjlsVmM9Y8VPE614zSiZQBL5Cin BTTI8ssYlV/aIKYi0dxRcj6vYnAfUImOsdZ5AQja5xIqw1rwWWUOYb99 Message-ID: <2fcc5ad6-fa90-6565-e75c-d20b46965733@suse.com> Date: Fri, 13 Sep 2019 11:25:43 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.8.0 MIME-Version: 1.0 In-Reply-To: <48a6b72d-d554-b563-5ed6-9a79db5fb4ab@gmx.net> Content-Language: en-US X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190913_022549_689347_70E427C7 X-CRM114-Status: GOOD ( 28.78 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: f.fainelli@gmail.com, robin.murphy@arm.com, linux-kernel@vger.kernel.org, linux-rpi-kernel@lists.infradead.org, phill@raspberrypi.org, will@kernel.org, m.szyprowski@samsung.com Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org On 13/09/2019 10:50, Stefan Wahren wrote: > Am 13.09.19 um 10:09 schrieb Matthias Brugger: >> >> On 12/09/2019 21:32, Stefan Wahren wrote: >>> Am 12.09.19 um 19:18 schrieb Matthias Brugger: >>>> On 10/09/2019 11:27, Matthias Brugger wrote: >>>>> On 09/09/2019 21:33, Stefan Wahren wrote: >>>>>> Hi Nicolas, >>>>>> >>>>>> Am 09.09.19 um 11:58 schrieb Nicolas Saenz Julienne: >>>>>>> Hi all, >>>>>>> this series attempts to address some issues we found while bringing up >>>>>>> the new Raspberry Pi 4 in arm64 and it's intended to serve as a follow >>>>>>> up of these discussions: >>>>>>> v4: https://lkml.org/lkml/2019/9/6/352 >>>>>>> v3: https://lkml.org/lkml/2019/9/2/589 >>>>>>> v2: https://lkml.org/lkml/2019/8/20/767 >>>>>>> v1: https://lkml.org/lkml/2019/7/31/922 >>>>>>> RFC: https://lkml.org/lkml/2019/7/17/476 >>>>>>> >>>>>>> The new Raspberry Pi 4 has up to 4GB of memory but most peripherals can >>>>>>> only address the first GB: their DMA address range is >>>>>>> 0xc0000000-0xfc000000 which is aliased to the first GB of physical >>>>>>> memory 0x00000000-0x3c000000. Note that only some peripherals have these >>>>>>> limitations: the PCIe, V3D, GENET, and 40-bit DMA channels have a wider >>>>>>> view of the address space by virtue of being hooked up trough a second >>>>>>> interconnect. >>>>>>> >>>>>>> Part of this is solved on arm32 by setting up the machine specific >>>>>>> '.dma_zone_size = SZ_1G', which takes care of reserving the coherent >>>>>>> memory area at the right spot. That said no buffer bouncing (needed for >>>>>>> dma streaming) is available at the moment, but that's a story for >>>>>>> another series. >>>>>>> >>>>>>> Unfortunately there is no such thing as 'dma_zone_size' in arm64. Only >>>>>>> ZONE_DMA32 is created which is interpreted by dma-direct and the arm64 >>>>>>> arch code as if all peripherals where be able to address the first 4GB >>>>>>> of memory. >>>>>>> >>>>>>> In the light of this, the series implements the following changes: >>>>>>> >>>>>>> - Create both DMA zones in arm64, ZONE_DMA will contain the first 1G >>>>>>> area and ZONE_DMA32 the rest of the 32 bit addressable memory. So far >>>>>>> the RPi4 is the only arm64 device with such DMA addressing limitations >>>>>>> so this hardcoded solution was deemed preferable. >>>>>>> >>>>>>> - Properly set ARCH_ZONE_DMA_BITS. >>>>>>> >>>>>>> - Reserve the CMA area in a place suitable for all peripherals. >>>>>>> >>>>>>> This series has been tested on multiple devices both by checking the >>>>>>> zones setup matches the expectations and by double-checking physical >>>>>>> addresses on pages allocated on the three relevant areas GFP_DMA, >>>>>>> GFP_DMA32, GFP_KERNEL: >>>>>>> >>>>>>> - On an RPi4 with variations on the ram memory size. But also forcing >>>>>>> the situation where all three memory zones are nonempty by setting a 3G >>>>>>> ZONE_DMA32 ceiling on a 4G setup. Both with and without NUMA support. >>>>>>> >>>>>> i like to test this series on Raspberry Pi 4 and i have some questions >>>>>> to get arm64 running: >>>>>> >>>>>> Do you use U-Boot? Which tree? >>>>> If you want to use U-Boot, try v2019.10-rc4, it should have everything you need >>>>> to boot your kernel. >>>>> >>>> Ok, here is a thing. In the linux kernel we now use bcm2711 as SoC name, but the >>>> RPi4 devicetree provided by the FW uses mostly bcm2838. >>> Do you mean the DTB provided at runtime? >>> >>> You mean the merged U-Boot changes, doesn't work with my Raspberry Pi >>> series? >>> >>>> U-Boot in its default >>>> config uses the devicetree provided by the FW, mostly because this way you don't >>>> have to do anything to find out how many RAM you really have. Secondly because >>>> this will allow us, in the near future, to have one U-boot binary for both RPi3 >>>> and RPi4 (and as a side effect one binary for RPi1 and RPi2). >>>> >>>> Anyway, I found at least, that the following compatibles need to be added: >>>> >>>> "brcm,bcm2838-cprman" >>>> "brcm,bcm2838-gpio" >>>> >>>> Without at least the cprman driver update, you won't see anything. >>>> >>>> "brcm,bcm2838-rng200" is also a candidate. >>>> >>>> I also suppose we will need to add "brcm,bcm2838" to >>>> arch/arm/mach-bcm/bcm2711.c, but I haven't verified this. >>> How about changing this in the downstream kernel? Which is much easier. >> I'm not sure I understand what you want to say. My goal is to use the upstream >> kernel with the device tree blob provided by the FW. > > The device tree blob you are talking is defined in this repository: > > https://github.com/raspberrypi/linux > > So the word FW is misleading to me. > No, it's part of https://github.com/raspberrypi/firmware.git file boot/bcm2711-rpi-4-b.dtb >> If you talk about the >> downstream kernel, I suppose you mean we should change this in the FW DT blob >> and in the downstream kernel. That would work for me. >> >> Did I understand you correctly? > > Yes > > So i suggest to add the upstream compatibles into the repo mentioned above. > > Sorry, but in case you decided as a U-Boot developer to be compatible > with a unreviewed DT, we also need to make U-Boot compatible with > upstream and downstream DT blobs. > Well RPi3 is working with the DT blob provided by the FW, as I mentioned earlier if we can use this DTB we can work towards one binary that can boot both RPi3 and RPi4. On the other hand we can rely on the FW to detect the amount of memory our RPi4 has. That said, I agree that we should make sure that U-Boot can boot with both DTBs, the upstream one and the downstream. Now the question is how to get to this. I'm a bit puzzled that by talking about "unreviewed DT" you insinuate that bcm2711 compatible is already reviewed and can't be changed. From what I can see none of these compatibles got merged for now, so we are still at time to change them. Apart from the point Florian made, to stay consistent with the RPi SoC naming, it will save us work, both in the kernel and in U-Boot, as we would need to add both compatibles to the code-base. Regards, Matthias >> >>>> Regards, >>>> Matthias >>>> >>>>> Regards, >>>>> Matthias >>>>> >>>>>> Are there any config.txt tweaks necessary? >>>>>> >>>>>> >>>>> _______________________________________________ >>>>> linux-arm-kernel mailing list >>>>> linux-arm-kernel@lists.infradead.org >>>>> http://lists.infradead.org/mailman/listinfo/linux-arm-kernel >>>>> >>>> _______________________________________________ >>>> linux-arm-kernel mailing list >>>> linux-arm-kernel@lists.infradead.org >>>> http://lists.infradead.org/mailman/listinfo/linux-arm-kernel >>> > _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel