Rename CPUState to CPUOldState.

Upstream qemu has split the cpu state into two new data structures:

  CPUState -> is used to model the CPU state through the QEMU
              object model.

  CPUArchState -> actually a macro that aliases CPUArmState,
                  CPUX86State or CPUMIPSState.

Both were part of the "CPUState" in the current emulator sources.

Previous patches introduced CPUArchState, as a simple alias to the
machine-specific state. This patch renames any use of CPUState in
the current code to CPUOldState, except within target-*/ directories
where it is replaced by CPU${ARCH}State instead.

This will allow bringing the upstream CPUState definition in the
source tree, and slowly migrate everything to the right location.

Change-Id: I88b79e6e89f1f36084dc2642e1cf415135e4da09
diff --git a/hw/android/android_mips.c b/hw/android/android_mips.c
index c55ef76..98a082f 100644
--- a/hw/android/android_mips.c
+++ b/hw/android/android_mips.c
@@ -71,7 +71,7 @@
 
 #define PHYS_TO_VIRT(x) ((x) | ~(target_ulong)0x7fffffff)
 
-static void android_load_kernel(CPUState *env, int ram_size, const char *kernel_filename,
+static void android_load_kernel(CPUOldState *env, int ram_size, const char *kernel_filename,
               const char *kernel_cmdline, const char *initrd_filename)
 {
     int initrd_size;
@@ -156,7 +156,7 @@
     const char *initrd_filename,
     const char *cpu_model)
 {
-    CPUState *env;
+    CPUOldState *env;
     qemu_irq *goldfish_pic;
     int i;
     ram_addr_t ram_offset;
diff --git a/hw/android/goldfish/pipe.c b/hw/android/goldfish/pipe.c
index 7f3dd90..5c2a64c 100644
--- a/hw/android/goldfish/pipe.c
+++ b/hw/android/goldfish/pipe.c
@@ -966,7 +966,7 @@
 {
     Pipe** lookup = pipe_list_findp_channel(&dev->pipes, dev->channel);
     Pipe*  pipe   = *lookup;
-    CPUState* env = cpu_single_env;
+    CPUOldState* env = cpu_single_env;
 
     /* Check that we're referring a known pipe channel */
     if (command != PIPE_CMD_OPEN && pipe == NULL) {
diff --git a/hw/android/goldfish/vmem.c b/hw/android/goldfish/vmem.c
index e676b61..95c6a05 100644
--- a/hw/android/goldfish/vmem.c
+++ b/hw/android/goldfish/vmem.c
@@ -26,7 +26,7 @@
 // and on AMD some of those ioctls (in particular KVM_GET_MSRS) are 10 to 100x
 // slower than on Intel chips.
 
-int safe_memory_rw_debug(CPUState *env, target_ulong addr, uint8_t *buf,
+int safe_memory_rw_debug(CPUOldState *env, target_ulong addr, uint8_t *buf,
                          int len, int is_write)
 {
 #ifdef TARGET_I386
@@ -37,7 +37,7 @@
     return cpu_memory_rw_debug(env, addr, buf, len, is_write);
 }
 
-hwaddr safe_get_phys_page_debug(CPUState *env, target_ulong addr)
+hwaddr safe_get_phys_page_debug(CPUOldState *env, target_ulong addr)
 {
 #ifdef TARGET_I386
     if (kvm_enabled()) {