lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAPDyKFp5KET0HR+8MwO4cf0O6W2kyFqHoKcVf5jbgBuLuQUcFA@mail.gmail.com>
Date: Tue, 2 Apr 2024 12:15:45 +0200
From: Ulf Hansson <ulf.hansson@...aro.org>
To: Tejun Heo <tj@...nel.org>
Cc: Allen Pais <apais@...ux.microsoft.com>, linux-kernel@...r.kernel.org, 
	keescook@...omium.org, vkoul@...nel.org, marcan@...can.st, sven@...npeter.dev, 
	florian.fainelli@...adcom.com, rjui@...adcom.com, sbranden@...adcom.com, 
	paul@...pouillou.net, Eugeniy.Paltsev@...opsys.com, 
	manivannan.sadhasivam@...aro.org, vireshk@...nel.org, Frank.Li@....com, 
	leoyang.li@....com, zw@...kernel.org, wangzhou1@...ilicon.com, 
	haijie1@...wei.com, shawnguo@...nel.org, s.hauer@...gutronix.de, 
	sean.wang@...iatek.com, matthias.bgg@...il.com, 
	angelogioacchino.delregno@...labora.com, afaerber@...e.de, 
	logang@...tatee.com, daniel@...que.org, haojian.zhuang@...il.com, 
	robert.jarzmik@...e.fr, andersson@...nel.org, konrad.dybcio@...aro.org, 
	orsonzhai@...il.com, baolin.wang@...ux.alibaba.com, zhang.lyra@...il.com, 
	patrice.chotard@...s.st.com, linus.walleij@...aro.org, wens@...e.org, 
	jernej.skrabec@...il.com, peter.ujfalusi@...il.com, kys@...rosoft.com, 
	haiyangz@...rosoft.com, wei.liu@...nel.org, decui@...rosoft.com, 
	jassisinghbrar@...il.com, mchehab@...nel.org, maintainers@...echerrydvr.com, 
	aubin.constans@...rochip.com, manuel.lauss@...il.com, mirq-linux@...e.qmqm.pl, 
	jh80.chung@...sung.com, oakad@...oo.com, hayashi.kunihiko@...ionext.com, 
	mhiramat@...nel.org, brucechang@....com.tw, HaraldWelte@...tech.com, 
	pierre@...man.eu, duncan.sands@...e.fr, stern@...land.harvard.edu, 
	oneukum@...e.com, openipmi-developer@...ts.sourceforge.net, 
	dmaengine@...r.kernel.org, asahi@...ts.linux.dev, 
	linux-arm-kernel@...ts.infradead.org, linux-rpi-kernel@...ts.infradead.org, 
	linux-mips@...r.kernel.org, imx@...ts.linux.dev, 
	linuxppc-dev@...ts.ozlabs.org, linux-mediatek@...ts.infradead.org, 
	linux-actions@...ts.infradead.org, linux-arm-msm@...r.kernel.org, 
	linux-riscv@...ts.infradead.org, linux-sunxi@...ts.linux.dev, 
	linux-tegra@...r.kernel.org, linux-hyperv@...r.kernel.org, 
	linux-rdma@...r.kernel.org, linux-media@...r.kernel.org, 
	linux-mmc@...r.kernel.org, linux-omap@...r.kernel.org, 
	linux-renesas-soc@...r.kernel.org, linux-s390@...r.kernel.org, 
	netdev@...r.kernel.org, linux-usb@...r.kernel.org
Subject: Re: [PATCH 9/9] mmc: Convert from tasklet to BH workqueue

On Thu, 28 Mar 2024 at 17:21, Tejun Heo <tj@...nel.org> wrote:
>
> Hello,
>
> On Thu, Mar 28, 2024 at 01:53:25PM +0100, Ulf Hansson wrote:
> > At this point we have suggested to drivers to switch to use threaded
> > irq handlers (and regular work queues if needed too). That said,
> > what's the benefit of using the BH work queue?
>
> BH workqueues should behave about the same as tasklets which have more
> limited interface and is subtly broken in an expensive-to-fix way (around
> freeing in-flight work item), so the plan is to replace tasklets with BH
> workqueues and remove tasklets from the kernel.

Seems like a good approach!

>
> The [dis]advantages of BH workqueues over threaded IRQs or regular threaded
> workqueues are the same as when you compare them to tasklets. No thread
> switching overhead, so latencies will be a bit tighter. Wheteher that
> actually matters really depends on the use case. Here, the biggest advantage
> is that it's mostly interchangeable with tasklets and can thus be swapped
> easily.

Right, thanks for clarifying!

However, the main question is then - if/when it makes sense to use the
BH workqueue for an mmc host driver. Unless there are some HW
limitations, a threaded irq handler should be sufficient, I think.

That said, moving to threaded irq handlers is a different topic and
doesn't prevent us from moving to BH workqueues as it seems like a
step in the right direction.

Kind regards
Uffe

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ