qemu-discuss
[Top][All Lists]
Advanced

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

[Qemu-discuss] Guidance requested creating a QEMU MMIO device


From: trasmussen
Subject: [Qemu-discuss] Guidance requested creating a QEMU MMIO device
Date: Tue, 16 Apr 2019 11:53:12 +0200

I am trying to create a new device in QEMU that is supposed to be a memory 
mapped device at some physical address and of some size.
The idea is to set up .read and .write functions that get control when the 
user application reads from or writes to the MMIO device, similar to other 
devices.
It should NOT be PCI!

I have not been able to locate any similar devices inside my 3.0.0 QEMU 
build environment, except the one described by mmio_interface.h and 
mmio_interface.c which I understand is internal to QEMU and not supposed 
to be used.

Various device examples I have consulted lack the precise details of how 
such a device-driver should look (though mmio_interface.c perhaps here 
could be used as a template?).

I have realized that other controlling files need to be updated as well, 
e.g. ./output/qemu-3.0.0/hw/misc/Makefile.objs and 
./output/qemu-3.0.0/default-configs/pci.mak and probably more (which?). Is 
there a description of how you 'add' your new device to a qemu?

I was hoping that the configuration values for the MMIO-device could be 
provided when starting the QEMU-image, along with other entities you see 
when you use the -v option. So there must be a standard way to pass this 
information on from the invocation to the actual device they were written 
for.

Which sources would provide enough information to allow them to be used as 
templates for my MMIO device.

Thanks.

        Thorkil B. Rasmussen
        address@hidden



reply via email to

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