xen-hvm: Remove redundant variable 'xstate'
In xen_hvm_change_state_handler(), we can pass 'opaque' with type cast to xen_main_loop_prepare() directly, there's no need to use additional variable for it. Signed-off-by: Chen Gang <gang.chen.5i5j@gmail.com> Acked-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com> Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
This commit is contained in:
		
							parent
							
								
									7f151e6f71
								
							
						
					
					
						commit
						d208a85f15
					
				| 
						 | 
					@ -993,9 +993,8 @@ static void xen_main_loop_prepare(XenIOState *state)
 | 
				
			||||||
static void xen_hvm_change_state_handler(void *opaque, int running,
 | 
					static void xen_hvm_change_state_handler(void *opaque, int running,
 | 
				
			||||||
                                         RunState rstate)
 | 
					                                         RunState rstate)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
    XenIOState *xstate = opaque;
 | 
					 | 
				
			||||||
    if (running) {
 | 
					    if (running) {
 | 
				
			||||||
        xen_main_loop_prepare(xstate);
 | 
					        xen_main_loop_prepare((XenIOState *)opaque);
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in New Issue