History | View | Annotate | Download (16.1 kB)
hw: include hw header files with full paths
Done with this script:
cd hwfor i in `find . -name '*.h' | sed 's/^..//'`; do echo '\,^#.*include.*["<]'$i'[">], s,'$i',hw/&,'done | sed -i -f - `find . -type f`
This is so that paths remain valid as files are moved....
fw_cfg: Remove FW_CFG_MAX_CPUS from fw_cfg_init()
PC will not use max_cpus for that field, so move it outside the commoncode so it can use a different value on PC.
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>Signed-off-by: Andreas Färber <afaerber@suse.de>
fw_cfg: Drop a few superfluous initializers
Signed-off-by: Markus Armbruster <armbru@redhat.com>Reviewed-by: Laszlo Ersek <lersek@redhat.com>Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
fw_cfg: Splash image loader can overrun a stack variable, fix
read_splashfile() passes the address of an int variable as size_t *parameter to g_file_get_contents(), with a cast to gag the compiler.
No problem on machines where sizeof(size_t) == sizeof(int)....
sysbus: Drop sysbus_from_qdev() cast macro
Replace by SYS_BUS_DEVICE() QOM cast macro using a scripted conversion.Avoids the old macro creeping into new code.
Resolve a Coding Style warning in openpic code.
Signed-off-by: Andreas Färber <afaerber@suse.de>...
vl: Use size_t for sizes in get_boot_devices_list()
Code mixes uint32_t, int and size_t. Very unlikely to go wrong inpractice, but clean it up anyway.
Signed-off-by: Markus Armbruster <armbru@redhat.com>Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
fw_cfg: Use void *, size_t instead of uint8_t *, uint32_t for blobs
Many callers pass size_t, which gets silently truncated to uint32_t.Harmless, because all practical sizes are well below 4GiB. Clean itup anyway. Size overflow now fails assertions....
fw_cfg: New fw_cfg_add_string()
fw_cfg: Dumb down fw_cfg_add_*() not to return success / failure
No caller is checking the value, so all errors get ignored, usuallysilently. assert() instead.
fw_cfg: Replace debug prints by tracepoints
Make all static TypeInfos const
Since 39bffca2030950ef6efe57c2fac8327a45ae1015 (qdev: register alltypes natively through QEMU Object Model), TypeInfo as used inthe common, non-iterative pattern is no longer amended with informationand should therefore be const....
softmmu: move include files to include/sysemu/
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
misc: move include files to include/qemu/
janitor: do not rely on indirect inclusions of or from qemu-char.h
Various header files rely on qemu-char.h including qemu-config.h ormain-loop.h, but they really do not need qemu-char.h at all (particularlyinteresting is the case of the block layer!). Clean this up, and also...
Rename target_phys_addr_t to hwaddr
target_phys_addr_t is unwieldly, violates the C standard (_t suffixes arereserved) and its purpose doesn't match the name (most target_phys_addr_taddresses are not target specific). Replace it with a finger-friendly,...
add a boot parameter to set reboot timeout
Added an option to let qemu transfer a configuration file to bios,"etc/boot-fail-wait", which could be specified by command -boot reboot-timeout=TT have a max value of 0xffff, unit is ms.
With this option, guest will wait for a given time if not find...
qom: Unify type registration
Replace device_init() with generalized type_init().
While at it, unify naming convention: type_init([$prefix_]register_types)Also, type_init() is a function, so add preceding blank line wherenecessary and don't put a semicolon after the closing brace....
qdev: register all types natively through QEMU Object Model
This was done in a mostly automated fashion. I did it in three steps and thenrebased it into a single step which avoids repeatedly touching every file inthe tree.
The first step was a sed-based addition of the parent type to the subclass...
sysbus: apic: ioapic: convert to QEMU Object Model
This converts three devices because apic and ioapic are subclasses of sysbus.Converting subclasses independently of their base class is prohibitively hard.
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
sysbus: rename sysbus_init_mmio_region() to sysbus_init_mmio()
Signed-off-by: Avi Kivity <avi@redhat.com>
fw_cfg: convert to memory API
Because the new API doesn't allow overlapping regions with just differentaccess sizes, we have to create a new "combined" region for both controland data, when the two share an ioport offset.
fw_cfg: Use g_file_get_contents instead of multiple fread() calls
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>Signed-off-by: Pavel Borzenkov <pavel.borzenkov@gmail.com>Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
fw_cfg: fix crash if FW_CFG_WRITE_CHANNEL is used incorrectly
Avoid a crash if the guest combines FW_CFG_WRITE_CHANNEL witha wrong value.
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
Use glib memory allocation and free functions
qemu_malloc/qemu_free no longer exist after this commit.
Check fread() results to avoid gcc 4.6 warnings
When compiling with gcc 4.6, some code in fw_cfg.c complains that fop_retis assigned but not used (which is true). However, it looks like themeaningless assignments to fop_ret were done to suppress other gcc warnings...
showing a splash picture when start
Added options to let qemu transfer two configuration files to bios:"bootsplash.bmp" and "etc/boot-menu-wait", which could be specified by command -boot splash=P,splash-time=TP is jpg/bmp file name or an absolute path, T have a max value of 0xffff, unit...
notifier: Pass data argument to callback
This allows to pass additional information to the notifier callbackwhich is useful if sender and receiver do not share any other distinctdata structure.
Will be used first for the clock reset notifier.
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>...
Pass boot device list to firmware.
Signed-off-by: Gleb Natapov <gleb@redhat.com>Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
Change fw_cfg_add_file() to get full file path as a parameter.
Change fw_cfg_add_file() to get full file path as a parameter insteadof building one internally. Two reasons for that. First caller may needto know how file is named. Second this moves policy of file naming out...
Add endianness as io mem parameter
As stated before, devices can be little, big or native endian. Thetarget endianness is not of their concern, so we need to push thingsdown a level.
This patch adds a parameter to cpu_register_io_memory that allows adevice to choose its endianness. For now, all devices simply choose...
fw_cfg: convert to qdev
Convert fw_cfg to qdev.
spelling typo (compatibilty) in hw/fw_cfg.c
here's a trivial patch to fix the spelling of "compatibility":
Signed-off-by: Vagrant Cascadian <vagrant@freegeek.org>Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
fw_cfg: don't use reserved _ prefix
fw_cfg: rom loader tweaks.
Changes: - make dir argument mandatory, we allways have one anyway (vgaroms or genroms). - check for duplicates, skip loading if found.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
fw_cfg: make calls typesafe
fw_cfg: add API for file transfer.
This patch adds a file transfer interface to fw_cfg. Intended to beused for passing non-pci option roms and vgabios to seabios. Namespaceis modeled after the existing cbfs filesystem support in seabios.
Reading the new FW_CFG_FILE_DIR entry returns a file list....
Add "static" to please Sparse
fw_cfg: change cur_offset to 32 bits
Signed-off-by: Juan Quintela <quintela@redhat.com>Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
sparc32 (mostly): remove unneeded calls to device reset
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. Somethinglike this must be presented on the list first so people can provide input...
Get rid of _t suffix
Some not so obvious bits, slirp and Xen were left alone for the timebeing.
Signed-off-by: malc <av1474@comtv.ru>
vmstate: port fw_cfg device
Make CPURead/WriteFunc structure 'const'
Introduce -smp , maxcpus= flag to specify maximum number of CPUS.
Follow on patch will use it to determine the size of the MADT andother BIOS tables.
Signed-off-by: Jes Sorensen <jes@sgi.com>Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Add boot menu control via command line switch
Disable the lengthy BIOS prompt for selecting a boot device by default,but let the user reenable it via '-boot menu=on'.
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Revert "Introduce reset notifier order"
This reverts commit 8217606e6edb49591b4a6fd5a0d1229cebe470a9 (andupdates later added users of qemu_register_reset), we solved theproblem it originally addressed less invasively.
Remove io_index argument from cpu_register_io_memory()
The parameter is always zero except when registering the three internalio regions (ROM, unassigned, notdirty). Remove the parameter to reducethe API's power, thus facilitating future change.
Signed-off-by: Avi Kivity <avi@redhat.com>...
Introduce reset notifier order
Add the parameter 'order' to qemu_register_reset and sort callbacks onregistration. On system reset, callbacks with lower order will beinvoked before those with higher order. Update all existing users to thestandard order 0....
Refactor how display drivers are selected
My previous commit, f92f8afebe, broke -vnc (spotted by Glauber Costa). Thisis because it's necessary to tell when the no special display parameters havebeen passed and default to SDL or VNC appropriately.
This refactors the display selection logic to be less complicated which has...
Replace gcc variadic macro extension with C99 version
Don't try to return result from a void function (spotted by Sparse)
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@7017 c046a42c-6fe2-441c-8c8c-71466251a162
hw: remove error handling from qemu_malloc() callers (Avi Kivity)
Signed-off-by: Avi Kivity <avi@redhat.com>Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6529 c046a42c-6fe2-441c-8c8c-71466251a162
Allow to register a callback with fw_cfg_add_callback()fw_cfg_add_callback() checks if key has FW_CFG_WRITE_CHANNEL bit setafter masking the key with FW_CFG_ENTRY_MASK.
But as FW_CFG_ENTRY_MASK is ~(FW_CFG_WRITE_CHANNEL | FW_CFG_ARCH_LOCAL),the bit is never set and function exits....
Move nographic export to sysemu.h
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5414 c046a42c-6fe2-441c-8c8c-71466251a162
Add common keys to firmware configuration
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5260 c046a42c-6fe2-441c-8c8c-71466251a162
Add UUID to firmware configuration info (Gleb Natapov)
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5259 c046a42c-6fe2-441c-8c8c-71466251a162
Key/value based qemu<->guest firmware communication mechanism (Gleb Natapov)
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5256 c046a42c-6fe2-441c-8c8c-71466251a162