linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: "Arnd Bergmann" <arnd@arndb.de>
To: "Vinod Koul" <vkoul@kernel.org>,
	"Allen Pais" <apais@linux.microsoft.com>
Cc: imx@lists.linux.dev, "Ulf Hansson" <ulf.hansson@linaro.org>,
	"Oliver Neukum" <oneukum@suse.com>,
	duncan.sands@free.fr,
	"Kunihiko Hayashi" <hayashi.kunihiko@socionext.com>,
	"linux-mmc @ vger . kernel . org" <linux-mmc@vger.kernel.org>,
	aubin.constans@microchip.com,
	"Linus Walleij" <linus.walleij@linaro.org>,
	"Frank Li" <Frank.Li@nxp.com>,
	linux-hyperv@vger.kernel.org, linux-mips@vger.kernel.org,
	"Paul Cercueil" <paul@crapouillou.net>,
	linux-tegra@vger.kernel.org, Netdev <netdev@vger.kernel.org>,
	maintainers@bluecherrydvr.com, peter.ujfalusi@gmail.com,
	"Manivannan Sadhasivam" <manivannan.sadhasivam@linaro.org>,
	linux-riscv@lists.infradead.org,
	"K. Y. Srinivasan" <kys@microsoft.com>,
	"Robert Jarzmik" <robert.jarzmik@free.fr>,
	haijie1@huawei.com,
	Linux-Renesas <linux-renesas-soc@vger.kernel.org>,
	"Wei Liu" <wei.liu@kernel.org>,
	Linux-OMAP <linux-omap@vger.kernel.org>,
	"Florian Fainelli" <florian.fainelli@broadcom.com>,
	linux-rdma@vger.kernel.org, "Viresh Kumar" <vireshk@kernel.org>
Subject: Re: [PATCH 2/9] dma: Convert from tasklet to BH workqueue
Date: Thu, 28 Mar 2024 11:08:47 +0100	[thread overview]
Message-ID: <2e9257af-c123-406b-a189-eaebeecc1d71@app.fastmail.com> (raw)
In-Reply-To: <ZgUGXTKPVhrA1tam@matsya>

On Thu, Mar 28, 2024, at 06:55, Vinod Koul wrote:
> On 27-03-24, 16:03, Allen Pais wrote:
>> The only generic interface to execute asynchronously in the BH context is
>> tasklet; however, it's marked deprecated and has some design flaws. To
>> replace tasklets, BH workqueue support was recently added. A BH workqueue
>> behaves similarly to regular workqueues except that the queued work items
>> are executed in the BH context.
>
> Thanks for conversion, am happy with BH alternative as it helps in
> dmaengine where we need shortest possible time between tasklet and
> interrupt handling to maximize dma performance

I still feel that we want something different for dmaengine,
at least in the long run. As we have discussed in the past,
the tasklet context in these drivers is what the callbacks
from the dma client device is run in, and a lot of these probably
want something other than tasklet context, e.g. just call
complete() on a client-provided completion structure.

Instead of open-coding the use of the system_bh_wq in each
dmaengine, how about we start with a custom WQ_BH
specifically for the dmaengine subsystem and wrap them
inside of another interface.

Since almost every driver associates the tasklet with the
dma_chan, we could go one step further and add the
work_queue structure directly into struct dma_chan,
with the wrapper operating on the dma_chan rather than
the work_queue.

      Arnd

  reply	other threads:[~2024-03-28 13:57 UTC|newest]

Thread overview: 42+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-03-27 16:03 [PATCH 0/9] Convert Tasklets to BH Workqueues Allen Pais
2024-03-27 16:03 ` [PATCH 1/9] hyperv: Convert from tasklet to BH workqueue Allen Pais
2024-04-03 16:43   ` Allen
2024-03-27 16:03 ` [PATCH 2/9] dma: " Allen Pais
2024-03-28  5:55   ` Vinod Koul
2024-03-28 10:08     ` Arnd Bergmann [this message]
2024-03-28 18:31       ` Vinod Koul
2024-03-28 19:39         ` Allen
2024-03-28 19:49           ` Arnd Bergmann
2024-03-28 20:01             ` Allen
2024-03-29 16:38               ` Vinod Koul
2024-03-29 16:39           ` Vinod Koul
2024-03-28 17:49     ` Allen
2024-04-02 12:25   ` Linus Walleij
2024-04-02 13:11     ` Vinod Koul
2024-03-27 16:03 ` [PATCH 3/9] IB: " Allen Pais
2024-03-27 16:03 ` [PATCH 4/9] USB: " Allen Pais
2024-03-27 16:20   ` Duncan Sands
2024-03-27 16:55   ` Greg KH
2024-03-27 16:58     ` Allen
2024-03-27 17:55   ` Alan Stern
2024-03-28 17:54     ` Allen
2024-03-27 16:03 ` [PATCH 5/9] mailbox: " Allen Pais
2024-03-27 16:03 ` [PATCH 6/9] ipmi: " Allen Pais
2024-03-27 17:58   ` Corey Minyard
2024-03-28 17:52     ` Allen
2024-03-28 19:23       ` Corey Minyard
2024-03-28 19:41         ` Allen
2024-03-28 19:52           ` Corey Minyard
2024-03-28 19:58             ` Allen
2024-03-27 16:03 ` [PATCH 7/9] s390: " Allen Pais
2024-04-02 12:48   ` Alexandra Winter
2024-04-03 13:33     ` Allen
2024-03-27 16:03 ` [PATCH 8/9] drivers/media/*: " Allen Pais
2024-03-27 16:03 ` [PATCH 9/9] mmc: " Allen Pais
2024-03-27 19:35   ` Jernej Škrabec
2024-03-28 10:16   ` Christian Loehle
2024-03-28 17:47     ` Allen
2024-03-28 12:53   ` Ulf Hansson
2024-03-28 13:37     ` Linus Walleij
2024-03-28 16:21     ` Tejun Heo
2024-04-02 10:15       ` Ulf Hansson

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=2e9257af-c123-406b-a189-eaebeecc1d71@app.fastmail.com \
    --to=arnd@arndb.de \
    --cc=Frank.Li@nxp.com \
    --cc=apais@linux.microsoft.com \
    --cc=aubin.constans@microchip.com \
    --cc=duncan.sands@free.fr \
    --cc=florian.fainelli@broadcom.com \
    --cc=haijie1@huawei.com \
    --cc=hayashi.kunihiko@socionext.com \
    --cc=imx@lists.linux.dev \
    --cc=kys@microsoft.com \
    --cc=linus.walleij@linaro.org \
    --cc=linux-hyperv@vger.kernel.org \
    --cc=linux-mips@vger.kernel.org \
    --cc=linux-mmc@vger.kernel.org \
    --cc=linux-omap@vger.kernel.org \
    --cc=linux-rdma@vger.kernel.org \
    --cc=linux-renesas-soc@vger.kernel.org \
    --cc=linux-riscv@lists.infradead.org \
    --cc=linux-tegra@vger.kernel.org \
    --cc=maintainers@bluecherrydvr.com \
    --cc=manivannan.sadhasivam@linaro.org \
    --cc=netdev@vger.kernel.org \
    --cc=oneukum@suse.com \
    --cc=paul@crapouillou.net \
    --cc=peter.ujfalusi@gmail.com \
    --cc=robert.jarzmik@free.fr \
    --cc=ulf.hansson@linaro.org \
    --cc=vireshk@kernel.org \
    --cc=vkoul@kernel.org \
    --cc=wei.liu@kernel.org \
    /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).