"exec/cpu-common.h" is meant to contain the declarations related to CPU usable with any accelerator / target combination. tcg_flush_jmp_cache() is specific to TCG, so restrict its declaration by moving it to "exec/tb-flush.h". Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org> Reviewed-by: Anton Johansson <anjo@rev.ng> Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Message-Id: <20230918104153.24433-2-philmd@linaro.org>
		
			
				
	
	
		
			29 lines
		
	
	
		
			794 B
		
	
	
	
		
			C
		
	
	
	
	
	
			
		
		
	
	
			29 lines
		
	
	
		
			794 B
		
	
	
	
		
			C
		
	
	
	
	
	
/*
 | 
						|
 * tb-flush prototype for use by the rest of the system.
 | 
						|
 *
 | 
						|
 * Copyright (c) 2022 Linaro Ltd
 | 
						|
 *
 | 
						|
 * SPDX-License-Identifier: GPL-2.0-or-later
 | 
						|
 */
 | 
						|
#ifndef _TB_FLUSH_H_
 | 
						|
#define _TB_FLUSH_H_
 | 
						|
 | 
						|
/**
 | 
						|
 * tb_flush() - flush all translation blocks
 | 
						|
 * @cs: CPUState (must be valid, but treated as anonymous pointer)
 | 
						|
 *
 | 
						|
 * Used to flush all the translation blocks in the system. Sometimes
 | 
						|
 * it is simpler to flush everything than work out which individual
 | 
						|
 * translations are now invalid and ensure they are not called
 | 
						|
 * anymore.
 | 
						|
 *
 | 
						|
 * tb_flush() takes care of running the flush in an exclusive context
 | 
						|
 * if it is not already running in one. This means no guest code will
 | 
						|
 * run until this complete.
 | 
						|
 */
 | 
						|
void tb_flush(CPUState *cs);
 | 
						|
 | 
						|
void tcg_flush_jmp_cache(CPUState *cs);
 | 
						|
 | 
						|
#endif /* _TB_FLUSH_H_ */
 |