 43e0c3515d
			
		
	
	
		43e0c3515d
		
	
	
	
	
		
			
			Reuse of the same guard symbol in multiple headers is okay as long as
they cannot be included together.  scripts/clean-header-guards.pl
can't tell, so it warns.
Since we can avoid guard symbol reuse easily, do so: use guard symbol
${target^^}_${fname^^} for linux-user/$target/$fname, just like we did
in commit a9c94277f0..3500385697.
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Message-Id: <20190315145123.28030-4-armbru@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
		
	
			
		
			
				
	
	
		
			23 lines
		
	
	
		
			422 B
		
	
	
	
		
			C
		
	
	
	
	
	
			
		
		
	
	
			23 lines
		
	
	
		
			422 B
		
	
	
	
		
			C
		
	
	
	
	
	
| #ifndef RISCV_TARGET_CPU_H
 | |
| #define RISCV_TARGET_CPU_H
 | |
| 
 | |
| static inline void cpu_clone_regs(CPURISCVState *env, target_ulong newsp)
 | |
| {
 | |
|     if (newsp) {
 | |
|         env->gpr[xSP] = newsp;
 | |
|     }
 | |
| 
 | |
|     env->gpr[xA0] = 0;
 | |
| }
 | |
| 
 | |
| static inline void cpu_set_tls(CPURISCVState *env, target_ulong newtls)
 | |
| {
 | |
|     env->gpr[xTP] = newtls;
 | |
| }
 | |
| 
 | |
| static inline abi_ulong get_sp_from_cpustate(CPURISCVState *state)
 | |
| {
 | |
|    return state->gpr[xSP];
 | |
| }
 | |
| #endif
 |