RE: [PATCH 1/2] genirq: Fix the possible synchronize_irq() wait-forever

2014-02-21 Thread Thomas Gleixner
On Fri, 21 Feb 2014, Liu, Chuansheng wrote: > > -Original Message- > > From: Thomas Gleixner [mailto:t...@linutronix.de] > > Sent: Friday, February 21, 2014 7:53 PM > > To: Liu, Chuansheng > > Cc: linux-kernel@vger.kernel.org; Wang, Xiaoming > >

RE: [PATCH 1/2] genirq: Fix the possible synchronize_irq() wait-forever

2014-02-21 Thread Liu, Chuansheng
Hello Thomas, > -Original Message- > From: Thomas Gleixner [mailto:t...@linutronix.de] > Sent: Friday, February 21, 2014 7:53 PM > To: Liu, Chuansheng > Cc: linux-kernel@vger.kernel.org; Wang, Xiaoming > Subject: RE: [PATCH 1/2] genirq: Fix the possible synchronize_irq

RE: [PATCH 1/2] genirq: Fix the possible synchronize_irq() wait-forever

2014-02-21 Thread Thomas Gleixner
On Fri, 21 Feb 2014, Liu, Chuansheng wrote: > > > > I think you have a point there, but not on x86 wherre the atomic_dec > > > > and the spinlock on the queueing side are full barriers. For non-x86 > > > > there is definitely a potential issue. > > > > > > > But even on X86, spin_unlock has no

RE: [PATCH 1/2] genirq: Fix the possible synchronize_irq() wait-forever

2014-02-21 Thread Liu, Chuansheng
> -Original Message- > From: Thomas Gleixner [mailto:t...@linutronix.de] > Sent: Friday, February 21, 2014 7:11 PM > To: Liu, Chuansheng > Cc: linux-kernel@vger.kernel.org; Wang, Xiaoming > Subject: RE: [PATCH 1/2] genirq: Fix the possible synchronize_irq() > wai

RE: [PATCH 1/2] genirq: Fix the possible synchronize_irq() wait-forever

2014-02-21 Thread Thomas Gleixner
Xiaoming > > Subject: RE: [PATCH 1/2] genirq: Fix the possible synchronize_irq() > > wait-forever > > > > On Fri, 21 Feb 2014, Liu, Chuansheng wrote: > > > But feels there is another case which the synchronize_irq waited there > > f

RE: [PATCH 1/2] genirq: Fix the possible synchronize_irq() wait-forever

2014-02-21 Thread Liu, Chuansheng
Hello Thomas, > -Original Message- > From: Thomas Gleixner [mailto:t...@linutronix.de] > Sent: Friday, February 21, 2014 6:34 PM > To: Liu, Chuansheng > Cc: linux-kernel@vger.kernel.org; Wang, Xiaoming > Subject: RE: [PATCH 1/2] genirq: Fix the possible synchronize_irq

RE: [PATCH 1/2] genirq: Fix the possible synchronize_irq() wait-forever

2014-02-21 Thread Thomas Gleixner
On Fri, 21 Feb 2014, Liu, Chuansheng wrote: > But feels there is another case which the synchronize_irq waited there > forever, > it is no waking up action from irq_thread(). > > CPU0 CPU1 > disable_irq() irq_thread() > synchronize_irq()

RE: [PATCH 1/2] genirq: Fix the possible synchronize_irq() wait-forever

2014-02-21 Thread Thomas Gleixner
On Fri, 21 Feb 2014, Liu, Chuansheng wrote: But feels there is another case which the synchronize_irq waited there forever, it is no waking up action from irq_thread(). CPU0 CPU1 disable_irq() irq_thread() synchronize_irq()

RE: [PATCH 1/2] genirq: Fix the possible synchronize_irq() wait-forever

2014-02-21 Thread Liu, Chuansheng
Hello Thomas, -Original Message- From: Thomas Gleixner [mailto:t...@linutronix.de] Sent: Friday, February 21, 2014 6:34 PM To: Liu, Chuansheng Cc: linux-kernel@vger.kernel.org; Wang, Xiaoming Subject: RE: [PATCH 1/2] genirq: Fix the possible synchronize_irq() wait-forever

RE: [PATCH 1/2] genirq: Fix the possible synchronize_irq() wait-forever

2014-02-21 Thread Thomas Gleixner
On Fri, 21 Feb 2014, Liu, Chuansheng wrote: Hello Thomas, -Original Message- From: Thomas Gleixner [mailto:t...@linutronix.de] Sent: Friday, February 21, 2014 6:34 PM To: Liu, Chuansheng Cc: linux-kernel@vger.kernel.org; Wang, Xiaoming Subject: RE: [PATCH 1/2] genirq: Fix

RE: [PATCH 1/2] genirq: Fix the possible synchronize_irq() wait-forever

2014-02-21 Thread Liu, Chuansheng
-Original Message- From: Thomas Gleixner [mailto:t...@linutronix.de] Sent: Friday, February 21, 2014 7:11 PM To: Liu, Chuansheng Cc: linux-kernel@vger.kernel.org; Wang, Xiaoming Subject: RE: [PATCH 1/2] genirq: Fix the possible synchronize_irq() wait-forever On Fri, 21 Feb

RE: [PATCH 1/2] genirq: Fix the possible synchronize_irq() wait-forever

2014-02-21 Thread Thomas Gleixner
On Fri, 21 Feb 2014, Liu, Chuansheng wrote: I think you have a point there, but not on x86 wherre the atomic_dec and the spinlock on the queueing side are full barriers. For non-x86 there is definitely a potential issue. But even on X86, spin_unlock has no full barrier, the

RE: [PATCH 1/2] genirq: Fix the possible synchronize_irq() wait-forever

2014-02-21 Thread Liu, Chuansheng
Hello Thomas, -Original Message- From: Thomas Gleixner [mailto:t...@linutronix.de] Sent: Friday, February 21, 2014 7:53 PM To: Liu, Chuansheng Cc: linux-kernel@vger.kernel.org; Wang, Xiaoming Subject: RE: [PATCH 1/2] genirq: Fix the possible synchronize_irq() wait-forever

RE: [PATCH 1/2] genirq: Fix the possible synchronize_irq() wait-forever

2014-02-21 Thread Thomas Gleixner
On Fri, 21 Feb 2014, Liu, Chuansheng wrote: -Original Message- From: Thomas Gleixner [mailto:t...@linutronix.de] Sent: Friday, February 21, 2014 7:53 PM To: Liu, Chuansheng Cc: linux-kernel@vger.kernel.org; Wang, Xiaoming Subject: RE: [PATCH 1/2] genirq: Fix the possible

RE: [PATCH 1/2] genirq: Fix the possible synchronize_irq() wait-forever

2014-02-20 Thread Liu, Chuansheng
Hello Thomas, > -Original Message- > From: Thomas Gleixner [mailto:t...@linutronix.de] > Sent: Thursday, February 20, 2014 8:53 PM > To: Liu, Chuansheng > Cc: linux-kernel@vger.kernel.org; Wang, Xiaoming > Subject: RE: [PATCH 1/2] genirq: Fix the possible synchronize_irq

RE: [PATCH 1/2] genirq: Fix the possible synchronize_irq() wait-forever

2014-02-20 Thread Thomas Gleixner
Xiaoming > > Subject: Re: [PATCH 1/2] genirq: Fix the possible synchronize_irq() > > wait-forever > > > > On Mon, 10 Feb 2014, Chuansheng Liu wrote: > > > There is below race between irq handler and irq thread: > > > irq handler

RE: [PATCH 1/2] genirq: Fix the possible synchronize_irq() wait-forever

2014-02-20 Thread Thomas Gleixner
On Thu, 20 Feb 2014, Liu, Chuansheng wrote: Hello Thomas, -Original Message- From: Thomas Gleixner [mailto:t...@linutronix.de] Sent: Monday, February 10, 2014 4:58 PM To: Liu, Chuansheng Cc: linux-kernel@vger.kernel.org; Wang, Xiaoming Subject: Re: [PATCH 1/2] genirq: Fix

RE: [PATCH 1/2] genirq: Fix the possible synchronize_irq() wait-forever

2014-02-20 Thread Liu, Chuansheng
Hello Thomas, -Original Message- From: Thomas Gleixner [mailto:t...@linutronix.de] Sent: Thursday, February 20, 2014 8:53 PM To: Liu, Chuansheng Cc: linux-kernel@vger.kernel.org; Wang, Xiaoming Subject: RE: [PATCH 1/2] genirq: Fix the possible synchronize_irq() wait-forever

RE: [PATCH 1/2] genirq: Fix the possible synchronize_irq() wait-forever

2014-02-19 Thread Liu, Chuansheng
Hello Thomas, > -Original Message- > From: Thomas Gleixner [mailto:t...@linutronix.de] > Sent: Monday, February 10, 2014 4:58 PM > To: Liu, Chuansheng > Cc: linux-kernel@vger.kernel.org; Wang, Xiaoming > Subject: Re: [PATCH 1/2] genirq: Fix the possible synchronize_irq

RE: [PATCH 1/2] genirq: Fix the possible synchronize_irq() wait-forever

2014-02-19 Thread Liu, Chuansheng
Hello Thomas, -Original Message- From: Thomas Gleixner [mailto:t...@linutronix.de] Sent: Monday, February 10, 2014 4:58 PM To: Liu, Chuansheng Cc: linux-kernel@vger.kernel.org; Wang, Xiaoming Subject: Re: [PATCH 1/2] genirq: Fix the possible synchronize_irq() wait-forever

Re: [PATCH 1/2] genirq: Fix the possible synchronize_irq() wait-forever

2014-02-10 Thread Thomas Gleixner
On Mon, 10 Feb 2014, Chuansheng Liu wrote: > There is below race between irq handler and irq thread: > irq handler irq thread > > irq_wake_thread() irq_thread() > set bit RUNTHREAD > ...clear bit RUNTHREAD >

[PATCH 1/2] genirq: Fix the possible synchronize_irq() wait-forever

2014-02-10 Thread Chuansheng Liu
There is below race between irq handler and irq thread: irq handler irq thread irq_wake_thread() irq_thread() set bit RUNTHREAD ...clear bit RUNTHREAD thread_fn()

[PATCH 1/2] genirq: Fix the possible synchronize_irq() wait-forever

2014-02-10 Thread Chuansheng Liu
There is below race between irq handler and irq thread: irq handler irq thread irq_wake_thread() irq_thread() set bit RUNTHREAD ...clear bit RUNTHREAD thread_fn()

Re: [PATCH 1/2] genirq: Fix the possible synchronize_irq() wait-forever

2014-02-10 Thread Thomas Gleixner
On Mon, 10 Feb 2014, Chuansheng Liu wrote: There is below race between irq handler and irq thread: irq handler irq thread irq_wake_thread() irq_thread() set bit RUNTHREAD ...clear bit RUNTHREAD