Hierarchical memory region API

The memory API separates the attributes of a memory region (its size, how
reads or writes are handled, dirty logging, and coalescing) from where it
is mapped and whether it is enabled.  This allows a device to configure
a memory region once, then hand it off to its parent bus to map it according
to the bus configuration.

Hierarchical registration also allows a device to compose a region out of
a number of sub-regions with different properties; for example some may be
RAM while others may be MMIO.

Reviewed-by: Anthony Liguori <aliguori@us.ibm.com>
Signed-off-by: Avi Kivity <avi@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
3 files changed
tree: a75dc34dbddaeb5283025f182eb9a84022b1bfff
  1. audio/
  2. block/
  3. bsd-user/
  4. darwin-user/
  5. default-configs/
  6. docs/
  7. fpu/
  8. fsdev/
  9. gdb-xml/
  10. hw/
  11. libcacard/
  12. linux-headers/
  13. linux-user/
  14. net/
  15. pc-bios/
  16. qapi/
  17. qga/
  18. QMP/
  19. roms/
  20. scripts/
  21. slirp/
  22. sysconfigs/
  23. target-alpha/
  24. target-arm/
  25. target-cris/
  26. target-i386/
  27. target-lm32/
  28. target-m68k/
  29. target-microblaze/
  30. target-mips/
  31. target-ppc/
  32. target-s390x/
  33. target-sh4/
  34. target-sparc/
  35. target-unicore32/
  36. tcg/
  37. tests/
  38. ui/
  39. .gitignore
  40. .gitmodules
  41. a.out.h
  42. acl.c
  43. acl.h
  44. aes.c
  45. aes.h
  46. aio.c
  47. alpha-dis.c
  48. alpha.ld
  49. arch_init.c
  50. arch_init.h
  51. arm-dis.c
  52. arm-semi.c
  53. arm.ld
  54. async.c
  55. balloon.c
  56. balloon.h
  57. bitmap.c
  58. bitmap.h
  59. bitops.c
  60. bitops.h
  61. block-migration.c
  62. block-migration.h
  63. block.c
  64. block.h
  65. block_int.h
  66. blockdev.c
  67. blockdev.h
  68. bswap.h
  69. bt-host.c
  70. bt-host.h
  71. bt-vhci.c
  72. buffered_file.c
  73. buffered_file.h
  74. cache-utils.c
  75. cache-utils.h
  76. Changelog
  77. check-qdict.c
  78. check-qfloat.c
  79. check-qint.c
  80. check-qjson.c
  81. check-qlist.c
  82. check-qstring.c
  83. cmd.c
  84. cmd.h
  85. CODING_STYLE
  86. compatfd.c
  87. compatfd.h
  88. compiler.h
  89. config.h
  90. configure
  91. console.c
  92. console.h
  93. COPYING
  94. COPYING.LIB
  95. cpu-all.h
  96. cpu-common.h
  97. cpu-defs.h
  98. cpu-exec.c
  99. cpus.c
  100. cpus.h
  101. cris-dis.c
  102. cursor.c
  103. cursor_hidden.xpm
  104. cursor_left_ptr.xpm
  105. cutils.c
  106. def-helper.h
  107. device_tree.c
  108. device_tree.h
  109. dis-asm.h
  110. disas.c
  111. disas.h
  112. dma-helpers.c
  113. dma.h
  114. dyngen-exec.h
  115. elf.h
  116. envlist.c
  117. envlist.h
  118. error.c
  119. error.h
  120. error_int.h
  121. exec-all.h
  122. exec.c
  123. gdbstub.c
  124. gdbstub.h
  125. gen-icount.h
  126. HACKING
  127. hmp-commands.hx
  128. host-utils.c
  129. host-utils.h
  130. hpet.h
  131. hppa-dis.c
  132. hppa.ld
  133. i386-dis.c
  134. i386.ld
  135. ia64-dis.c
  136. ia64.ld
  137. input.c
  138. iohandler.c
  139. ioport-user.c
  140. ioport.c
  141. ioport.h
  142. iorange.h
  143. iov.c
  144. iov.h
  145. json-lexer.c
  146. json-lexer.h
  147. json-parser.c
  148. json-parser.h
  149. json-streamer.c
  150. json-streamer.h
  151. kvm-all.c
  152. kvm-stub.c
  153. kvm.h
  154. libfdt_env.h
  155. LICENSE
  156. linux-aio.c
  157. m68k-dis.c
  158. m68k-semi.c
  159. m68k.ld
  160. MAINTAINERS
  161. Makefile
  162. Makefile.dis
  163. Makefile.hw
  164. Makefile.objs
  165. Makefile.target
  166. Makefile.user
  167. memory.c
  168. memory.h
  169. microblaze-dis.c
  170. migration-exec.c
  171. migration-fd.c
  172. migration-tcp.c
  173. migration-unix.c
  174. migration.c
  175. migration.h
  176. mips-dis.c
  177. mips.ld
  178. module.c
  179. module.h
  180. monitor.c
  181. monitor.h
  182. nbd.c
  183. nbd.h
  184. net.c
  185. net.h
  186. notify.c
  187. notify.h
  188. os-posix.c
  189. os-win32.c
  190. osdep.c
  191. osdep.h
  192. oslib-posix.c
  193. oslib-win32.c
  194. path.c
  195. pci-ids.txt
  196. pflib.c
  197. pflib.h
  198. poison.h
  199. posix-aio-compat.c
  200. ppc-dis.c
  201. ppc.ld
  202. ppc64.ld
  203. qapi-schema-guest.json
  204. qapi-schema-test.json
  205. qbool.c
  206. qbool.h
  207. qdict-test-data.txt
  208. qdict.c
  209. qdict.h
  210. qemu-aio.h
  211. qemu-barrier.h
  212. qemu-char.c
  213. qemu-char.h
  214. qemu-common.h
  215. qemu-config.c
  216. qemu-config.h
  217. qemu-doc.texi
  218. qemu-error.c
  219. qemu-error.h
  220. qemu-ga.c
  221. qemu-img-cmds.hx
  222. qemu-img.c
  223. qemu-img.texi
  224. qemu-io.c
  225. qemu-lock.h
  226. qemu-log.h
  227. qemu-malloc.c
  228. qemu-nbd.c
  229. qemu-nbd.texi
  230. qemu-objects.h
  231. qemu-option.c
  232. qemu-option.h
  233. qemu-options.h
  234. qemu-options.hx
  235. qemu-os-posix.h
  236. qemu-os-win32.h
  237. qemu-progress.c
  238. qemu-queue.h
  239. qemu-sockets.c
  240. qemu-tech.texi
  241. qemu-thread-posix.c
  242. qemu-thread-posix.h
  243. qemu-thread-win32.c
  244. qemu-thread-win32.h
  245. qemu-thread.h
  246. qemu-timer-common.c
  247. qemu-timer.c
  248. qemu-timer.h
  249. qemu-tool.c
  250. qemu-x509.h
  251. qemu.sasl
  252. qemu_socket.h
  253. qerror.c
  254. qerror.h
  255. qfloat.c
  256. qfloat.h
  257. qint.c
  258. qint.h
  259. qjson.c
  260. qjson.h
  261. qlist.c
  262. qlist.h
  263. qmp-commands.hx
  264. qobject.h
  265. qstring.c
  266. qstring.h
  267. range.h
  268. readline.c
  269. readline.h
  270. README
  271. rules.mak
  272. rwhandler.c
  273. rwhandler.h
  274. s390-dis.c
  275. s390.ld
  276. savevm.c
  277. sh4-dis.c
  278. simpletrace.c
  279. simpletrace.h
  280. softmmu-semi.h
  281. softmmu_defs.h
  282. softmmu_exec.h
  283. softmmu_header.h
  284. softmmu_template.h
  285. sparc-dis.c
  286. sparc.ld
  287. sparc64.ld
  288. spice-qemu-char.c
  289. sysemu.h
  290. targphys.h
  291. tcg-runtime.c
  292. test-qmp-commands.c
  293. test-visitor.c
  294. thunk.c
  295. thunk.h
  296. TODO
  297. trace-events
  298. translate-all.c
  299. uboot_image.h
  300. usb-bsd.c
  301. usb-linux.c
  302. usb-redir.c
  303. usb-stub.c
  304. user-exec.c
  305. VERSION
  306. version.rc
  307. vgafont.h
  308. vl.c
  309. x86_64.ld
  310. xen-all.c
  311. xen-mapcache.c
  312. xen-mapcache.h
  313. xen-stub.c