Received: by 2002:a05:6500:1b45:b0:1f5:f2ab:c469 with SMTP id cz5csp780259lqb; Wed, 17 Apr 2024 10:24:28 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCVX6SyxVR/P+YUbQBbIJZ3aAMUxAPCuDba5+2tuE/hbYidOEO/uGOE0Nufy23u80ndRNJyhTaH5KaMeaeNZDgQLJ7epRWJlf9E7PFd/8Q== X-Google-Smtp-Source: AGHT+IH/1zIu4nj4FG65ezbd8mzypuKdt8NBsa9/ECSdCsi17B8Sum3e150vf0c49Qtl7tExBCFq X-Received: by 2002:a05:6a20:968a:b0:1a7:7ccf:2157 with SMTP id hp10-20020a056a20968a00b001a77ccf2157mr300519pzc.42.1713374668285; Wed, 17 Apr 2024 10:24:28 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1713374668; cv=pass; d=google.com; s=arc-20160816; b=sc0xbRaSrWGXY3Jy+6GzPH3ntmnQlacPF2G1/nQHgjt5q8ZqtmD+1QkHyJak0HTD4T FRSINvQgNmZInQef+/RLynYw1iFra3EdrvrZwkonA0rH2Cy7l/vTAxqSlOZigpI+Fkga P/uz6tQ0QGVXd9YEMW/o5+XlWFmqTK99abfOeVCKw2TPVyCBugBAePcbStRqYqZVNvxD y9orc3WVa8yYI2oYcZL/ye1IxUIlA16Ajbx4RCZ4zi6coFpByATF6jAiZoVOUB3eoi5j 8SMeYoV2pygnqctTsMiINYesvhf2LljoU/CmzgQTuqvxn2RlDPgL/hClZpFhsZ5gW/PF SgtA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :references:message-id:subject:cc:to:from:date:dkim-signature; bh=d6I37tapuI9sr5/+8izBpAxna9svPirIiW1ubnzN/oc=; fh=/n9EW83w/xrPdQRBDGjxYA17U0RVs8lfZAGuebAS9YQ=; b=l+lYf/r5nMNH8cYiEWuBttsvn30e/mosV5wlacHyT19Enw9Q7VnCLkcrSH8gauMXx/ QOFjF0nMLva3Oo6+tgbq+3+E1ycZJohi1S3jSKyYiz9VLo7vGjbfZsRT52KDvIluWFTy aau/OEYBkrDEzTjvVx/14Lnc+JbFhRI0hi/IVp7XW++XE+2t3poR6VmX7dmOp2xd6ONw cb3USdf5Qi6IXgSOUmAgP7er52F47NJZvNiG2Faoo4yiBVzB4G8hqa95frXYNpWgSAdD Oc1QATqo+zK9KchJHuhCRHpADOCB4WL1kvB2/NImaRPX8m3m61kQ3AcBrdODXCL/gwYK Mz3A==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=hHChMN57; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-148965-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-148965-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id z3-20020a634c03000000b005cf64c90ecbsi11596576pga.215.2024.04.17.10.24.27 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 17 Apr 2024 10:24:28 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-148965-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) client-ip=147.75.48.161; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=hHChMN57; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-148965-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-148965-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id 24874B26AD3 for ; Wed, 17 Apr 2024 17:05:00 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 2FD40171667; Wed, 17 Apr 2024 17:03:30 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="hHChMN57" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 5207F171079; Wed, 17 Apr 2024 17:03:29 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713373409; cv=none; b=djQswGIQfjyFbPKDSuHyzwS6SP8x0cprZ3n4TjKXqsYncV5IY3KVucRkZxX9Abuga0i5u8MiWk+/9z+loIZAGSKZWKK3l1hBCmMcHTZmg5BSaHR2aslEPn/4L3Kf8hj2wEythdM3WrBf6ccfwSxYGyPnEXDNEIMzfDYnH7HLJEM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713373409; c=relaxed/simple; bh=QjtQ6V3Ehbk5LLxAr33UNMioxKiRpcYG4jFh+UYBzEE=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=HvD51BoGQgl5RI6+hbFXuZXr5kOJRsGUUooYfCmUeuhen6hGwhyqKMVYZzadF6JdhvlX1l4dJ/LKqukTyoLYKlYUEWRuyJSbL4fv12x+6ZEE/o4IO75YJFwz8E7sPAGrLTK58nkB6h23q6/thh3merdT9xrJv32PQ1ceuwnrbjI= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=hHChMN57; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 504D6C072AA; Wed, 17 Apr 2024 17:03:27 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1713373408; bh=QjtQ6V3Ehbk5LLxAr33UNMioxKiRpcYG4jFh+UYBzEE=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=hHChMN57kBOXbFM4QTwzgQyXPTNjbqinV6W7wCepAN0W6oYfeaCyE6dgKeTCTR9Xv G9gEj89fKjNhohGEO//tSrWYiXUTCgtUL61JfvkiXyV2qflbR+0Ju4n86LASM8Gklr +SYKoh/Yf160Uj7zpDeF/vPQnEA2Fv5pwxKYmY8Alo+/cv6LvvuWDJvCTvbqkdCiR+ ctIWquCQr+S1e28UlSRsRzreoUOHkqDwxVp20LMc8VqBlaN6APWAr9UHoWtlRpq7B9 DfKauiiui1p6RXPmALDG6N2WTI0W9lAOJhlx+HXi7wSDkfmilRwd2jZmRjkXkkGUhE vdQEAdyRcF6tw== Date: Wed, 17 Apr 2024 22:33:24 +0530 From: Vinod Koul To: Lizhi Hou Cc: dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org, Nishad Saraf , nishad.saraf@amd.com, sonal.santan@amd.com, max.zhen@amd.com Subject: Re: [PATCH V10 1/1] dmaengine: amd: qdma: Add AMD QDMA driver Message-ID: References: <1709675352-19564-1-git-send-email-lizhi.hou@amd.com> <1709675352-19564-2-git-send-email-lizhi.hou@amd.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: On 08-04-24, 11:06, Lizhi Hou wrote: > > > +static void *qdma_get_metadata_ptr(struct dma_async_tx_descriptor *tx, > > > + size_t *payload_len, size_t *max_len) > > > +{ > > > + struct qdma_mm_vdesc *vdesc; > > > + > > > + vdesc = container_of(tx, typeof(*vdesc), vdesc.tx); > > > + if (payload_len) > > > + *payload_len = sizeof(vdesc->dev_addr); > > > + if (max_len) > > > + *max_len = sizeof(vdesc->dev_addr); > > > + > > > + return &vdesc->dev_addr; > > Can you describe what metadata is being used here for? > > The metadata is the device address the dma request will transfer > > data to / from.? Please see the example usage here: > > https://github.com/houlz0507/XRT-1/blob/qdma_v1_usage/src/runtime_src/core/pcie/driver/linux/xocl/subdev/qdma.c#L311 > > Before dmaengine_submit(), it specifies the device address. Hmmm, why is the vaddr passed like this, why not use slave_config for this -- ~Vinod