Statistics
| Branch: | Revision:

root / hw / ppce500_mpc8544ds.c @ 4e4fa398

History | View | Annotate | Download (13.1 kB)

# Date Author Comment
c5705a77 01/04/2012 01:34 pm Avi Kivity

vmstate, memory: decouple vmstate from memory API

Currently creating a memory region automatically registers it for
live migration. This differs from other state (which is enumerated
in a VMStateDescription structure) and ties the live migration code
into the memory core....

2646c133 10/17/2011 04:59 pm Avi Kivity

ppcr500_mpc8544ds: convert to memory API

Signed-off-by: Avi Kivity <>

df2921d3 10/09/2011 02:11 pm Avi Kivity

Merge remote-tracking branch 'upstream' into memory/batch

  • upstream: (87 commits)
    target-alpha: Fix compilation errors for 32 bit hosts
    target-alpha: Add high-resolution access to wall clock and an alarm.
    target-alpha: Implement HALT IPR.
    target-alpha: Implement WAIT IPR....
ddd1055b 10/06/2011 10:48 am Fabien Chouteau

PPC: booke timers

While working on the emulation of the freescale p2010 (e500v2) I realized that
there's no implementation of booke's timers features. Currently mpc8544 uses
ppc_emb (ppc_emb_timers_init) which is close but not exactly like booke (for
example booke uses different SPR)....

93dd5e85 10/06/2011 10:48 am Scott Wood

kvm: ppc: booke206: use MMU API

Share the TLB array with KVM. This allows us to set the initial TLB
both on initial boot and reset, is useful for debugging, and could
eventually be used to support migration.

Signed-off-by: Scott Wood <>...

2bd9543c 10/06/2011 10:48 am Scott Wood

ppc: booke206: use MAV=2.0 TSIZE definition, fix 4G pages

This definition is backward compatible with MAV=1.0 as long as
the guest does not set reserved bits in MAS1/MAS4.

Also, fix the shift in booke206_tlb_to_page_size -- it's the base
that should be able to hold a 4G page size, not the shift count....

1e3debf0 10/06/2011 10:48 am Alexander Graf

MPC8544DS: Generate CPU nodes on init

With this patch, we generate CPU nodes in the machine initialization, giving
us the freedom to generate as many nodes as we want and as the machine supports,
but only those.

This is a first step towards a much cleaner device tree generation...

a2a67420 10/06/2011 10:48 am Alexander Graf

PPC: E500: Bump CPU count to 15

Now that we have everything in place, make the machine description
aware of the fact that we can now handle 15 virtual CPUs!

Signed-off-by: Alexander Graf <>


v1 -> v2:

- Max cpus is 15 because of MPIC
10f25a46 10/06/2011 10:48 am Alexander Graf

PPC: E500: Update cpu-release-addr property in cpu nodes

The guest OS wants to know where the guest spins, so let's tell him while
updating the CPU nodes with the frequencies anyways.

Signed-off-by: Alexander Graf <>


v1 -> v2:

- use new spin table address
5c145dac 10/06/2011 10:47 am Alexander Graf

PPC: E500: Add PV spinning code

CPUs that are not the boot CPU need to run in spinning code to check if they
should run off to execute and if so where to jump to. This usually happens
by leaving secondary CPUs looping and checking if some variable in memory...

621d05e3 10/06/2011 10:43 am Alexander Graf

PPC: E500: Update freqs for all CPUs

Now that we can so nicely find out the host's frequencies, we should also
make sure that we get them into all virtual CPUs' device tree nodes.

Signed-off-by: Alexander Graf <>

66bc7e00 10/06/2011 10:43 am Alexander Graf

PPC: E500: Remove unneeded CPU nodes

We should only keep CPU nodes in the device tree around that we really have
virtual CPUs for. So remove all superfluous entries that we just keep there
in case someone wants to create a lot of vCPUs.

Signed-off-by: Alexander Graf <>

911d6e7a 10/06/2011 10:43 am Alexander Graf

PPC: E500: Use generic kvm function for freq

Now that we have generic KVM functions to read out the host tb and clock
frequencies, let's use them in the e500 code!

Signed-off-by: Alexander Graf <>

66ae7902 10/06/2011 10:43 am Alexander Graf

PPC: E500: Remove mpc8544_copy_soc_cell

We don't need mpc8544_copy_soc_cell anymore, since we're explicitly reading
host values and writing guest values respectively.

Signed-off-by: Alexander Graf <>

e61c36d5 10/06/2011 10:43 am Alexander Graf

PPC: E500: create multiple envs

When creating a VM, we should go through smp_cpus and create a virtual CPU for
every CPU the user requested. This patch adds support for that and moves some
code around to make that more convenient.

Signed-off-by: Alexander Graf <>

a915249f 10/06/2011 10:43 am Alexander Graf

PPC: E500: Generate IRQ lines for many CPUs

Now that we can generate multiple envs for all our virtual CPUs, we
also need to tell the MPIC that we have multiple CPUs connected and
connect them all to the respective virtual interrupt lines.

Signed-off-by: Alexander Graf <>

39186d8a 10/02/2011 05:14 pm Richard Henderson

serial: Add MemoryRegion parameter to serial_mm_init

Remove the get_system_memory() call from serial_mm_init, pushing
it back into the callers. In many cases we already have the
system memory region available.

Signed-off-by: Richard Henderson <>...

71cf9e62 10/02/2011 05:14 pm Fabien Chouteau

openpic: Memory API conversion for mpic

This patch converts mpic to the new memory API (through old mmio).

Signed-off-by: Fabien Chouteau <>
Signed-off-by: Avi Kivity <>

fb50cfe4 10/02/2011 05:14 pm Richard Henderson

serial: Use enum device_endian in serial_mm_init parameter

The use of DEVICE_NATIVE_ENDIAN cleans up lots of ifdefs in
many of the callers.

Signed-off-by: Richard Henderson <>
Signed-off-by: Avi Kivity <>

2ff0c7c3 10/02/2011 05:14 pm Richard Henderson

serial: Remove ioregister parameter from serial_mm_init

All callers passed 1.

Signed-off-by: Richard Henderson <>
Signed-off-by: Avi Kivity <>

7267c094 08/21/2011 07:01 am Anthony Liguori

Use glib memory allocation and free functions

qemu_malloc/qemu_free no longer exist after this commit.

Signed-off-by: Anthony Liguori <>

d1e256fe 06/17/2011 03:58 am Alexander Graf

PPC: E500: Use MAS registers instead of internal TLB representation

The natural format for e500 cores to do TLB manipulation with are the MAS
registers. Instead of converting them into some internal representation
and back again when the guest reads them, we can just keep the data...

5de6b46d 06/17/2011 03:58 am Alexander Graf

PPC: mpc8544ds: Add hypervisor node

When running a PPC guest with KVM that can do PV operations, we need
to indicate the guest which instructions to use for a hypercall and
that it is running as KVM guest.

This logic was available on openbios based machines already. This patch...

b0fb8423 06/17/2011 03:58 am Alexander Graf

PPC: E500: Implement reboot controller

When Linux reboots an e500 VM, it writes to a magic register in the
"global-utilities" device indicated by the device tree. We were not
emulating that device so far, rendering the VM reboot-less.

This patch implements that device with only the reboot functionality...

d461e3b9 06/03/2011 01:42 pm Alexander Graf

PPC: fix mpc8544ds pci default devices

After the Qdev'ification of the MPC8544DS board and PCI bus, the internal
PCI bus name changed from "pci" to "pci.0". Reflect this change in the
search for that bus.

This patch enables networking on e500 guests again....

be13cc7a 05/12/2011 01:24 am Alexander Graf

PPC: Qdev'ify e500 pci

The e500 PCI controller isn't qdev'ified yet. This leads to severe issues
when running with -drive.

To be able to use a virtio disk with an e500 VM, let's convert the PCI
controller over to qdev.

Reviewed-by: Paul Brook <>...

ef250db6 05/12/2011 01:24 am Alexander Graf

PPC: Make MPC8544DS obey -cpu switch

The MPC8544DS board emulation code ignored the user defined -cpu switch.
This patch enables it to only provide a sane default, not force an e500v2
CPU inside.

Signed-off-by: Alexander Graf <>

3b989d49 05/12/2011 01:24 am Alexander Graf

PPC: Make MPC8544DS emulation work w/o KVM

The MPC8544DS board emulation was only used with KVM so far, so some
parts of the code didn't provide proper values for non-KVM execution.

This patch makes the machine work without KVM enabled. To actually use
this, you also need proper e500v2 MMU emulation....

5389055a 05/12/2011 01:24 am Alexander Graf

PPC MPC7544DS: Use new TLB helper function

Now that we have some nice helpers that can find us a TLB entry, let's
use that on the machine initialization code, so we don't need to know
about the internals of the TLB array.

Signed-off-by: Alexander Graf <>

64a4d100 04/08/2011 12:32 pm Scott Wood

Don't call cpu_synchronize_state() from machine init.

This will deadlock when the I/O thread is used, since the
CPU thread is blocked waiting for qemu_system_ready.

The synchronization is unnecessary since this is before
cpu_synchronize_all_post_init()....

968d683c 12/11/2010 05:24 pm Alexander Graf

isa_mmio: Always use little endian

This patch converts the ISA MMIO bridge code to always use little endian mmio.
All bswap code that existed was only there to convert from native cpu
endianness to little endian ISA devices.

Signed-off-by: Alexander Graf <>...

49a2942d 10/13/2010 09:41 pm Blue Swirl

Delete write only variables

Compiling with GCC 4.6.0 20100925 produced warnings like:
/src/qemu/net/tap-win32.c: In function 'tap_win32_open':
/src/qemu/net/tap-win32.c:582:12: error: variable 'hThread' set but not used [-Werror=unused-but-set-variable]
...

1724f049 07/06/2010 06:36 pm Alex Williamson

qemu_ram_alloc: Add DeviceState and name parameters

These will be used to generate unique id strings for ramblocks. The name
field is required, the device pointer is optional as most callers don't
have a device. When there's no device or the device isn't a child of...

2d48377a 03/21/2010 09:47 pm Blue Swirl

Compile serial only once

Push TARGET_WORDS_BIGENDIAN dependency to board level.

Signed-off-by: Blue Swirl <>

84108e12 03/21/2010 09:47 pm Blue Swirl

Compile isa_mmio only once

Push TARGET_WORDS_BIGENDIAN dependency to board level.

Signed-off-by: Blue Swirl <>

409dbce5 03/16/2010 09:38 am Aurelien Jarno

load_elf: replace the address addend by a translation function

A few machines need to translate the ELF header addresses into physical
addresses. Currently the only possibility is to add a value to the
addresses.

This patch replaces the addend argument by and a translation function...

75bb6589 02/27/2010 08:48 pm Liu Yu

powerpc/e500: adjust fdt and ramdisk loading addr

Since kernel uimage is getting bigger,
old fixed loading bases will result in regions overlap.

Add pad for fdt and ramdisk, so that they won't overlap with uimage.

Signed-off-by: Liu Yu <>...

dbf916d8 02/27/2010 08:47 pm Aurelien Jarno

powerpc: fix compilation with CONFIG_FDT undefined

Signed-off-by: Aurelien Jarno <>

04088adb 02/27/2010 05:30 pm Liu Yu

powerpc/booke: move fdt loading to rom infrastructure

It's convinent to use rom to checking overlap, to reset etc.
And uImage and ramdisk loading has already moved to it.

Also, after we add fdt to rom, free it.

Signed-off-by: Liu Yu <>...

c4963817 02/27/2010 05:21 pm Liu Yu

target-ppc: add synchronize register for booke init

So that the following registers init could be flushed back to kvm.

Signed-off-by: Liu Yu <>
Acked-by: Hollis Blanchard <>
Signed-off-by: Aurelien Jarno <>

07caea31 10/05/2009 05:32 pm Markus Armbruster

Fix pci_add nic not to exit on bad model

Monitor command "pci_add ADDR nic model=MODEL" uses pci_nic_init() to
create the NIC. When MODEL is unknown or "?", this prints to stderr
and terminates the program.

Change pci_nic_init() not to treat "?" specially, and to return NULL...

c227f099 10/02/2009 12:12 am Anthony Liguori

Revert "Get rid of _t suffix"

In the very least, a change like this requires discussion on the list.

The naming convention is goofy and it causes a massive merge problem. Something
like this must be presented on the list first so people can provide input...

99a0949b 10/01/2009 09:45 pm malc

Get rid of _t suffix

Some not so obvious bits, slirp and Xen were left alone for the time
being.

Signed-off-by: malc <>

ca20cf32 09/20/2009 05:58 pm Blue Swirl

Compile loader only once

Callers must pass ELF machine, byte swapping and symbol LSB clearing
information to ELF loader. A.out loader needs page size information, pass
that too as a parameter.

Extract prototypes to a separate file. Move loader.[ch] and elf_ops.h under hw....

d176c495 08/10/2009 09:05 pm Gerd Hoffmann

qdev-ify virtio-blk.

First user of the new drive property. With this patch applied host
and guest config can be specified separately, like this:

-drive if=none,id=disk1,file=/path/to/disk.img
-device virtio-blk-pci,drive=disk1

You can set any property for virtio-blk-pci now. You can set the pci...

3f0855b1 07/27/2009 10:09 pm Juan Quintela

Rename HAVE_FDT to CONFIG_FDT and define it also in Makefile

Signed-off-by: Juan Quintela <>
Signed-off-by: Anthony Liguori <>

751c6a17 07/27/2009 10:08 pm Gerd Hoffmann

kill drives_table

First step cleaning up the drives handling. This one does nothing but
removing drives_table[], still it became seriously big.

drive_get_index() is gone and is replaced by drives_get() which hands
out DriveInfo pointers instead of a table index. This needs adaption in...

5607c388 06/22/2009 06:15 pm Markus Armbruster

Support addr=... in option argument of -net nic

Make net_client_init() accept addr=, put the value into struct
NICinfo. Use it in pci_nic_init(), and remove arguments bus and
devfn.

Don't support addr= in third argument of monitor command pci_add,
because that clashes with its first argument. Admittedly unelegant....

c2cc47a4 06/22/2009 06:15 pm Markus Armbruster

Support addr=... in option argument of -drive if=virtio

Make drive_init() accept addr=, put the value into struct DriveInfo.
Use it in all the places that create virtio-blk-pci devices:
pc_init1(), bamboo_init(), mpc8544ds_init().

Don't support addr= in third argument of monitor command pci_add and...

5cea8590 05/30/2009 03:59 am Paul Brook

Use relative path for bios

Look for bios and other support files relative to qemu binary, rather than
a hardcoded prefix.

Signed-off-by: Paul Brook <>

f80f9ec9 05/21/2009 04:47 pm Anthony Liguori

Convert machine registration to use module init functions

This cleans up quite a lot of #ifdefs, extern variables, and other ugliness.

Signed-off-by: Anthony Liguori <>

53c25cea 05/18/2009 08:26 pm Paul Brook

Separate virtio PCI code

Split the PCI host bindings from the VRing transport implementation.

Signed-off-by: Paul Brook <>

07e3af9a 05/15/2009 12:35 am Paul Brook

Virtio-blk qdev conversion

Signed-off-by: Paul Brook <>

fbe1b595 05/13/2009 07:56 pm Paul Brook

Remove vga_ram_size

The vga_ram_size argument to machine init functions always has the same
value, and is ignored by many machines (including SPARC32 which has an
obsolete ifdef for VGA_RAM_SIZE).

Remove it and push VGA_RAM_SIZE into vga_int.h.

Signed-off-by: Paul Brook <>

190cd021 04/11/2009 08:33 pm pbrook

Remove redundant ram_require machine properly.

Signed-off-by: Paul Brook <>

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@7090 c046a42c-6fe2-441c-8c8c-71466251a162

7ec632b4 04/10/2009 07:23 pm pbrook

Wean device tree code off phys_ram_base.

Signed-off-by: Paul Brook <>

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@7068 c046a42c-6fe2-441c-8c8c-71466251a162

d7585251 04/10/2009 06:36 am pbrook

More phys_ram_base elimination.

Signed-off-by: Paul Brook <>

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@7064 c046a42c-6fe2-441c-8c8c-71466251a162

511d2b14 03/07/2009 05:32 pm blueswir1

Sparse fixes: NULL use, header order, ANSI prototypes, static

Fix Sparse warnings: * use NULL instead of plain 0 * rearrange header include order to avoid redefining types accidentally * ANSIfy SLIRP * avoid "restrict" keyword * add static

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6736 c046a42c-6fe2-441c-8c8c-71466251a162

1db09b84 03/02/2009 06:42 pm aurel32

kvm/powerpc: Add MPC8544DS board support

This patch add an emulation of MPC8544DS board.
It can work on All E500 platforms.

Signed-off-by: Liu Yu <>
Acked-by: Hollis Blanchard <>
Signed-off-by: Aurelien Jarno <>...