Currently, the inter-stutter interval is the same as the stutter duration, that is, whatever number of jiffies is passed into torture_stutter_init(). This has worked well for quite some time, but the addition of forward-progress testing to rcutorture can delay processes for several seconds, which can triple the time that they are stuttered. This commit therefore adds a second argument to torture_stutter_init() that specifies the inter-stutter interval. While locktorture preserves the current behavior, rcutorture uses the RCU CPU stall warning interval to provide a wider inter-stutter interval.
Showing the changes to include/linux (1 of 4 files). Show all
Unified · Split
| @@ -66,7 +66,7 @@ int torture_shutdown_init(int ssecs, void (*cleanup)(void)); · 65 unmodified lines | |||
| 66 | 66 | ||
| 67 | /* Task stuttering, which forces load/no-load transitions. */ | 67 | /* Task stuttering, which forces load/no-load transitions. */ |
| 68 | bool stutter_wait(const char *title); | 68 | bool stutter_wait(const char *title); |
| 69 | int torture_stutter_init(int s); | 69 | int torture_stutter_init(int s, int sgap); |
| 70 | 70 | ||
| 71 | /* Initialization and cleanup. */ | 71 | /* Initialization and cleanup. */ |
| 72 | bool torture_init_begin(char *ttype, int v); | 72 | bool torture_init_begin(char *ttype, int v); |