Received: by 2002:a05:7208:9594:b0:7e:5202:c8b4 with SMTP id gs20csp1257636rbb; Mon, 26 Feb 2024 04:05:22 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCX1w9wA23Q5Ft7I6YSzgeD419nsz2JkfdSvW1MrmaIFJqihCRhYrkf7T+sAf3uGScPFgkte9WDcvNPWmrLGcbEQxtbPWmlNtig2Dl5kIQ== X-Google-Smtp-Source: AGHT+IFjkcc9xQqFILuo+r3soKpVI/6uc0aZUMsX1zr23eiNA7SzT1VDjwsiD6Eibb5L1P5fyU+H X-Received: by 2002:a05:6358:1092:b0:17b:7abd:89ce with SMTP id j18-20020a056358109200b0017b7abd89cemr9757601rwi.26.1708949122026; Mon, 26 Feb 2024 04:05:22 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1708949121; cv=pass; d=google.com; s=arc-20160816; b=MJxYy5mUZn8slAq3JiRATtGyQXAzP4PkCgr5r4nLAKw93D0qo9Lnu2vEZ2J3ql8N0w SZjMHzpOBoiQTWqO9Sn4dt8t0FiGdhJPtiZUdK4WdqKd7rz0XXVIcx7RUO1+cnxdcegn 8BIFWoU2cKwJEmyVjxFLQn/EQL7IKalF8z4WSHTwKKsHONm9Gtwa1qZ2D2cfWJZs+cFj VWe68yMeKMKL2mkN1Qnwjddy53bZdAPrEHYIVdejza/+a0mcU6fR3GkJT1dZlc2QiUsQ taXk/yQJQgwWyljA1/ukX8NoW7+xEgdo1IiYZYyuhExKHmqDZJAu4uneWRFUkcTq4lnU qNgw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=cc:to:content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:message-id:date:subject:from :dkim-signature; bh=yOtDU75r2JA5nMqmgqSfs6LZtJBpRoh0ipLmkGMw850=; fh=DSi59ncLz30K8BphhVE51tnwCGJZo0Q+ZHCEYADhPZc=; b=jWUVgkSM/1ktueKJ4umZMjlgdWNNm2+MVHuqoapiG0qRsZEw5xYbQO42w2l0Gsi1vO KYS8ue/7yLUXz3Xtrz1EKz1kycDjGOfVmlFQ2k9FYQL++dsq6qUrRw5VKNxgAisGMlbo Q/z0eSHMScr5H0jnRLg9YbZ3xWfywCiLfTVlorQ7KTm/wI+da6QXdPoznbMrwguJoCun /J6oz84b1wH9AaOsJPLmKq4nE6twXuvxqFb6sHJZxtQUrU7IbVDlIYyX3I6G96yoFj4j +ZgPEnnxHQEfIL8+IgQVnH9EEeVoVNfn8tIvzfnVIliAKyaMTh5wE383Fn1Ta+iuEXCK 8dpw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=liVJl3i9; arc=pass (i=1 spf=pass spfdomain=linaro.org dkim=pass dkdomain=linaro.org dmarc=pass fromdomain=linaro.org); spf=pass (google.com: domain of linux-kernel+bounces-81287-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-81287-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id 7-20020a630a07000000b005dc82a6711fsi3546197pgk.102.2024.02.26.04.05.21 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 26 Feb 2024 04:05:21 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-81287-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=@linaro.org header.s=google header.b=liVJl3i9; arc=pass (i=1 spf=pass spfdomain=linaro.org dkim=pass dkdomain=linaro.org dmarc=pass fromdomain=linaro.org); spf=pass (google.com: domain of linux-kernel+bounces-81287-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-81287-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.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 577E3B2D831 for ; Mon, 26 Feb 2024 11:39:13 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 6D6231D54F; Mon, 26 Feb 2024 11:37:52 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="liVJl3i9" Received: from mail-qk1-f170.google.com (mail-qk1-f170.google.com [209.85.222.170]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 8559D1EB55 for ; Mon, 26 Feb 2024 11:37:49 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.222.170 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708947471; cv=none; b=RiUCZ1yoLdO4JfkEXp2pLufSnSXF61ZFNrTHlyIoXOGq6webK//5dy/y5rA+NB3ufWJf3RcDzq3fuftJ66cqb2a5/+OJCI6UwJLKJLOtYP99nO/cGjSdV5Oo0/ogaSw7Ffic8y9dKZ8WuPnAIfgwHXDnM2rx2YWXbr/qIpukkD0= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708947471; c=relaxed/simple; bh=zN4H7AL9yEWwBMPFUse2kPeWuj9c3TyK31dCtLQBVwU=; h=From:Subject:Date:Message-Id:MIME-Version:Content-Type:To:Cc; b=VyY/WhcrwCU1Z6wcKeswB1KTKxl9c+nmWfVbuHpQkeSPAV/3lWAQTJoKmMhVO1Nb029wN8H6QPjx+9IBymZrySOEZsUQx2Bcbh30FjyDv1LjCkhxt2aqKK8zYwT6ERy5G0/o7jHNPOU2GGqo+BtWdMvl7qdiTu5VJN1TJcH9F5g= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org; spf=pass smtp.mailfrom=linaro.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b=liVJl3i9; arc=none smtp.client-ip=209.85.222.170 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linaro.org Received: by mail-qk1-f170.google.com with SMTP id af79cd13be357-787bc70dfc7so157057185a.2 for ; Mon, 26 Feb 2024 03:37:49 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1708947468; x=1709552268; darn=vger.kernel.org; h=cc:to:content-transfer-encoding:mime-version:message-id:date :subject:from:from:to:cc:subject:date:message-id:reply-to; bh=yOtDU75r2JA5nMqmgqSfs6LZtJBpRoh0ipLmkGMw850=; b=liVJl3i9xCmrH9zhq8o1WhqU3jVj4q6wdYxEpJeW9obDIk2gNHciJWvVAcahATIzkh lSSPipVAh/+joi7aK0go8IeuKgqaiy2rrxkLhUPiBXlWz02DBdG973xL+aDTtUQMlTM5 7m2pbIbvmPK2+YNYm8z/3eme2/0V1L2RhQ0yWSq38JAkQWJLsFRl3jn8x0qSfLPnhnnm xV5qQnCEE+LbSm9zwwqZo8lG1Jb2Bte+Mt4Q0CX7rj9Lbk6caPZnDQbt+VTbkP+1N+8z DwstsUQkMOhLrl5LYE7VN+83ZonmAwF1/weltCnW4GlfyUSBR1NlulaTNMhVCC3Uf9SB tYWA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1708947468; x=1709552268; h=cc:to:content-transfer-encoding:mime-version:message-id:date :subject:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=yOtDU75r2JA5nMqmgqSfs6LZtJBpRoh0ipLmkGMw850=; b=KZ30aIKAFP7tbTkP5YEDBtyA0ahaKKVLfPWXRYFmVSRiWTe+UhIV5gXiRSCePruRAC S0sI1BpFL35GfQS29Wl1HZKmwuO4EIyWjZPjdcbeex8UlenLShY0AlGhABK1HpdNMttO 0kN6xIqN75T16Ke8gNYw7xHpudzKCWhOOfMw2Sg7QIkeS/XAWt/nnzYYUneE8mN9suYW 9er6fSYuW6Fq6rfnRUAK6PtBiUFux1BoTm/v9CJjqsL51tOygYtQemwv19OyYJ9tDpRq DPjNKvSbq8zZpgwtZrj25TdrIvUfdPVdWtCLzXXW3Xunw3Ir+Oe94s8WMZKHnRDmvA/V UY1g== X-Forwarded-Encrypted: i=1; AJvYcCXv/h1pH99Con4d21Vc1oG4eOp+BYbCBOyMDMhU0MTwUGoGjxc1v5V24r90ZFVPqzcfdKsYJCSTXB4cOQqaCVAn3kmY1dTWmZAJcI/m X-Gm-Message-State: AOJu0YwoCK8cOQtPsjEsAdGsl9gmbReHsUNULls448BqKQrncRbWphO/ /o+DclOF+vwfftMiRARK5Qftkk0p+BAeaoebQ5ZULBdM2jSFsDVMdgrMf8HeYw== X-Received: by 2002:a05:620a:7f9:b0:787:1a78:fbe9 with SMTP id k25-20020a05620a07f900b007871a78fbe9mr6385524qkk.56.1708947468464; Mon, 26 Feb 2024 03:37:48 -0800 (PST) Received: from [127.0.1.1] ([117.202.184.81]) by smtp.gmail.com with ESMTPSA id q15-20020a05620a0c8f00b007878babb96asm2341842qki.94.2024.02.26.03.37.42 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 26 Feb 2024 03:37:47 -0800 (PST) From: Manivannan Sadhasivam Subject: [PATCH v3 0/5] PCI: dwc: Add support for integrating HDMA with DWC EP driver Date: Mon, 26 Feb 2024 17:07:25 +0530 Message-Id: <20240226-dw-hdma-v3-0-cfcb8171fc24@linaro.org> 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="utf-8" Content-Transfer-Encoding: 7bit X-B4-Tracking: v=1; b=H4sIAPV33GUC/2XMQQ7CIBCF4as0sxYzDqRJXXkP0wUUKJMoGDCoa bi72K3L/+Xl26C4zK7Aedggu8qFU+whDwMsQcfVCba9gZAU0mkU9iWCvWsxKmsXnLyRaKC/H9l 5fu/Sde4duDxT/uxwpd/6b1QSKIwiSROi9Epebhx1TseUV5hba1/oduAdnwAAAA== To: Jingoo Han , Gustavo Pimentel , Lorenzo Pieralisi , =?utf-8?q?Krzysztof_Wilczy=C5=84ski?= , Rob Herring , Bjorn Helgaas , Marek Vasut , Yoshihiro Shimoda , Kishon Vijay Abraham I Cc: Serge Semin , linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org, linux-renesas-soc@vger.kernel.org, linux-arm-msm@vger.kernel.org, mhi@lists.linux.dev, Manivannan Sadhasivam , Siddharth Vadapalli , Mrinmay Sarkar X-Mailer: b4 0.12.4 X-Developer-Signature: v=1; a=openpgp-sha256; l=2608; i=manivannan.sadhasivam@linaro.org; h=from:subject:message-id; bh=zN4H7AL9yEWwBMPFUse2kPeWuj9c3TyK31dCtLQBVwU=; b=owEBbQGS/pANAwAKAVWfEeb+kc71AcsmYgBl3Hf+ugscH906dxKa1q956AiK7dO/M8tdcr6fT aiph35AMmeJATMEAAEKAB0WIQRnpUMqgUjL2KRYJ5dVnxHm/pHO9QUCZdx3/gAKCRBVnxHm/pHO 9VIPB/90Qib9s9ybHOJjZTFAzC+LuAX4iTj/eAvrr+mXEaxKJgMyz/Zaxr3LoPGnq9TeHvyOSh+ rk8EqkZ8yGo+jFjQru/9eO3BCZEAaZQgbP4dgHuLgkKBkUOl91uC1af3moCy9egzAqAnXVcZJ2k lgcJf7eOuH+Db/euhh8+4bvApFvNG2KBCWI+e3lP8A4MARip6kPe7hc924+LzcG1RAg2CLJXK6w qGIQeCoU/d5wx0OiCOz8HGQpUWTXeTSDOes8m4P9WVTwWHQih8n5oYyZ8DV4yoURYsgxiaE43QX O+qByCZy8Q9LEQTmuuv+cv8fJuWCq5nxdUXlYbYny/O34vIw X-Developer-Key: i=manivannan.sadhasivam@linaro.org; a=openpgp; fpr=C668AEC3C3188E4C611465E7488550E901166008 Hello, This series adds support for integrating HDMA with the DWC EP driver. Hyper DMA (HDMA) is already supported by the dw-edma dmaengine driver. Unlike it's predecessor Embedded DMA (eDMA), HDMA supports only unroll mapping format and doesn't support auto detecting the read/write channels. Hence, this series modifies the existing eDMA code to work with HDMA by honoring the platform supplied mapping format and read/write channels count. The platform drivers making use of HDMA should pass the EDMA_MF_HDMA_NATIVE flag and provide channels count. In this series, HDMA support is added for the Qcom SA8775P SoC and the DMA support in enabled in MHI EPF driver as well. Testing ------- Tested on Qualcomm SA8775P Ride board. Dependency ---------- Depends on: https://lore.kernel.org/dmaengine/20240129-b4-feature_hdma_mainline-v7-0-8e8c1acb7a46@bootlin.com/ https://lore.kernel.org/all/1701432377-16899-1-git-send-email-quic_msarkar@quicinc.com/ NOTE: I've taken over this series from Mrinmay who posted v1: https://lore.kernel.org/linux-pci/1705669223-5655-1-git-send-email-quic_msarkar@quicinc.com/ - Mani Changes in v3: - Collected review tags - Minor code refactoring (Siddharth) - Link to v2: https://lore.kernel.org/r/20240216-dw-hdma-v2-0-b42329003f43@linaro.org Changes in v2: - Dropped dmaengine patches (Sergey) - Reworked dw_pcie_edma_find_chip() to support both eDMA and HDMA (Sergey) - Skipped MF and channel detection if glue drivers have provided them (Sergey) - Addressed review comments in pcie-qcom-ep and pci-epf-mhi drivers (Mani) Signed-off-by: Manivannan Sadhasivam --- Manivannan Sadhasivam (3): PCI: dwc: Refactor dw_pcie_edma_find_chip() API PCI: dwc: Skip finding eDMA channels count if glue drivers have passed them PCI: dwc: Pass the eDMA mapping format flag directly from glue drivers Mrinmay Sarkar (2): PCI: qcom-ep: Add HDMA support for SA8775P SoC PCI: epf-mhi: Enable HDMA for SA8775P SoC drivers/pci/controller/dwc/pcie-designware.c | 74 +++++++++++++++++++--------- drivers/pci/controller/dwc/pcie-designware.h | 5 +- drivers/pci/controller/dwc/pcie-qcom-ep.c | 23 ++++++++- drivers/pci/controller/dwc/pcie-rcar-gen4.c | 2 +- drivers/pci/endpoint/functions/pci-epf-mhi.c | 1 + 5 files changed, 78 insertions(+), 27 deletions(-) --- base-commit: fdd10aee7740a53c370a867b8743a8c8945d1db1 change-id: 20240216-dw-hdma-64ddc09fb30b Best regards, -- Manivannan Sadhasivam