@@ -438,9 +438,9 @@ static unsigned long srcu_readers_lock_idx(struct srcu_struct *ssp, int idx)
438
438
unsigned long sum = 0 ;
439
439
440
440
for_each_possible_cpu (cpu ) {
441
- struct srcu_data * cpuc = per_cpu_ptr (ssp -> sda , cpu );
441
+ struct srcu_data * sdp = per_cpu_ptr (ssp -> sda , cpu );
442
442
443
- sum += atomic_long_read (& cpuc -> srcu_lock_count [idx ]);
443
+ sum += atomic_long_read (& sdp -> srcu_lock_count [idx ]);
444
444
}
445
445
return sum ;
446
446
}
@@ -456,11 +456,11 @@ static unsigned long srcu_readers_unlock_idx(struct srcu_struct *ssp, int idx)
456
456
unsigned long sum = 0 ;
457
457
458
458
for_each_possible_cpu (cpu ) {
459
- struct srcu_data * cpuc = per_cpu_ptr (ssp -> sda , cpu );
459
+ struct srcu_data * sdp = per_cpu_ptr (ssp -> sda , cpu );
460
460
461
- sum += atomic_long_read (& cpuc -> srcu_unlock_count [idx ]);
461
+ sum += atomic_long_read (& sdp -> srcu_unlock_count [idx ]);
462
462
if (IS_ENABLED (CONFIG_PROVE_RCU ))
463
- mask = mask | READ_ONCE (cpuc -> srcu_reader_flavor );
463
+ mask = mask | READ_ONCE (sdp -> srcu_reader_flavor );
464
464
}
465
465
WARN_ONCE (IS_ENABLED (CONFIG_PROVE_RCU ) && (mask & (mask - 1 )),
466
466
"Mixed NMI-safe readers for srcu_struct at %ps.\n" , ssp );
@@ -564,12 +564,12 @@ static bool srcu_readers_active(struct srcu_struct *ssp)
564
564
unsigned long sum = 0 ;
565
565
566
566
for_each_possible_cpu (cpu ) {
567
- struct srcu_data * cpuc = per_cpu_ptr (ssp -> sda , cpu );
567
+ struct srcu_data * sdp = per_cpu_ptr (ssp -> sda , cpu );
568
568
569
- sum += atomic_long_read (& cpuc -> srcu_lock_count [0 ]);
570
- sum += atomic_long_read (& cpuc -> srcu_lock_count [1 ]);
571
- sum -= atomic_long_read (& cpuc -> srcu_unlock_count [0 ]);
572
- sum -= atomic_long_read (& cpuc -> srcu_unlock_count [1 ]);
569
+ sum += atomic_long_read (& sdp -> srcu_lock_count [0 ]);
570
+ sum += atomic_long_read (& sdp -> srcu_lock_count [1 ]);
571
+ sum -= atomic_long_read (& sdp -> srcu_unlock_count [0 ]);
572
+ sum -= atomic_long_read (& sdp -> srcu_unlock_count [1 ]);
573
573
}
574
574
return sum ;
575
575
}
0 commit comments