mirror of
				https://github.com/RGBCube/serenity
				synced 2025-10-31 15:42:44 +00:00 
			
		
		
		
	Kernel: Only use the TSC when it is invariant
This commit is contained in:
		
							parent
							
								
									cf48200e7b
								
							
						
					
					
						commit
						0cfcac7900
					
				
					 1 changed files with 1 additions and 2 deletions
				
			
		|  | @ -381,8 +381,7 @@ UNMAP_AFTER_INIT void Scheduler::initialize() | |||
|     VERIFY(Processor::is_initialized()); // sanity check
 | ||||
| 
 | ||||
|     // Figure out a good scheduling time source
 | ||||
|     if (Processor::current().has_feature(CPUFeature::TSC)) { | ||||
|         // TODO: only use if TSC is running at a constant frequency?
 | ||||
|     if (Processor::current().has_feature(CPUFeature::TSC) && Processor::current().has_feature(CPUFeature::CONSTANT_TSC)) { | ||||
|         current_time = current_time_tsc; | ||||
|     } else { | ||||
|         // TODO: Using HPET is rather slow, can we use any other time source that may be faster?
 | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Markus Pfeifenberger
						Markus Pfeifenberger