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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <20130205171333.B4D483E0D17@localhost>
Date:	Tue, 05 Feb 2013 17:13:33 +0000
From:	Grant Likely <grant.likely@...retlab.ca>
To:	Murali Karicheri <m-karicheri2@...com>
Cc:	spi-devel-general@...ts.sourceforge.net,
	davinci-linux-open-source@...ux.davincidsp.com,
	Thomas Gleixner <tglx@...uronix.de>,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH] spi: davinci: use request_threaded_irq() to fix deadlock

On Wed, 2 Jan 2013 10:19:08 -0500, Murali Karicheri <m-karicheri2@...com> wrote:
> On 12/22/2012 05:08 AM, Grant Likely wrote:
> > On Fri, 21 Dec 2012 15:13:26 -0500, Murali Karicheri<m-karicheri2@...com>  wrote:
> >> With RT pre-empt patch applied to Linux kernel, the irq handler will be
> >> force converted to an irq thread. spi driver can get back to back messages
> >> from the slave device. In such cases, IRQ thread doesn't get a chance to
> >> run to read the slave data. Hence the irq handler must be run in hard irq
> >> context to read/write data from slave device. Otherwise, the kernel goes
> >> into a deadlock. This patch fixes this issue when PREEMPT_RT_FULL is
> >> enabled in the kernel. A dummy thread function is provided to satisfy the
> >> request_threaded_irq() API. Passing a NULL for function also causes the
> >> irq handler to be executed in the thread context.
> >>
> >> Signed-off-by: Murali Karicheri<m-karicheri2@...com>
> > Thomas, would you mind taking a look at this for me. My gut feel is that
> > this is the wrong way to solve the problem that Murali is having and
> > that it really just hacks something that works.
> Grant,
> 
> Thanks for reviewing this. As per the RT patch, all of the IRQ handlers 
> will be converted to thread by brute force. This breaks the SPI driver 
> since the data is overwritten with back to back irq as thread is not 
> getting a chance to read the word before next irq happens.  What my 
> patch does is to keep the functionality as before by using a new irq 
> API. So though this is not the best solution, this solves the problem 
> and give an opportunity for improvement by splitting this into two part 
> to handle the irq. But I am not convinced if this is really needed.

Okay. Applied, thanks.

g.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ