mirror of
				https://github.com/torvalds/linux.git
				synced 2025-11-04 10:40:15 +02:00 
			
		
		
		
	sched: symmetric sync vs avg_overlap
Reinstate the weakening of the sync hint if set. This yields a more symmetric usage of avg_overlap. Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl> Signed-off-by: Ingo Molnar <mingo@elte.hu>
This commit is contained in:
		
							parent
							
								
									d942fb6c7d
								
							
						
					
					
						commit
						1596e29773
					
				
					 1 changed files with 9 additions and 3 deletions
				
			
		| 
						 | 
					@ -2266,9 +2266,15 @@ static int try_to_wake_up(struct task_struct *p, unsigned int state, int sync)
 | 
				
			||||||
	if (!sched_feat(SYNC_WAKEUPS))
 | 
						if (!sched_feat(SYNC_WAKEUPS))
 | 
				
			||||||
		sync = 0;
 | 
							sync = 0;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	if (!sync && (current->se.avg_overlap < sysctl_sched_migration_cost &&
 | 
						if (!sync) {
 | 
				
			||||||
			    p->se.avg_overlap < sysctl_sched_migration_cost))
 | 
							if (current->se.avg_overlap < sysctl_sched_migration_cost &&
 | 
				
			||||||
 | 
								  p->se.avg_overlap < sysctl_sched_migration_cost)
 | 
				
			||||||
			sync = 1;
 | 
								sync = 1;
 | 
				
			||||||
 | 
						} else {
 | 
				
			||||||
 | 
							if (current->se.avg_overlap >= sysctl_sched_migration_cost ||
 | 
				
			||||||
 | 
								  p->se.avg_overlap >= sysctl_sched_migration_cost)
 | 
				
			||||||
 | 
								sync = 0;
 | 
				
			||||||
 | 
						}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#ifdef CONFIG_SMP
 | 
					#ifdef CONFIG_SMP
 | 
				
			||||||
	if (sched_feat(LB_WAKEUP_UPDATE)) {
 | 
						if (sched_feat(LB_WAKEUP_UPDATE)) {
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in a new issue