virt: Add a func to enable/disable cpu

Signed-off-by: Li Yang <liyang.fnst@cn.fujitsu.com>
@liyangfnst Hi can we put the get cpu status related code to one separated function. Althrough we don't have cases to use it now. But maybe it can be used in the future.