Received: by 2002:a25:1506:0:0:0:0:0 with SMTP id 6csp4100603ybv; Tue, 25 Feb 2020 13:12:48 -0800 (PST) X-Google-Smtp-Source: APXvYqxsyFNPCOGiKFmJu5/h63EI0SSeONKD4QcoHXudh27E3L0ZQpB5KtNv+1Csfgou3gJklhBL X-Received: by 2002:a9d:4f04:: with SMTP id d4mr460360otl.78.1582665168651; Tue, 25 Feb 2020 13:12:48 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1582665168; cv=none; d=google.com; s=arc-20160816; b=qlHeSYiIQA3pBvOHKD4ZRssDk5HOJ8fWd1ZmyYbLfHqDp2hRX7BPpQsXZQ63egsk2i U/RhQ3l4kgsVTe5yhkfIACDp1rbCKKfvNDwFlOtuBBkf+Mvo0m74hyyf/FCn72ix/ukv aTO558CJw6JFZmSM9P9iBtXXx8p9AtlJuPTpBXyvmHYWBN/0Hkax0xGm+wXpVCxhumqk vcMUKPgHLZBUfnSkZrfw6OA9/wyaFHpeP403lkFMPL+nyEOd4UrCVKK8nPqrg0ofj3Hh QsAT/eRSULCaMPeV/Mpj8/uINUJdWKP41I7KKTFmKppNQ2LQYVCABTdfKnXzvu8K0NNC G3pQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature; bh=tF+IlVAI+HS6Y0f+cneOLEXoT8cWlqM5wUtgnJmBx14=; b=khheCprK9lVAXMcVq0B7kp+2kiJVjw66LLKgUijDwG2FgXQpx6Y2jdcten5h2F+218 5TZ83MQx+pbfL70nAnbsz/3QjWrsX+7wwMd0PFqX9yWvEKB7oYbOjv9UYSjhW/LkEgkM nCTPLzHLisZh2opiD9NTXF1BDd6VOYpbcgnvYSOk4c1dpZ4DUP2wsYscFRm6U8S6ptIm rQ8n+OzDPhOPRiPrLErxCY2vk/6uztUL5gefcgfU1SePP/QLyQMkCJRGVdS15C7LUApn yT3lz/VfdJBTa2y5BKGnob1hW+zVQpWe6FMRfpSFLO+O6Q5NtLAGpfKHBw0oYSGvu0RN 4ZXA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@sifive.com header.s=google header.b=ftkdQ2hg; 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 r10si23801otk.83.2020.02.25.13.12.36; Tue, 25 Feb 2020 13:12:48 -0800 (PST) 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=@sifive.com header.s=google header.b=ftkdQ2hg; 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 S1727075AbgBYVLW (ORCPT + 99 others); Tue, 25 Feb 2020 16:11:22 -0500 Received: from mail-pg1-f195.google.com ([209.85.215.195]:34496 "EHLO mail-pg1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726130AbgBYVLW (ORCPT ); Tue, 25 Feb 2020 16:11:22 -0500 Received: by mail-pg1-f195.google.com with SMTP id j4so172374pgi.1 for ; Tue, 25 Feb 2020 13:11:21 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sifive.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=tF+IlVAI+HS6Y0f+cneOLEXoT8cWlqM5wUtgnJmBx14=; b=ftkdQ2hgfFVI+hwU2MK6zYKrQrPOSgrXXuFofv2ARHivbmdOfs3ssBMzmdjnP5ZzPD Dr8MiMS654nUEZnmSv/nnA2aODa8F5AWISMWIlq2W5JbZQho0BgYPNraYWZPAoryyXSH G+T5SQyrCZgGe4xBrhoQedScDHGxcrOiKer9O53ygw/vEXo5vFkJl3NoPmX+MdWgsP1L Qan28rYEmUbwHA0ZPySQNAZQwsCrfKb4qnKz3CxjPFQlrY9yQBNHzugggZ0UiAAmEP++ ITepZHHQcsLZT8uewbRgRRN9T9ryRH/AJL5KBei+/II26JUJl+y9nBjMNa/GET7EKb29 WFlg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=tF+IlVAI+HS6Y0f+cneOLEXoT8cWlqM5wUtgnJmBx14=; b=djqlA2qd4QvDijP9zGhY+5PytzpSyw9/gx73suTUZVV7y+sxMz7E0XyuGlCptflwFj o9bdv5Vq9jhPcmBQ1L85iYq3OdE9+5xjXyO9DXouo5tVMb7AaHoJSQyBf+0XHjiX+YrV REgl9mNbVd0EIZ+mEN7BwvaS0FogNAgB4tiqtiv/4G9TzHNUw3e4jg2aBzHWgmXzNKvT Kc33T1D9X4x2SflpBIpKKLkgIwxV5aa+eD883/hh7Z6Fhj/hANhRF47mCIrqy2mclJW6 dg6beoSAEMFWB9IU3N3itUQBqvxvMLZ24us3MyTO4WbNAl5190uFCNavFQa1Lv9rwmrF gTIA== X-Gm-Message-State: APjAAAUc+LDdSKvK/8LaJZK/SQ51Yr6X4V7N5UA10QwkXwwl8enqbvCU WkP490Ltp2S9CKooWTH4E/hKjQ== X-Received: by 2002:a63:d90c:: with SMTP id r12mr486886pgg.106.1582665081210; Tue, 25 Feb 2020 13:11:21 -0800 (PST) Received: from nuc7.sifive.com ([12.206.222.5]) by smtp.gmail.com with ESMTPSA id h3sm17862064pfo.102.2020.02.25.13.11.20 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 25 Feb 2020 13:11:20 -0800 (PST) From: Alan Mikhak X-Google-Original-From: Alan Mikhak < alan.mikhak@sifive.com > To: kishon@ti.com Cc: alan.mikhak@sifive.com, amurray@thegoodpenguin.co.uk, arnd@arndb.de, bhelgaas@google.com, gregkh@linuxfoundation.org, linux-kernel@vger.kernel.org, linux-pci@vger.kernel.org, lorenzo.pieralisi@arm.com Subject: [PATCH 1/5] PCI: endpoint: functions/pci-epf-test: Add DMA support to transfer data Date: Tue, 25 Feb 2020 13:11:07 -0800 Message-Id: <1582665067-20462-1-git-send-email-alan.mikhak@sifive.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <20200225091130.29467-1-kishon@ti.com> References: <20200225091130.29467-1-kishon@ti.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org @@ -380,6 +572,7 @@ static void pci_epf_test_unbind(struct pci_epf *epf) int bar; cancel_delayed_work(&epf_test->cmd_handler); + pci_epf_clean_dma_chan(epf_test); pci_epc_stop(epc); for (bar = 0; bar < PCI_STD_NUM_BARS; bar++) { epf_bar = &epf->bar[bar]; @@ -550,6 +743,12 @@ static int pci_epf_test_bind(struct pci_epf *epf) } } + epf_test->dma_supported = true; + + ret = pci_epf_init_dma_chan(epf_test); + if (ret) + epf_test->dma_supported = false; + if (linkup_notifier) { epf->nb.notifier_call = pci_epf_test_notifier; pci_epc_register_notifier(epc, &epf->nb); Hi Kishon, Looking forward to building and trying this patch series on a platform I work on. Would you please point me to where I can find the patches which add pci_epf_init_dma_chan() and pci_epf_clean_dma_chan() to Linux PCI Endpoint Framework? Regards, Alan Mikhak