linux-pci.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Kishon Vijay Abraham I <kishon@ti.com>
To: Alan Mikhak <alan.mikhak@sifive.com>
Cc: <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: Re: [PATCH 1/5] PCI: endpoint: functions/pci-epf-test: Add DMA support to transfer data
Date: Wed, 26 Feb 2020 10:39:13 +0530	[thread overview]
Message-ID: <7e1202a3-037b-d1f3-f2bf-1b8964787ebd@ti.com> (raw)
In-Reply-To: <1582665067-20462-1-git-send-email-alan.mikhak@sifive.com>

Hi Alan,

On 26/02/20 2:41 am, Alan Mikhak wrote:
> @@ -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?

I've added these functions in pci-epf-test itself instead of adding in
the core files. I realized adding it in core files may not be helpful if
the endpoint function decides to use more number of DMA channels etc.,

Thanks
Kishon

  reply	other threads:[~2020-02-26  5:04 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-02-25  9:11 [PATCH 0/5] PCI: functions/pci-epf-test: Add DMA data transfer Kishon Vijay Abraham I
2020-02-25  9:11 ` [PATCH 1/5] PCI: endpoint: functions/pci-epf-test: Add DMA support to transfer data Kishon Vijay Abraham I
2020-02-25  9:11 ` [PATCH 2/5] PCI: endpoint: functions/pci-epf-test: Print throughput information Kishon Vijay Abraham I
2020-02-25  9:11 ` [PATCH 3/5] misc: pci_endpoint_test: Use streaming DMA APIs for buffer allocation Kishon Vijay Abraham I
2020-02-25  9:11 ` [PATCH 4/5] tools: PCI: Add 'd' command line option to support DMA Kishon Vijay Abraham I
2020-02-25  9:11 ` [PATCH 5/5] misc: pci_endpoint_test: Add support to get DMA option from userspace Kishon Vijay Abraham I
2020-02-25 21:11 ` [PATCH 1/5] PCI: endpoint: functions/pci-epf-test: Add DMA support to transfer data Alan Mikhak
2020-02-26  5:09   ` Kishon Vijay Abraham I [this message]
2020-02-26 17:39     ` Alan Mikhak
2020-03-03 23:57       ` Alan Mikhak
2020-03-04  5:15         ` Kishon Vijay Abraham I

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=7e1202a3-037b-d1f3-f2bf-1b8964787ebd@ti.com \
    --to=kishon@ti.com \
    --cc=alan.mikhak@sifive.com \
    --cc=amurray@thegoodpenguin.co.uk \
    --cc=arnd@arndb.de \
    --cc=bhelgaas@google.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=lorenzo.pieralisi@arm.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).