qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] [RFC PATCH 0/4] Machine description as data


From: Markus Armbruster
Subject: [Qemu-devel] [RFC PATCH 0/4] Machine description as data
Date: Thu, 30 Apr 2009 18:03:44 +0200

Tenth iteration of the prototype.  Work in progress, not quite ready for
merging.

Four parts, parts 1 and 2 are cleanups (could be applied right away),
part 3 is straightforward preparation, and part 4 is the prototype:

    [PATCH 1/4] Confine use of global rtc_state to PC CMOS functions
    [PATCH 2/4] Remove global floppy_controller
    [PATCH 3/4] Give parse_macaddr() external linkage
    [PATCH 4/4] Machine description as data


New:

* Bunch PIC and I/O APIC together in the tree, to keep the interrupt
  graph a tree.

* Reduce device initialization dependencies.  Such dependencies arise
  when device A exposes its innards, typically in global variables, and
  device B rummages through them.  A then has to be initialized before
  B.  Fine if A is a parent of B (but even then, global variables are
  gauche), not so fine if they're siblings.

* Property "unit-address".  Recognized only for PCI devices so far, and
  implemented only by PIIX3.

* Rebased to commit 0ecdb16ef01ffbff7e5c88872e885c9f6c6e89c7.

Shortcuts:

* No support for systems lacking PCI bus or APIC.

* I didn't implement all the devices of the "pc" original.  Missing:
  - Audio
  - RAM above 4g

* The configuration tree is simplistic.  I expect it to evolve, and I
  wouldn't exclude the possibility of wholesale replacement.

* The initial configuration tree is hardcoded in dt_hardcoded_config().
  It should be read from a configuration file.

* The new, unified device API is implemented as wrappers around the old
  APIs.  Done that way because we want to explore the new API with
  minimal impact to the rest of the code.  Once we're satisfied with the
  new API, the old APIs should be replaced.

* A bus is identified by its kind and number.  The bus number depends on
  its position in the tree.  Means for position-independent addressing
  would be nice.

* The interface to the shared code in hw/pc.c (hw/pcint.h) is rather
  crude.

* The pc-misc driver should be split up completely.

* BIOS larger than 128KiB isn't implemented.  pc.c loads the BIOS once
  and maps it in two locations.  pcdt.c loads and maps it twice.

* PCI interrupt routing from LNKA..LNKD to GSIs ist not yet represented.

* Requires -disable-kqemu, because USE_KQEMU adds a dependence through
  global variable first_cpu.

Not in, but not forgotten either:

* A few more renames suggested by reviewers.

* Reduce unnecessary differences to IEEE 1275 trees.

Bugs (last checked in 7th iteration):

* hw/ppce500_mpc8544ds.c doesn't compile when I configure with fdt
  support.

* If I configure both a virtio block device and a virtio console, the
  Linux guest kernel hangs.  The same happens when I move virtio code in
  pc.c in an otherwise unmodified QEMU so that balloon and console are
  initialized earlier.


Markus Armbruster (4):
  Confine use of global rtc_state to PC CMOS functions
  Remove global floppy_controller
  Give parse_macaddr() external linkage
  Machine description as data

 Makefile              |    1 +
 Makefile.target       |    7 +-
 dt-fdt.c              |  123 +++++++
 dt-host.c             |  176 +++++++++
 dt.c                  |  600 +++++++++++++++++++++++++++++++
 dt.h                  |  150 ++++++++
 hw/boards.h           |    3 +
 hw/fdc.c              |   76 +++--
 hw/fdc.h              |    2 +-
 hw/pc.c               |   78 ++---
 hw/pcdt.c             |  941 +++++++++++++++++++++++++++++++++++++++++++++++++
 hw/pcidt.c            |   67 ++++
 hw/pcint.h            |   47 +++
 net.c                 |    2 +-
 net.h                 |    1 +
 target-i386/machine.c |    1 +
 tree.c                |  285 +++++++++++++++
 tree.h                |   41 +++
 18 files changed, 2522 insertions(+), 79 deletions(-)
 create mode 100644 dt-fdt.c
 create mode 100644 dt-host.c
 create mode 100644 dt.c
 create mode 100644 dt.h
 create mode 100644 hw/pcdt.c
 create mode 100644 hw/pcidt.c
 create mode 100644 hw/pcint.h
 create mode 100644 tree.c
 create mode 100644 tree.h





reply via email to

[Prev in Thread] Current Thread [Next in Thread]