]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
ENGR00294115 PXP: correct the pxp_dispatch thread exit logic
authorFancy Fang <B47543@freescale.com>
Wed, 8 Jan 2014 02:43:17 +0000 (10:43 +0800)
committerLothar Waßmann <LW@KARO-electronics.de>
Wed, 20 Aug 2014 08:06:53 +0000 (10:06 +0200)
We should add thread stop checking before handle pxp task,
since the wait condition includes this check.

Signed-off-by: Fancy Fang <B47543@freescale.com>
drivers/dma/pxp/pxp_dma_v2.c

index f4a70bdf2c366b9a168cdd5bfa30a0c1b12122a7..63d5d4e91b512f5416893606c6f665dff3880a42 100644 (file)
@@ -1673,6 +1673,9 @@ static int pxp_dispatch_thread(void *argv)
                if (signal_pending(current))
                        continue;
 
+               if (kthread_should_stop())
+                       break;
+
                spin_lock_irqsave(&pxp->lock, flags);
                pxp->pxp_ongoing = 1;
                spin_unlock_irqrestore(&pxp->lock, flags);