upstream integration

This patch is a merge of a series of 42 upstream integration patches
into the emulator's master branch.

The individual patches come from the 'upstream-integrate'
branch that was uploaded separately on kernel.org.

The reference upstream sources used for this integration come
from http://meego.gitorious.org/qemu-maemo/qemu using the following
hash:

    7243fbd089cce3c06ca24ed173a251f32644863c

In a nutshell, the goal is to make our source tree closer to upstream
in order to use various improvement there. Unfortunately, we're not to
the point where we can use the upstream ARMv7-A / NEON translator,
though we're getting close.

Major changes are:

- integrate upstream TCG and softfloat

- target-arm: Move most Android-specific helper functions to helper-android.c
  and translate-android.h. This is in preparation of a _major_ integration
  of the upstream ARM translator.

- moving various functions to different files (e.g. cpus.c,
  qemu-os-posix.c, qemu-os-win32.c, arch_init.c, etc)

- qemu-char-android.c is now gone. We're using qemu-char.c
  with slight modifications embedded within CONFIG_ANDROID-guarded
  ifdef blocks.

- rename "trace.h" to "android-trace.h". We still need to keep
  "trace.h" and "trace_common.h" until we also update
  sdk/emulator/tools/qtools/ to use the new header names.

  After this, we will integrate in a future integration
  the auto-generated trace.h used by upstream.

- remove the OutputChannel hack. Instead, implement a "fake Monitor"
  object that can be used with any function that takes a Monitor as
  input. The fake Monitor is used to collect output into a dynamic
  buffer (e.g. during snapshot save/load).

- convert to upstream QEMUTimer API changes.

- implement physical memory with RAMBlock lists (instead of a single array).

Short log of individual changes:

    406a59b trace.h: rename to trace-android.h
    288208c target-arm/translate.c: move Android-specific stuff out.
    f1d9bf1 tcg: integrate upstream version
    280afa0 ramblocks: integrate upstream implementation (sophisticated)
    ae3098a vl-android.c: move arch-specific functions to arch_init.c
    23ca2ae vl-android.c: move cpu functions to cpus.c
    c1ac40a vl-android.c: use os-specific setup routines
    e49c3f3 compatfd.c: minor integrate
    4276038 cpu-exec.c: minor integrate
    3b2846a qemu-char-android.c: rename to qemu-char.c
    f645f7d cpu_restore_state: remove un-necessary argument.
    f0753ac qjson.c: minor integrate
    8354d2d vl-android.c: Move code to iohandler.c
    d3d4468 translate-all.c: minor integrate
    1f9ec0f qemu-config.c: minor integrate
    d09775c monitor.c: minor integrate
    9f64011 disas.c: minor integrate
    69ed952 device_tree.c: minor integrate
    e1c0948 bswap.h + others: minor integrate
    6b9236d buffered_file.c: minor integrate
    95a83ce savevm: Remove OutputBuffer hack.
    986acc9 savevm.c: minor integrate
    39373b1 arm-semi.c: minor integrate
    fb955c7 README: minor integrate
    8ee4e5e trace: simplify code and avoid conflicts
    65d1521 acl.c: minor integrate
    c98cf7b arm-dis.c: minor integrate
    bfec547 fpu: upstream integrate
    9bfb3d5 json-lexer.c, json-parser.c: minor integrate
    6eaacfb trace.h: minor C compatibility fixes.
    17410ee qemu-char.h, console.h: upstream integration
    5973c77 qemu-timer.c: rename qemu_timer_new_scale()
    317c9d5 qemu-timer.c: upstream integrate
    47dc1f4 qerror: minor integrate
    488bfd5 qemu-error: minor integrate
    1646b4e posix-aio-compat.c: minor integrate
    088edf8 os-posix.c + os-win32.c and dependencies
    795bb19 qemu-common.h: other intergrates
    45c3be0 integrate: qemu-common.h changes

Change-Id: If5771dd4b030c602b99845d7489d1f55406bf159
tree: e9dbb51e71a14aa9118f8e9c980d4722abb04fd8
  1. android/
  2. audio/
  3. block/
  4. distrib/
  5. docs/
  6. elff/
  7. fpu/
  8. gdb-xml/
  9. hw/
  10. images/
  11. memcheck/
  12. pc-bios/
  13. proxy/
  14. slirp/
  15. slirp-android/
  16. target-arm/
  17. target-i386/
  18. tcg/
  19. telephony/
  20. .gitignore
  21. a.out.h
  22. acl.c
  23. acl.h
  24. aes.c
  25. aes.h
  26. aio-android.c
  27. aio.c
  28. alpha.ld
  29. android-configure.sh
  30. android-rebuild.sh
  31. android-trace.h
  32. android-trace_common.h
  33. Android.mk
  34. arch_init.c
  35. arch_init.h
  36. arm-dis.c
  37. arm-semi.c
  38. arm.ld
  39. async.c
  40. balloon.h
  41. block.c
  42. block.h
  43. block_int.h
  44. blockdev.c
  45. blockdev.h
  46. bswap.h
  47. bt-host.c
  48. bt-host.h
  49. bt-vhci.c
  50. buffered_file.c
  51. buffered_file.h
  52. cache-utils.c
  53. cache-utils.h
  54. cbuffer.c
  55. cbuffer.h
  56. Changelog
  57. CHANGES.TXT
  58. charpipe.c
  59. charpipe.h
  60. CleanSpec.mk
  61. compatfd.c
  62. compatfd.h
  63. console.c
  64. console.h
  65. COPYING
  66. COPYING.LIB
  67. cpu-all.h
  68. cpu-common.h
  69. cpu-defs.h
  70. cpu-exec.c
  71. cpus.c
  72. cpus.h
  73. curses.c
  74. curses_keys.h
  75. cutils.c
  76. d3des.c
  77. d3des.h
  78. def-helper.h
  79. device_tree.c
  80. device_tree.h
  81. dis-asm.h
  82. disas.c
  83. disas.h
  84. dma-helpers.c
  85. dma.h
  86. dyngen-exec.h
  87. dynlink-static.c
  88. dynlink.h
  89. elf.h
  90. elf_ops.h
  91. envlist.c
  92. envlist.h
  93. exec-all.h
  94. exec.c
  95. feature_to_c.sh
  96. gdbstub.c
  97. gdbstub.h
  98. gen-charmap.py
  99. gen-icount.h
  100. gen-skin.py
  101. host-defs.h
  102. host-utils.c
  103. host-utils.h
  104. hostregs_helper.h
  105. hpet.h
  106. hxtool
  107. i386-dis.c
  108. i386-vl.ld
  109. i386.ld
  110. ia64.ld
  111. input.c
  112. INSTALL
  113. iohandler.c
  114. iolooper-select.c
  115. iolooper.h
  116. ioport-user.c
  117. ioport.c
  118. ioport.h
  119. json-lexer.c
  120. json-lexer.h
  121. json-parser.c
  122. json-parser.h
  123. json-streamer.c
  124. json-streamer.h
  125. keymaps.c
  126. keymaps.h
  127. kqemu.c
  128. kqemu.h
  129. kvm-all.c
  130. kvm-android.c
  131. kvm-android.h
  132. kvm.h
  133. LICENSE
  134. linux_keycodes.h
  135. loader.c
  136. loadpng.c
  137. m68k.ld
  138. Makefile
  139. Makefile.android
  140. Makefile.common
  141. Makefile.target
  142. migration-dummy-android.c
  143. migration-exec.c
  144. migration-tcp-android.c
  145. migration-tcp.c
  146. migration.c
  147. migration.h
  148. module.c
  149. module.h
  150. MODULE_LICENSE_GPL
  151. monitor-android.h
  152. monitor.c
  153. monitor.h
  154. net-android.c
  155. net-checksum.c
  156. net.c
  157. net.h
  158. NOTICE
  159. notify.c
  160. notify.h
  161. offset_layout.py
  162. os-posix.c
  163. os-win32.c
  164. osdep.c
  165. osdep.h
  166. oslib-posix.c
  167. oslib-win32.c
  168. path.c
  169. poison.h
  170. posix-aio-compat.c
  171. ppc-dis.c
  172. ppc.ld
  173. qbool.c
  174. qbool.h
  175. qdict.c
  176. qdict.h
  177. qemu-aio.h
  178. qemu-barrier.h
  179. qemu-char.c
  180. qemu-char.h
  181. qemu-common.h
  182. qemu-config.c
  183. qemu-config.h
  184. qemu-error.c
  185. qemu-error.h
  186. qemu-io.c
  187. qemu-lock.h
  188. qemu-log.h
  189. qemu-malloc.c
  190. qemu-monitor.hx
  191. qemu-objects.h
  192. qemu-option.c
  193. qemu-option.h
  194. qemu-options.h
  195. qemu-options.hx
  196. qemu-os-posix.h
  197. qemu-os-win32.h
  198. qemu-queue.h
  199. qemu-sockets-android.c
  200. qemu-sockets.c
  201. qemu-thread.c
  202. qemu-thread.h
  203. qemu-timer-common.c
  204. qemu-timer.c
  205. qemu-timer.h
  206. qemu_debug.h
  207. qemu_file.h
  208. qemu_socket.h
  209. qemu_timers.h
  210. qerror.c
  211. qerror.h
  212. qfloat.c
  213. qfloat.h
  214. qint.c
  215. qint.h
  216. qjson.c
  217. qjson.h
  218. qlist.c
  219. qlist.h
  220. qobject.h
  221. qstring.c
  222. qstring.h
  223. readline.c
  224. readline.h
  225. README
  226. savevm.c
  227. sdl_keysym.h
  228. shaper.c
  229. shaper.h
  230. sockets.c
  231. sockets.h
  232. softmmu-semi.h
  233. softmmu_defs.h
  234. softmmu_exec.h
  235. softmmu_header.h
  236. softmmu_outside_jit.c
  237. softmmu_outside_jit.h
  238. softmmu_template.h
  239. sparc.ld
  240. sys-tree.h
  241. sysemu.h
  242. tap-win32.c
  243. targphys.h
  244. tcpdump.c
  245. tcpdump.h
  246. thunk.c
  247. thunk.h
  248. trace.c
  249. trace.h
  250. trace_common.h
  251. translate-all.c
  252. translate-op.c
  253. translate.make
  254. uboot_image.h
  255. usb-dummy-android.c
  256. usb-linux.c
  257. user-events-qemu.c
  258. user-events.h
  259. varint.c
  260. varint.h
  261. vgafont.h
  262. vl-android-ui.c
  263. vl-android.c
  264. vl.c
  265. vnc-android.c
  266. vnc-tls.h
  267. vnc.c
  268. vnc.h
  269. vnc_keysym.h
  270. vnchextile.h
  271. x86_64.ld