summary refs log tree commit diff stats
Commit message (Collapse)AuthorAgeFilesLines
...
* | | slirp: slirp/slirp.c coding style cleanupStefan Hajnoczi2013-02-211-297/+311
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The slirp glue code uses tabs in some places. Since the next patch will modify the file, convert tabs to spaces and fix checkpatch.pl issues. Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com> Message-id: 1361356113-11049-5-git-send-email-stefanha@redhat.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* | | main-loop: switch POSIX glib integration to GPollFDStefan Hajnoczi2013-02-211-49/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Convert glib file descriptor polling from rfds/wfds/xfds to GPollFD. The Windows code still needs poll_fds[] and n_poll_fds but they can now become local variables. Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com> Message-id: 1361356113-11049-4-git-send-email-stefanha@redhat.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* | | main-loop: switch to g_poll() on POSIX hostsStefan Hajnoczi2013-02-211-8/+129
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Use g_poll(3) instead of select(2). Well, this is kind of a cheat. It's true that we're now using g_poll(3) on POSIX hosts but the *_fill() and *_poll() functions are still using rfds/wfds/xfds. We've set the scene to start converting *_fill() and *_poll() functions step-by-step until no more rfds/wfds/xfds users remain. Then we'll drop the temporary gpollfds_from_select() and gpollfds_to_select() functions and be left with native g_poll(2). On Windows things are a little crazy: convert from rfds/wfds/xfds to GPollFDs, back to rfds/wfds/xfds, call select(2), rfds/wfds/xfds back to GPollFDs, and finally back to rfds/wfds/xfds again. This is only temporary and keeps the Windows build working through the following patches. We'll drop this excessive conversion later and be left with a single GPollFDs -> select(2) -> GPollFDs sequence that allows Windows to use select(2) while the rest of QEMU only knows about GPollFD. Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com> Message-id: 1361356113-11049-3-git-send-email-stefanha@redhat.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* | | main-loop: fix select_ret uninitialized variable warningStefan Hajnoczi2013-02-211-1/+2
| |/ |/| | | | | | | | | | | Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com> Reviewed-by: Laszlo Ersek <lersek@redhat.com> Message-id: 1361356113-11049-2-git-send-email-stefanha@redhat.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* | Merge remote-tracking branch 'kraxel/usb.78' into stagingAnthony Liguori2013-02-2144-291/+742
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | # By Gerd Hoffmann # Via Gerd Hoffmann * kraxel/usb.78: uas-uas: usb3 streams usb-xhci: usb3 streams usb-core: usb3 streams usb: fix endpoint descriptor ordering usb-redir: simplify packet copy usb: make usb_packet_copy operate on combined packets usb: add usb_ep_set_halted usb-host: remove usb_host_device_close usb-host: move legacy cmd line bits usb-storage: use scsi_req_enqueue return value allow disabling usb smartcard support make usb devices configurable fix scripts/make_device_config.sh usb: Makefile cleanup
| * | uas-uas: usb3 streamsGerd Hoffmann2013-02-191-42/+205
| | | | | | | | | | | | | | | | | | Add usb3 streams support to the uas (usb attached scsi) emulation. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * | usb-xhci: usb3 streamsGerd Hoffmann2013-02-192-48/+226
| | | | | | | | | | | | | | | | | | | | | Add streams support to the xhci emulation. No secondary streams yet, only linear stream arays are supported for now. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * | usb-core: usb3 streamsGerd Hoffmann2013-02-1914-31/+37
| | | | | | | | | | | | | | | | | | | | | This patch adds support for usb3 streams to the usb subsystem core. This is just adding a streams field / parameter in a number of places. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * | usb: fix endpoint descriptor orderingGerd Hoffmann2013-02-191-4/+5
| | | | | | | | | | | | | | | | | | | | | | | | Fix the ordering of the endpoint descriptors for superspeed endpoints: The superspeed companion must come first, possible additional descriptors for the endpoint after that. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * | usb-redir: simplify packet copyGerd Hoffmann2013-02-191-14/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | usb_packet_copy can handle combined packets now, so it isn't needed to special-case them any more. Also use the new usb_packet_size() function. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * | usb: make usb_packet_copy operate on combined packetsGerd Hoffmann2013-02-192-5/+15
| | | | | | | | | | | | | | | | | | | | | Likewise usb_packet_skip. Also usb_packet_size. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * | usb: add usb_ep_set_haltedGerd Hoffmann2013-02-192-0/+7
| | | | | | | | | | | | Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * | usb-host: remove usb_host_device_closeGerd Hoffmann2013-02-195-38/+3
| | | | | | | | | | | | | | | | | | Nobody implements that anyway. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * | usb-host: move legacy cmd line bitsGerd Hoffmann2013-02-195-102/+191
| | | | | | | | | | | | | | | | | | | | | The code handling the "-usbdevice host:..." legacy command line syntax is moved to the new hw/usb/host-legacy.c file. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * | usb-storage: use scsi_req_enqueue return valueGerd Hoffmann2013-02-191-2/+3
| | | | | | | | | | | | Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * | allow disabling usb smartcard supportGerd Hoffmann2013-02-192-1/+2
| | | | | | | | | | | | Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * | make usb devices configurableGerd Hoffmann2013-02-1917-8/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Leave the core usb devices (usb hub, tablet, mouse, keyboard) enabled unconditionally. Make the other ones configurable. Exceptions: - bluetooth: not qdevified yet, has a vl.c dependency because of that, thus disabling isn't as easy as not linking the object file. - smardcard: ccid-card-emulated depends on that one *and* CONFIG_SMARTCARD_NSS. So it isn't a one-liner and comes as separate patch because of that. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * | fix scripts/make_device_config.shGerd Hoffmann2013-02-191-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Make it handle multiple include statements in a file: (1) The printf needs a space so the include files will be separated. (2) Also $f can contain multiple failes, so redirection will not work and we have to use cat to process all files. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * | usb: Makefile cleanupGerd Hoffmann2013-02-191-7/+20
| |/ | | | | | | | | | | Group files, sprinkle in some comments. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
* | Merge remote-tracking branch 'stefanha/trivial-patches' into stagingAnthony Liguori2013-02-215-3/+14
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | # By Alin Tomescu (1) and others # Via Stefan Hajnoczi * stefanha/trivial-patches: .gitignore: Ignore optionrom/*.asm ppc: fix bamboo >256MB RAM initialization in hw/ppc4xx_devs.c Add some missing qtest binaries to .gitignore xilinx_axienet.c: Assert no error when making link Remove forward declaration of non-existant variable
| * | .gitignore: Ignore optionrom/*.asmCole Robinson2013-02-211-0/+3
| | | | | | | | | | | | | | | Signed-off-by: Cole Robinson <crobinso@redhat.com> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
| * | ppc: fix bamboo >256MB RAM initialization in hw/ppc4xx_devs.cAlin Tomescu2013-02-211-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | I was trying to launch a PowerPC "bamboo" machine with more than 256MB of RAM with qemu-system-ppc -M bamboo -kernel $kernel -initrd $ramdisk -m 512, but QEMU would just hang. However, when I used -m 256, the machine would boot. I looked through the code in hw/ and it seems there is an error when the RAM memory is setup (if my understanding is correct). After patching it, the machine launched and booted successfully with 512MB of RAM. Signed-off-by: Alin Tomescu <tomescu.alin@gmail.com> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
| * | Add some missing qtest binaries to .gitignoreDavid Gibson2013-02-211-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | These binaries are generated during make check on at least some configurations, so att them to .gitignore. Signed-off-by: David Gibson <david@gibson.dropbear.id.au> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
| * | xilinx_axienet.c: Assert no error when making linkPeter Crosthwaite2013-02-211-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | This gives an awful silent failure when it doesn't work. Assert against link creation failure. Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
| * | Remove forward declaration of non-existant variableHervé Poussineau2013-02-211-1/+0
| |/ | | | | | | | | | | | | This variable has been removed 5 years ago in 970ac5a3082428dca91171f270dcd95d6f4b2636. Signed-off-by: Hervé Poussineau <hpoussin@reactos.org> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
* | rtc-test: add testcases for alarms in 12hour modePaolo Bonzini2013-02-181-3/+199
| | | | | | | | | | | | | | | | | | | | | | Trying (unsuccessfully) to break the device model as mentioned in https://bugs.launchpad.net/qemu/+bug/1090558. At least if someone tries to fix that, it won't break what works... Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Message-id: 1357922817-17584-3-git-send-email-pbonzini@redhat.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* | rtc-test: always set register B in its entiretyPaolo Bonzini2013-02-181-27/+9
|/ | | | | | | | Eliminate dependencies between one test and the others. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Message-id: 1357922817-17584-2-git-send-email-pbonzini@redhat.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* vnc-tls: Fix compilation with newer versions of GNU-TLSAndre Przywara2013-02-181-3/+3
| | | | | | | | | | | | | | | In my installation of GNU-TLS (v3.0.23) the type gnutls_anon_server_credentials is marked deprecated, so -Werror breaks compilation. Simply replacing it with the newer ..._t version fixed the compilation on my machine (Slackware 14.0). I cannot tell how far back this "new" type goes, at least the header file in RHEL 5.0 (v1.4.1) seems to have it already. If someone finds a broken distribution, tell me and I insert some compat code. Signed-off-by: Andre Przywara <andre.przywara@amd.com> Message-id: 1350551818-14717-1-git-send-email-andre.przywara@amd.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* doc help: Collect block device stuff under its own headingMarkus Armbruster2013-02-181-291/+281
| | | | | | | | | | Collect them from "Standard options", "File system options", "Virtual File system pass-through options", "Debug/Expert options". Signed-off-by: Markus Armbruster <armbru@redhat.com> Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com> Message-id: 1360781383-28635-8-git-send-email-armbru@redhat.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* doc help: A few options are under inappropriate headings, fixMarkus Armbruster2013-02-181-41/+39
| | | | | | | | | | | --device is under heading "USB options". --name and --uuid are under "Virtual File system pass-through options". Move all three to "Standard options". Signed-off-by: Markus Armbruster <armbru@redhat.com> Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com> Message-id: 1360781383-28635-7-git-send-email-armbru@redhat.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* help: Fix markup of heading "USB options" so it appears in -helpMarkus Armbruster2013-02-181-1/+2
| | | | | | | Signed-off-by: Markus Armbruster <armbru@redhat.com> Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com> Message-id: 1360781383-28635-6-git-send-email-armbru@redhat.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* doc: Fix texinfo @table markup in qemu-options.hxMarkus Armbruster2013-02-181-19/+37
| | | | | | | | | | | | | End tables before headings, start new ones afterwards. Fixes incorrect indentation of headings "File system options" and "Virtual File system pass-through options" in manual page and qemu-doc. Normalize markup some to increase chances it survives future edits. Signed-off-by: Markus Armbruster <armbru@redhat.com> Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com> Message-id: 1360781383-28635-5-git-send-email-armbru@redhat.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* doc: Fill some option doc gaps in manual page and qemu-docMarkus Armbruster2013-02-181-4/+12
| | | | | | | Signed-off-by: Markus Armbruster <armbru@redhat.com> Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com> Message-id: 1360781383-28635-4-git-send-email-armbru@redhat.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* doc: Fix some option entries in qemu-doc's function indexMarkus Armbruster2013-02-181-2/+5
| | | | | | | Signed-off-by: Markus Armbruster <armbru@redhat.com> Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com> Message-id: 1360781383-28635-3-git-send-email-armbru@redhat.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* help: Drop bogus help on -qtest and -qtest-logMarkus Armbruster2013-02-181-7/+3
| | | | | | | Signed-off-by: Markus Armbruster <armbru@redhat.com> Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com> Message-id: 1360781383-28635-2-git-send-email-armbru@redhat.com Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* isa: Split off instance_init for ISADeviceAndreas Färber2013-02-181-3/+9
| | | | | | | | | Prepares for assigning IRQs before QOM realize. Signed-off-by: Andreas Färber <afaerber@suse.de> Signed-off-by: Andreas Färber <afaerber@suse.de> Message-id: 1361010446-1427-1-git-send-email-afaerber@suse.de Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* qtest: Add MMIO supportAndreas Färber2013-02-187-29/+332
| | | | | | | | | | | | | Introduce [qtest_]{read,write}[bwlq]() libqtest functions and corresponding QTest protocol commands to replace local versions in libi2c-omap.c. Also convert m48t59-test's cmos_{read,write}_mmio() to {read,write}b(). Signed-off-by: Andreas Färber <afaerber@suse.de> Signed-off-by: Andreas Färber <afaerber@suse.de> Message-id: 1361051043-27944-4-git-send-email-afaerber@suse.de Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* libqtest: Introduce qtest_qmpv() and convert remaining macroAndreas Färber2013-02-182-5/+29
| | | | | | | | | | | | | In order to convert qmp() macro to an inline function, expose a qtest_qmpv() function, reused by qtest_qmp(). We can't apply GCC_FMT_ATTR() since fdc-test is using zero-length format strings, which would result in warnings treated as errors. Signed-off-by: Andreas Färber <afaerber@suse.de> Signed-off-by: Andreas Färber <afaerber@suse.de> Message-id: 1361051043-27944-3-git-send-email-afaerber@suse.de Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* libqtest: Convert macros to functions and clean up documentationAndreas Färber2013-02-181-50/+110
| | | | | | | | | | | | | | | | | libqtest.h provides a number of shortcut macros to avoid tests feeding it the QTestState they operate on. Most of these can easily be turned into static inline functions, so let's do that for clarity. This avoids getting off-by-one error messages when passing wrong args. Some macros had a val argument but documented @value argument. Fix this. While touching things, enforce gtk-doc markup for return values and for referencing types. Signed-off-by: Andreas Färber <afaerber@suse.de> Signed-off-by: Andreas Färber <afaerber@suse.de> Message-id: 1361051043-27944-2-git-send-email-afaerber@suse.de Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
* Merge remote-tracking branch 'afaerber/qom-cpu' into stagingAnthony Liguori2013-02-1883-363/+780
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | # By Andreas Färber # Via Andreas Färber * afaerber/qom-cpu: (47 commits) target-i386: Split command line parsing out of cpu_x86_register() target-i386: Move cpu_x86_init() target-lm32: Drop unused cpu_lm32_close() prototype target-s390x: Drop unused cpu_s390x_close() prototype spapr_hcall: Replace open-coded CPU loop with qemu_get_cpu() ppce500_spin: Replace open-coded CPU loop with qemu_get_cpu() e500: Replace open-coded loop with qemu_get_cpu() cpu: Add CPUArchState pointer to CPUState cputlb: Pass CPUState to cpu_unlink_tb() cpu: Move current_tb field to CPUState cpu: Move exit_request field to CPUState cpu: Move running field to CPUState cpu: Move host_tid field to CPUState target-cris: Introduce CRISCPU subclasses target-m68k: Pass M68kCPU to m68k_set_irq_level() mcf_intc: Pass M68kCPU to mcf_intc_init() mcf5206: Pass M68kCPU to mcf5206_init() target-m68k: Return M68kCPU from cpu_m68k_init() ppc405_uc: Pass PowerPCCPU to ppc40x_{core,chip,system}_reset() target-xtensa: Move TCG initialization to XtensaCPU initfn ...
| * target-i386: Split command line parsing out of cpu_x86_register()Andreas Färber2013-02-162-41/+40
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In order to instantiate a CPU subtype we will need to know which type, so move the cpu_model splitting into cpu_x86_init(). Parameters need to be set on the X86CPU instance, so move cpu_x86_parse_featurestr() into cpu_x86_init() as well. This leaves cpu_x86_register() operating on the model name only. Signed-off-by: Andreas Färber <afaerber@suse.de> Signed-off-by: Igor Mammedov <imammedo@redhat.com> Reviewed-by: Eduardo Habkost <ehabkost@redhat.com> Signed-off-by: Andreas Färber <afaerber@suse.de>
| * target-i386: Move cpu_x86_init()Andreas Färber2013-02-163-26/+25
| | | | | | | | | | | | | | | | | | | | | | Consolidate CPU functions in cpu.c. Allows to make cpu_x86_register() static. No functional changes. Reviewed-by: Eduardo Habkost <ehabkost@redhat.com> Reviewed-by: Igor Mammedov <imammedo@redhat.com> Signed-off-by: Andreas Färber <afaerber@suse.de>
| * target-lm32: Drop unused cpu_lm32_close() prototypeAndreas Färber2013-02-161-1/+0
| | | | | | | | | | | | It was never implemented. Signed-off-by: Andreas Färber <afaerber@suse.de>
| * target-s390x: Drop unused cpu_s390x_close() prototypeAndreas Färber2013-02-161-1/+0
| | | | | | | | | | | | It was never implemented. Signed-off-by: Andreas Färber <afaerber@suse.de>
| * spapr_hcall: Replace open-coded CPU loop with qemu_get_cpu()Andreas Färber2013-02-161-8/+3
| | | | | | | | | | | | | | | | | | | | The helper functions all access ppc-specific fields only so don't bother to change arguments to PowerPCCPU and use env_ptr instead. No functional change. Acked-by: Alexander Graf <agraf@suse.de> Signed-off-by: Andreas Färber <afaerber@suse.de>
| * ppce500_spin: Replace open-coded CPU loop with qemu_get_cpu()Andreas Färber2013-02-161-11/+4
| | | | | | | | | | | | | | | | | | | | | | Potentially env could be NULL whereas cpu would still be valid and correspond to a previous env. Wrapping this in qemu_get_cpu(), env is no longer needed, so simplify code that existed before 55e5c2850293547203874098f7cec148ffd12dfa. Acked-by: Alexander Graf <agraf@suse.de> Signed-off-by: Andreas Färber <afaerber@suse.de>
| * e500: Replace open-coded loop with qemu_get_cpu()Andreas Färber2013-02-161-8/+3
| | | | | | | | | | | | | | | | | | | | | | | | Since we still need env for ppc-specific fields, obtain it via the new env_ptr fields to avoid "cpu" name conflicts between CPUState and PowerPCCPU for now. This fixes a potential issue with env being NULL at the end of the loop but cpu still being a valid pointer corresponding to a previous env. Acked-by: Alexander Graf <agraf@suse.de> Signed-off-by: Andreas Färber <afaerber@suse.de>
| * cpu: Add CPUArchState pointer to CPUStateAndreas Färber2013-02-1616-0/+31
| | | | | | | | | | | | | | | | | | | | | | | | The target-specific ENV_GET_CPU() macros have allowed us to navigate from CPUArchState to CPUState. The reverse direction was not supported. Avoid introducing CPU_GET_ENV() macros by initializing an untyped pointer that is initialized in derived instance_init functions. The field may not be called "env" due to it being poisoned. Acked-by: Richard Henderson <rth@twiddle.net> Signed-off-by: Andreas Färber <afaerber@suse.de>
| * cputlb: Pass CPUState to cpu_unlink_tb()Andreas Färber2013-02-163-6/+7
| | | | | | | | | | | | CPUArchState is no longer needed. Signed-off-by: Andreas Färber <afaerber@suse.de>
| * cpu: Move current_tb field to CPUStateAndreas Färber2013-02-1610-26/+48
| | | | | | | | | | | | | | | | | | | | Explictly NULL it on CPU reset since it was located before breakpoints. Change vapic_report_tpr_access() argument to CPUState. This also resolves the use of void* for cpu.h independence. Change vAPIC patch_instruction() argument to X86CPU. Signed-off-by: Andreas Färber <afaerber@suse.de>