summary refs log tree commit diff stats
Commit message (Collapse)AuthorAgeFilesLines
...
* | target-sh4: switch to AREG0 free modeBlue Swirl2012-09-155-189/+195
| | | | | | | | | | | | | | | | Add an explicit CPUState parameter instead of relying on AREG0 and switch to AREG0 free mode. Acked-by: Aurelien Jarno <aurelien@aurel32.net> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
* | target-cris: Switch to AREG0 free modeAurelien Jarno2012-09-156-187/+181
| | | | | | | | | | | | | | | | | | Add an explicit CPUCRISState parameter instead of relying on AREG0, and use cpu_ld* in translation and interrupt handling. Remove AREG0 swapping in tlb_fill(). Switch to AREG0 free mode Signed-off-by: Blue Swirl <blauwirbel@gmail.com> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
* | target-cris: Avoid AREG0 for helpersAurelien Jarno2012-09-154-77/+88
| | | | | | | | | | | | | | Add an explicit CPUCRISState parameter instead of relying on AREG0. Signed-off-by: Blue Swirl <blauwirbel@gmail.com> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
* | target-microblaze: switch to AREG0 free modeBlue Swirl2012-09-155-118/+110
| | | | | | | | | | | | | | Add an explicit CPUState parameter instead of relying on AREG0 and switch to AREG0 free mode. Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
* | target-arm: final conversion to AREG0 free modeBlue Swirl2012-09-156-21/+16
| | | | | | | | | | | | | | Convert code load functions and switch to AREG0 free mode. Signed-off-by: Blue Swirl <blauwirbel@gmail.com> Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
* | target-arm: convert remaining helpersBlue Swirl2012-09-153-125/+125
| | | | | | | | | | | | | | | | Convert remaining helpers to AREG0 free mode: add an explicit CPUState parameter instead of relying on AREG0. Signed-off-by: Blue Swirl <blauwirbel@gmail.com> Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
* | target-arm: convert void helpersBlue Swirl2012-09-153-18/+18
| | | | | | | | | | | | | | | | | | Add an explicit CPUState parameter instead of relying on AREG0. For easier review, convert only op helpers which don't return any value. Signed-off-by: Blue Swirl <blauwirbel@gmail.com> Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
* | target-unicore32: switch to AREG0 free modeBlue Swirl2012-09-155-75/+58
| | | | | | | | | | | | | | | | Add an explicit CPUState parameter instead of relying on AREG0 and switch to AREG0 free mode. Tested-by: Guan Xuetao <gxt@mprc.pku.edu.cn> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
* | target-m68k: avoid using cpu_single_envBlue Swirl2012-09-151-130/+140
| | | | | | | | | | | | Pass around CPUState instead of using global cpu_single_env. Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
* | target-m68k: switch to AREG0 free modeBlue Swirl2012-09-155-82/+68
| | | | | | | | | | | | | | Add an explicit CPUState parameter instead of relying on AREG0 and switch to AREG0 free mode. Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
* | target-lm32: switch to AREG0 free modeBlue Swirl2012-09-155-46/+35
| | | | | | | | | | | | | | Add an explicit CPUState parameter instead of relying on AREG0 and switch to AREG0 free mode. Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
* | target-s390x: avoid cpu_single_envBlue Swirl2012-09-151-173/+183
| | | | | | | | | | | | Pass around CPUState instead of using global cpu_single_env. Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
* | configure: properly check if -lrt and -lm is neededNatanael Copa2012-09-151-2/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fixes build against uClibc. uClibc provides 2 versions of clock_gettime(), one with realtime support and one without (this is so you can avoid linking in -lrt unless actually needed). This means that the clock_gettime() don't need -lrt. We still need it for timer_create() so we check for this function in addition. We also need check if -lm is needed for isnan(). Both -lm and -lrt are needed for libs_qga. Signed-off-by: Natanael Copa <ncopa@alpinelinux.org> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
* | tcg: Fix MAX_OPC_PARAM_IARGSStefan Weil2012-09-152-1/+3
|/ | | | | | | | | | | | | | | DEF_HELPER_FLAGS_5 was added some time ago without adjusting MAX_OPC_PARAM_IARGS. Fixing the definition becomes more important as QEMU is using an increasing number of helper functions called with 5 arguments. Add also a comment to avoid future problems when DEF_HELPER_FLAGS_6 will be added. Signed-off-by: Stefan Weil <sw@weilnetz.de> Reviewed-by: Richard Henderson <rth@twiddle.net> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
* Merge branch 'usb.64' of git://git.kraxel.org/qemuAurelien Jarno2012-09-1113-1042/+1376
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * 'usb.64' of git://git.kraxel.org/qemu: (54 commits) xhci: allow bytewise capability register reads xhci: kill xhci_mem_{read,write} dispatcher functions xhci: support multiple interrupters xhci: pick target interrupter xhci: prepare xhci_runtime_{read,write} for multiple interrupters xhci: add XHCIInterrupter xhci: move register update into xhci_intr_raise xhci: add msix support xhci: rework interrupt handling xhci: fix & cleanup msi. usb-storage: usb3 support usb3: bos decriptor usb3: superspeed endpoint companion usb3: superspeed descriptors xhci: update port handling xhci: update register layout xhci: fix runtime write tracepoint xhci: add trace_usb_xhci_ep_set_dequeue xhci: trace cc codes in cleartext xhci: iso xfer support ...
| * xhci: allow bytewise capability register readsGerd Hoffmann2012-09-111-1/+3
| | | | | | | | | | | | | | Some guests need this according to Alejandro Martinez Ruiz <alex@securiforest.com> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * xhci: kill xhci_mem_{read,write} dispatcher functionsGerd Hoffmann2012-09-111-65/+75
| | | | | | | | | | | | | | ... and register subregions instead, so we offload the dispatching to the the memory subsystem which is designed to handle it. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * xhci: support multiple interruptersGerd Hoffmann2012-09-111-5/+1
| | | | | | | | | | | | | | Everything is in place, flip the big switch now and enable support for multiple interrupters. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * xhci: pick target interrupterGerd Hoffmann2012-09-111-6/+16
| | | | | | | | | | | | Pick the correct interrupter when queuing an event. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * xhci: prepare xhci_runtime_{read,write} for multiple interruptersGerd Hoffmann2012-09-111-43/+57
| | | | | | | | | | | | Prepare xhci runtime register access function for multiple interrupters. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * xhci: add XHCIInterrupterGerd Hoffmann2012-09-112-148/+161
| | | | | | | | | | | | | | Move all state belonging to the (single) interrupter into a separate struct. First step in adding support for multiple interrupters. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * xhci: move register update into xhci_intr_raiseGerd Hoffmann2012-09-111-9/+5
| | | | | | | | | | | | | | Now that we have a separate function to raise an IRQ we can move some comon code into the function. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * xhci: add msix supportGerd Hoffmann2012-09-112-1/+49
| | | | | | | | Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * xhci: rework interrupt handlingGerd Hoffmann2012-09-111-14/+33
| | | | | | | | | | | | | | | | Split xhci_irq_update into a function which handles intx updates (including lowering the irq line once the guests acks the interrupt) and one which is used for raising an irq only. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * xhci: fix & cleanup msi.Gerd Hoffmann2012-09-111-18/+9
| | | | | | | | | | | | | | | | | | | | Drop custom write_config function which isn't needed any more. Make the msi property a bit property so it accepts 'on' & 'off'. Enable MSI by default. TODO: add compat property to disable on old machine types. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * usb-storage: usb3 supportGerd Hoffmann2012-09-111-3/+43
| | | | | | | | | | | | | | Add usb3 descriptors to usb-storage, so it shows up as superspeed device when connected to xhci. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * usb3: bos decriptorGerd Hoffmann2012-09-114-0/+141
| | | | | | | | | | | | | | Add support for creating BOS descriptor and device cappability descriptors. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * usb3: superspeed endpoint companionGerd Hoffmann2012-09-113-20/+62
| | | | | | | | | | | | | | Add support for building superspeed endpoint companion descriptors, create them for superspeed usb devices. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * usb3: superspeed descriptorsGerd Hoffmann2012-09-112-1/+10
| | | | | | | | | | | | | | Add superspeed descriptor entry to USBDesc, advertise superspeed support when present. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * xhci: update port handlingGerd Hoffmann2012-09-111-40/+97
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch changes the way xhci ports are linked to USBPorts. The fixed 1:1 relationship between xhci ports and USBPorts is gone. Now each USBPort represents a physical plug which has usually two xhci ports assigned: one usb2 and ond usb3 port. usb devices show up at one or the other, depending on whenever they support superspeed or not. This patch also makes the number of usb2 and usb3 ports runtime configurable by adding 'p2' and 'p3' properties. It is allowed to have different numbers of usb2 and usb3 ports. Specifying p2=4,p3=2 will give you an xhci adapter which supports all speeds on physical ports 1+2 and usb2 only on ports 3+4.
| * xhci: update register layoutGerd Hoffmann2012-09-111-8/+13
| | | | | | | | | | | | Change the register layout to be a bit more sparse and also not depend on the number of ports. Useful when for making the number of ports runtime-configurable.
| * xhci: fix runtime write tracepointGerd Hoffmann2012-09-111-1/+1
| | | | | | | | Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * xhci: add trace_usb_xhci_ep_set_dequeueGerd Hoffmann2012-09-112-1/+2
| | | | | | | | Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * xhci: trace cc codes in cleartextGerd Hoffmann2012-09-112-2/+48
| | | | | | | | Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * xhci: iso xfer supportGerd Hoffmann2012-09-111-16/+101
| | | | | | | | | | | | Add support for iso transfers. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * xhci: implement mfindexGerd Hoffmann2012-09-111-7/+46
| | | | | | | | | | | | Implement mfindex register and mfindex wrap event. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * xhci: move device lookup into xhci_setup_packetGerd Hoffmann2012-09-111-36/+38
| | | | | | | | Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * xhci: drop bufferingGerd Hoffmann2012-09-112-115/+72
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch splits the xhci_xfer_data function into three. The xhci_xfer_data function used to do does two things: (1) copy transfer data between guest memory and a temporary buffer. (2) report transfer results to the guest using events. Now we three functions to handle this: (1) xhci_xfer_map creates a scatter list for the transfer and uses that (instead of the temporary buffer) to build a USBPacket. (2) xhci_xfer_unmap undoes the mapping. (3) xhci_xfer_report sends out events. The patch also fixes reporting of transaction errors which must be reported unconditinally, not only in case the guest asks for it using the ISP flag. [ v2: fix warning ] Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * xhci: rip out background transfer codeGerd Hoffmann2012-09-111-219/+4
| | | | | | | | | | | | | | | | | | | | original xhci code (the one which used libusb directly) used to use 'background transfers' for iso streams. In upstream qemu the iso stream buffering is handled by usb-host & usb-redir, so we will never ever need this. It has been left in as reference, but is dead code anyway. Rip it out. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * usb-audio: fix usb versionGerd Hoffmann2012-09-111-1/+1
| | | | | | | | | | | | | | usb-audio is a full speed (1.1) device, but bcdUSB claims it is usb 2.0. Fix it. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * Better name usb braille deviceSamuel Thibault2012-09-111-1/+1
| | | | | | | | | | | | | | | | Windows users need to know that they have to use the Baum driver to make the qemu braille device work. Signed-off-by: Samuel Thibault <samuel.thibault@ens-lyon.org> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * usb-redir: Enable pipelining for bulk endpointsHans de Goede2012-09-111-0/+3
| | | | | | | | | | Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * usb-redir: Ensure our peer has the necessary caps when redirecting to XHCIHans de Goede2012-09-111-0/+11
| | | | | | | | | | | | | | | | | | | | | | In order for redirection to work properly when redirecting to an emulated XHCI controller, the usb-redir-host must support both usb_redir_cap_ep_info_max_packet_size and usb_redir_cap_64bits_ids, reject any devices redirected to an XHCI controller when these are not supported. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * usb-redir: Add a usbredir_reject_device helper functionHans de Goede2012-09-111-10/+11
| | | | | | | | | | Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * usb-redir: Set ep max_packet_size if availableHans de Goede2012-09-111-0/+5
| | | | | | | | | | | | | | This is needed for usb-redir to work properly with the xhci emulation. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * usb-redir: Convert to new libusbredirparser 0.5 APIHans de Goede2012-09-112-32/+32
| | | | | | | | | | | | | | | | This gives us support for 64 bit ids which is needed for using XHCI with the new hcd generated ids. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * usb-redir: Return babble when getting more bulk data then requestedHans de Goede2012-09-111-3/+3
| | | | | | | | | | | | | | Babble is the appropriate error in this case (rather then signalling a stall). Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * usb-redir: Move to core packet id and queue handlingHans de Goede2012-09-111-134/+92
| | | | | | | | | | Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * usb-redir: Get rid of unused async-struct dev memberHans de Goede2012-09-111-2/+0
| | | | | | | | | | | | | | | | | | This is a preparation patch for completely getting rid of the async-packet struct in usb-redir, instead relying on the (new) per ep queues in the qemu usb core. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
| * usb-redir: Get rid of local shadow copy of packet headersHans de Goede2012-09-111-27/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The shadow copy only serves as an extra check (besides the packet-id) to ensure the packet we get back is a reply to the packet we think it is. This check has never triggered in all the time usb-redir is in use now, and since the verified data in the returned packet-header is not used otherwise, removing the check does not open any possibilities for the usbredirhost to confuse us. This is a preparation patch for completely getting rid of the async-packet struct in usb-redir, instead relying on the (new) per ep queues in the qemu usb core. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>