Received: by 2002:a25:e7d8:0:0:0:0:0 with SMTP id e207csp2205366ybh; Sun, 15 Mar 2020 21:51:16 -0700 (PDT) X-Google-Smtp-Source: ADFU+vu5sWVO4ryUO05L3arC4sBAPsr8DQD9XEZyOzEBnvxKXzXzi7eOBsKF5mF4nHF99gaVVXh8 X-Received: by 2002:aca:d50f:: with SMTP id m15mr15460194oig.19.1584334276357; Sun, 15 Mar 2020 21:51:16 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1584334276; cv=none; d=google.com; s=arc-20160816; b=X+Z5EynjVZQSELn38gI1T3OcdpHYDZ4aqMk4Qro8kz7CMbqj7nCIZHIwDMlTtd9KlI RhO7d97HpOQZ2ebQSV75qoC1LWUyaQQOMo/3Zww3xbpRoypTFL1SS0Gci4UMTV6ZfoJP qEQgZK+PecrQbJ4J9OjXqnxCTng+1NF0F5y3PisMLP9szxtJQz3a8ywdHHdnZngQzwSt qoGUKHiPWo4sun4Vfb1Y5k8FynXEnTejO+0bRYGcDhqJuRZeIVtTCUOoCfcdIy5/I7DJ e3Vb/SF2y3Wl2A/8qfeiVqT35qxlRPEgZhZ2KqWbiDlqJULE6fo988eP4HQSd7tVSqYe iicA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=uxCRLDZ0IkMQwqs0XVpLiauYQ/QOJLqTZsxTkwxRAyY=; b=jcFbRbJbhY+gPeOgbEszEZpbeQUfieB+2w5Ui7g0N0ZFcw7YopY/CSO+vySmQtHqa5 LxgBWtRwr9NZb3LdoqbRgCXbxFv825LZZUfBXCmZr2CxvVKS48B2VCViPrK0nnTlqg2f 0DNILzDbWCVVmlEm7SRU9yxhj6giTnwUnnJv+YDqHlzi47ml4ciS6dmGHcuUjUtD/NCX flN6Jp2iSVrUbGw9vKVnPhmS++Ba+YiyJ4Uic/Gl2Q7h+5Z/Ysx+j0OtXEiQPVy2hfjk iBL3hDfbXX5rnr72YNvagys38d6cCxsxfVEyXDVLAPutq8eIN3uZ8u/9V5AkiZEardG0 WkTQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@jms.id.au header.s=google header.b=WCFiOpu7; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id c6si9186417otm.298.2020.03.15.21.50.48; Sun, 15 Mar 2020 21:51:16 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@jms.id.au header.s=google header.b=WCFiOpu7; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729577AbgCPEuI (ORCPT + 99 others); Mon, 16 Mar 2020 00:50:08 -0400 Received: from mail-qk1-f196.google.com ([209.85.222.196]:45275 "EHLO mail-qk1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727626AbgCPEuI (ORCPT ); Mon, 16 Mar 2020 00:50:08 -0400 Received: by mail-qk1-f196.google.com with SMTP id c145so23965717qke.12; Sun, 15 Mar 2020 21:50:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=jms.id.au; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=uxCRLDZ0IkMQwqs0XVpLiauYQ/QOJLqTZsxTkwxRAyY=; b=WCFiOpu7CYhUUeWYfysTGcsR835PmVC/GV/aSKpxW+atVSjfK72AHRQ3T4uxqOHcMD ygmW8Xe+hhjuc+zVNNmvLKsWo6IouNiBJIMG761CPajmDfxY1qeBto+g8sv0AYq6KxZ+ VPtUbPtKq4E14TOu92UDlrkuAF1ZyA3vQ7wFg= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=uxCRLDZ0IkMQwqs0XVpLiauYQ/QOJLqTZsxTkwxRAyY=; b=FZzKmdD8f2csQapVKVI8eS2sT1cZi/+Hx4KQCFMbeYPeJ5nSrTPc0gFBbzY6wFATEK wjrM3cFCuDdPy+6I5WPQBzw2ntIkhMWLosjSpRKOhMaZrghqTWkTomtTyF9Ah4SfVoJW 3FdYUQ30gvSdqGhmpVx0iyMEhsCn8mtJgQ1vfEXE9hHvlac1ys572RKKd1/b82dzV35v AjoF9aIi/9BnOpEqY1R68agI+HizWoTWLSKZYAzopQ2uiPNPnVw9SXxn46oNqEX1gz7u 8lmAVcWzATRVe/P3IRrowewMXEjn/+r1Z20SpF3Msj1WQyT6gdhqFaRRJVBKNR+pL3H4 LzsQ== X-Gm-Message-State: ANhLgQ0gFwW7rOApDTfiVhMyCc2c2CZo02jUengkWr1y7nRSkLyxZoid IagC5ZuTwUFdFM4+jDIs3ZInfQQEYjU+RvCtx1tWjZVF X-Received: by 2002:a37:6e06:: with SMTP id j6mr24529985qkc.171.1584334207132; Sun, 15 Mar 2020 21:50:07 -0700 (PDT) MIME-Version: 1.0 References: <1579123790-6894-1-git-send-email-eajames@linux.ibm.com> <1579123790-6894-7-git-send-email-eajames@linux.ibm.com> <1a303336-9ffb-353f-efe3-7d45ed114fd0@linux.vnet.ibm.com> In-Reply-To: <1a303336-9ffb-353f-efe3-7d45ed114fd0@linux.vnet.ibm.com> From: Joel Stanley Date: Mon, 16 Mar 2020 04:49:55 +0000 Message-ID: Subject: Re: [PATCH v6 06/12] soc: aspeed: Add XDMA Engine Driver To: Arnd Bergmann Cc: Eddie James , linux-aspeed , "linux-kernel@vger.kernel.org" , DTML , Mark Rutland , Jason Cooper , Marc Zyngier , Rob Herring , Thomas Gleixner , Andrew Jeffery Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 10 Feb 2020 at 17:10, Eddie James wrote: > > > On 2/10/20 10:35 AM, Arnd Bergmann wrote: > > On Wed, Jan 15, 2020 at 10:31 PM Eddie James wrote: > >> The XDMA engine embedded in the AST2500 and AST2600 SOCs performs PCI > >> DMA operations between the SOC (acting as a BMC) and a host processor > >> in a server. > >> > >> This commit adds a driver to control the XDMA engine and adds functions > >> to initialize the hardware and memory and start DMA operations. > >> > >> Signed-off-by: Eddie James > > Hi Eddie, > > > > I'm missing the bigger picture in the description here, how does this fit into > > the PCIe endpoint framework and the dmaengine subsystem? > > > Hi, > > It doesn't fit into the PCIe endpoint framework. The XDMA engine > abstracts all the PCIe details away so the BMC cannot configure any of > the things the PCIe endpoint exposes. > > It also doesn't fit into the dmaengine subsystem due to the restriction > on the ast2500 (and maybe the ast2600) that the XDMA engine can only > access certain areas of physical memory. Also problematic would be > pausing/resuming/terminating transfers because the XDMA engine can't do > those things. > > > > > > Does the AST2500 show up as a PCIe device in the host, or do you just > > inject DMAs into the host and hope that bypasses the IOMMU? > > If it shows up as an endpoint, how does the endpoint driver link into the > > dma driver? > > > The AST2500 and AST2600 have two PCIe devices on them, so these will > show up on the host if the BMC enables both of them. Either or both can > also be disabled and therefore will not show up. On the host side, in > order to receive DMA transfers, its simply a matter of registering a PCI > device driver and allocating some coherent DMA.... Not sure about the > details of endpoints/dma client driver? > > > Hopefully this answers your questions. Thanks, Arnd, did you have further questions about this driver?