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] [day] [month] [year] [list]
Date: Wed, 12 Jun 2024 05:12:43 -0700
From: Breno Leitao <leitao@...ian.org>
To: Andy Shevchenko <andriy.shevchenko@...el.com>, ldewangan@...dia.com
Cc: Laxman Dewangan <ldewangan@...dia.com>,
	Dmitry Osipenko <digetx@...il.com>,
	Andi Shyti <andi.shyti@...nel.org>,
	Thierry Reding <thierry.reding@...il.com>,
	Jonathan Hunter <jonathanh@...dia.com>, paulmck@...nel.org,
	apopple@...dia.com, Michael van der Westhuizen <rmikey@...a.com>,
	"open list:I2C SUBSYSTEM HOST DRIVERS" <linux-i2c@...r.kernel.org>,
	"open list:TEGRA ARCHITECTURE SUPPORT" <linux-tegra@...r.kernel.org>,
	open list <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] [i2c-tegra] Do not mark ACPI devices as irq safe

Hello Andy,

On Tue, Jun 11, 2024 at 03:49:02PM +0300, Andy Shevchenko wrote:
> On Thu, Jun 06, 2024 at 06:27:07AM -0700, Breno Leitao wrote:

> > The problem arises because during __pm_runtime_resume(), the spinlock
> > &dev->power.lock is acquired before rpm_resume() is called. Later,
> > rpm_resume() invokes acpi_subsys_runtime_resume(), which relies on
> > mutexes, triggering the error.
> > 
> > To address this issue, devices on ACPI are now marked as not IRQ-safe,
> > considering the dependency of acpi_subsys_runtime_resume() on mutexes.
> 
> ...
> 
> While it's a move in the right direction, the real fix is to get rid of
> the IRQ safe PM hack completely.
> Look at how OMAP code was modified for
> the last few years and now it's pm_runtime_irq_safe()-free. The main
> (ab)users are SH code followed by Tegra drivers.

Thanks. 

I think these are two different goals here. This near term goal is just
fix the driver so it can use the pm_runtime_irq_safe() in a saner
way, avoiding calling mutexes inside spinlocks.

Getting rid of the IRQ safe PM seems to me to be more a long term
desirable goal, and unfortunately I cannot afford doing it now.

Laxman, what is your view on this topic?

--breno

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ