File tree Expand file tree Collapse file tree 1 file changed +7
-0
lines changed Expand file tree Collapse file tree 1 file changed +7
-0
lines changed Original file line number Diff line number Diff line change @@ -1091,8 +1091,11 @@ static void udma_check_tx_completion(struct work_struct *work)
10911091 u32 residue_diff ;
10921092 ktime_t time_diff ;
10931093 unsigned long delay ;
1094+ unsigned long flags ;
10941095
10951096 while (1 ) {
1097+ spin_lock_irqsave (& uc -> vc .lock , flags );
1098+
10961099 if (uc -> desc ) {
10971100 /* Get previous residue and time stamp */
10981101 residue_diff = uc -> tx_drain .residue ;
@@ -1127,6 +1130,8 @@ static void udma_check_tx_completion(struct work_struct *work)
11271130 break ;
11281131 }
11291132
1133+ spin_unlock_irqrestore (& uc -> vc .lock , flags );
1134+
11301135 usleep_range (ktime_to_us (delay ),
11311136 ktime_to_us (delay ) + 10 );
11321137 continue ;
@@ -1143,6 +1148,8 @@ static void udma_check_tx_completion(struct work_struct *work)
11431148
11441149 break ;
11451150 }
1151+
1152+ spin_unlock_irqrestore (& uc -> vc .lock , flags );
11461153}
11471154
11481155static irqreturn_t udma_ring_irq_handler (int irq , void * data )
You can’t perform that action at this time.
0 commit comments