adding Irix (and, to a lesser extent, Solaris) userland emulation to QEMU
Go to file
Hans de Goede 060dc841d1 usb-linux: Add support for buffering iso usb packets
Currently we are submitting iso packets to the host one at a time, as we
receive them from the emulated host controller. This has 2 problems:
1) If we were fast enough to submit every packet in time for the next host host
controller usb frame, we would be generating 1000 hardware interrupts per
second on the host
2) We are not fast enough to submit every packet in time for the next host host
controller usb frame, causing us to not submit iso urbs in some usb frames
which causes devices with an endpoint with an interval of 1 ms (so every
frame) to loose data. This causes for example ubs-1.1 webcams to not work
properly (usb-2.0 is not supported at all atm).

This patch fixes both problems by changing the iso packet pass through handling
to buffer packets. This version only does so for iso input packets (webcams,
audio in) I'm working on a second patch extending this to iso output packets
(audio out).

This patch makes use of the linux batching of iso packets in one urb.
When an iso in packet gets received from the emulated host controller,
it immediately submits 3 urbs with 32 iso in packets each. This causes
the host to only get an hw interrupt every 32 packets dropping the
interrupt rate to 32 interrupts per second and gives it a queue of urbs
to work from once the first 32 iso in packets have been received to make sure
no packets are dropped.

Besides submitting a whole bunch or urbs as soon as the first urb is
received, effectively creating a buffer inside the kernel, this patch also
gets rid of the asynchroneous completion for iso in urbs. Instead they are
only marked as complete in the fd write callback (which usbfs uses to signal
complete urbs). These complete packets then get consumed by returning them
synchroneously to the emulated host controller when it submits an iso in
packet for the ep in question. When no complete packets are ready (which
happens when the stream is starting) a 0 length packet gets returned to
the emulated host controller.

With this patch I've several usb-1.1 webcams working well with usb pass
through, where as without this patch none of them work.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2011-05-04 12:25:24 +02:00
QMP spice: connection events. 2010-12-09 14:23:24 +01:00
audio Fix trivial "endianness bugs" 2011-04-03 21:42:57 +02:00
block NBD: Avoid leaking a couple of strings when the NBD device is closed 2011-05-03 11:29:21 +02:00
bsd-user bsd-user: Fix possible memory leaks and wrong realloc call 2011-01-17 20:23:47 +00:00
darwin-user darwin-user: Remove unneeded null pointer check 2011-04-27 16:28:09 +02:00
default-configs unicore32: necessary modifications for other files to support unicore32 2011-04-12 18:49:05 +00:00
docs docs/tracing.txt: minor documentation fixes 2011-04-26 13:14:49 +01:00
fpu softfloat-native: add float*_is_any_nan() functions 2011-04-25 11:18:33 +02:00
fsdev virtio-9p: move 9p files around 2011-04-27 08:24:37 -07:00
gdb-xml
hw ide/atapi: fix set but unused 2011-05-03 11:29:21 +02:00
libcacard libcacard: fix opposite usage of isspace 2011-04-17 20:40:31 +02:00
linux-user Don't zero out buffer in sched_getaffinity 2011-05-02 10:00:01 +03:00
net Use qemu-common.h or qemu-timer.h in place of sysemu.h 2011-04-15 18:25:44 +00:00
pc-bios PXE: Refresh all PXE ROMs from the ipxe submodule 2011-04-18 11:46:41 -06:00
roms Revert SeaBIOS change due to overzealous commit -a 2011-04-13 08:16:53 -05:00
scripts trace: [ust] fix generation of 'trace.c' on events without args 2011-04-26 13:14:49 +01:00
slirp add a service to reap zombies, use it in SLIRP 2011-03-29 08:14:11 -05:00
sysconfigs/target
target-alpha Remove unused function parameter from cpu_restore_state 2011-04-20 10:37:03 +02:00
target-arm target-arm: Don't update base register on abort in Thumb T1 LDM 2011-04-27 20:14:34 +02:00
target-cris Remove unused function parameter from cpu_restore_state 2011-04-20 10:37:03 +02:00
target-i386 kvm: use qemu_free consistently 2011-05-02 09:51:59 -03:00
target-lm32 lm32: fix exception handling 2011-05-03 10:48:40 +02:00
target-m68k Remove unused function parameter from cpu_restore_state 2011-04-20 10:37:03 +02:00
target-microblaze Remove unused function parameter from cpu_restore_state 2011-04-20 10:37:03 +02:00
target-mips Remove unused function parameter from cpu_restore_state 2011-04-20 10:37:03 +02:00
target-ppc Remove unused function parameter from cpu_restore_state 2011-04-20 10:37:03 +02:00
target-s390x Remove unused function parameter from cpu_restore_state 2011-04-20 10:37:03 +02:00
target-sh4 Remove unused function parameter from cpu_restore_state 2011-04-20 10:37:03 +02:00
target-sparc Remove unused function parameter from cpu_restore_state 2011-04-20 10:37:03 +02:00
target-unicore32 Remove unused function parameters from gen_pc_load and rename the function 2011-04-20 10:33:59 +02:00
tcg tcg/arm: Support host code being compiled for Thumb 2011-03-24 03:27:22 +01:00
tests tests/test-mmap.c: Check mmap() return value before using it 2011-04-14 17:31:47 +02:00
ui vnc: tight: Fix crash after 2GB of output 2011-04-10 00:14:51 +02:00
.gitignore Makefile: Clean up after "make pdf" 2011-04-16 12:24:28 +01:00
.gitmodules Add ipxe submodule 2011-04-08 13:03:34 -06:00
CODING_STYLE checkpatch: adjust to QEMUisms 2011-01-20 20:58:56 +00:00
COPYING
COPYING.LIB
Changelog
HACKING HACKING: Update status of format checking 2011-02-25 16:31:05 -06:00
LICENSE
MAINTAINERS MAINTAINERS: add Milkymist board 2011-04-04 10:26:54 +02:00
Makefile Merge remote-tracking branch 'awilliam/ipxe' into staging 2011-04-25 10:26:10 -05:00
Makefile.dis
Makefile.hw
Makefile.objs virtfs: fix build due from rename 2011-04-28 12:40:54 -05:00
Makefile.target lm32: add Milkymist Minimac2 support 2011-05-03 10:48:40 +02:00
Makefile.user
README
TODO
VERSION Open up the 0.15 development branch 2011-02-02 08:39:28 +01:00
a.out.h
acl.c Remove unused sysemu.h include directives 2011-04-15 18:25:41 +00:00
acl.h
aes.c
aes.h
aio.c
alpha-dis.c *-dis: Replace fprintf_ftype by fprintf_function (format checking) 2010-12-04 20:50:30 +00:00
alpha.ld
arch_init.c LatticeMico32 target support 2011-03-07 13:42:36 +01:00
arch_init.h migration: move some declarations to migration.h 2011-04-15 20:14:54 +00:00
arm-dis.c arm-dis: Include opcode hex when doing disassembly 2011-01-12 15:10:47 +01:00
arm-semi.c Remove unused sysemu.h include directives 2011-04-15 18:25:41 +00:00
arm.ld
async.c
balloon.c Remove unused sysemu.h include directives 2011-04-15 18:25:41 +00:00
balloon.h
bitmap.c bitmap: add a generic bitmap and bitops library 2011-02-23 16:28:29 -06:00
bitmap.h bitmap: add a generic bitmap and bitops library 2011-02-23 16:28:29 -06:00
bitops.c bitmap: add a generic bitmap and bitops library 2011-02-23 16:28:29 -06:00
bitops.h bitops: fix error on OpenBSD and mingw32 2011-02-25 17:21:22 +00:00
block-migration.c Improve accuracy of block migration bandwidth calculation 2011-04-27 14:36:57 +02:00
block-migration.h
block.c block: Do not cache device size for removable media 2011-04-07 13:51:47 +02:00
block.h Do not delete BlockDriverState when deleting the drive 2011-04-07 13:51:47 +02:00
block_int.h Add flag to indicate external users to block device 2011-02-07 12:51:19 +01:00
blockdev.c Do not delete BlockDriverState when deleting the drive 2011-04-07 13:51:47 +02:00
blockdev.h blockdev: add refcount to DriveInfo 2011-02-07 12:51:19 +01:00
bswap.h bswap.h: add cpu_to_be64wu() 2011-01-10 10:55:10 +01:00
bt-host.c Remove unused sysemu.h include directives 2011-04-15 18:25:41 +00:00
bt-host.h
bt-vhci.c Remove unused sysemu.h include directives 2011-04-15 18:25:41 +00:00
buffered_file.c Remove unused sysemu.h include directives 2011-04-15 18:25:41 +00:00
buffered_file.h
cache-utils.c Remove trailing whitespace 2010-11-01 00:54:06 +03:00
cache-utils.h Delete useless 'extern' qualifiers for functions 2011-01-23 16:21:20 +00:00
check-qdict.c check-qdict: Fix possible crash 2011-02-20 18:45:09 +01:00
check-qfloat.c
check-qint.c
check-qjson.c Silence compiler warning in json test case 2010-10-22 10:08:37 -02:00
check-qlist.c
check-qstring.c
cmd.c qemu-io: check registered fds in command_loop() 2010-06-22 14:38:02 +02:00
cmd.h Delete useless 'extern' qualifiers for functions 2011-01-23 16:21:20 +00:00
compatfd.c Use sigwait instead of sigwaitinfo. 2011-02-25 20:16:26 +00:00
compatfd.h signalfd compatibility 2010-10-20 16:15:04 -05:00
config.h
configure virtio-9p: move 9p files around 2011-04-27 08:24:37 -07:00
console.c Consolidate DisplaySurface allocation in qemu_alloc_display() 2011-03-22 08:39:11 -05:00
console.h Make VNC support optional 2011-03-22 08:39:12 -05:00
cpu-all.h Redirect cpu_interrupt to callback handler 2011-05-02 09:38:35 -03:00
cpu-common.h cpu-common: Modify cpu_physical_memory_read and cpu_physical_memory_write 2011-04-12 21:51:50 +02:00
cpu-defs.h Expose thread_id in info cpus 2011-03-16 17:11:07 -03:00
cpu-exec.c Remove unused function parameter from cpu_restore_state 2011-04-20 10:37:03 +02:00
cpus.c qemu_next_deadline should not consider host-time timers 2011-04-15 09:27:56 +02:00
cpus.h Move CPU related functions to cpus.h 2011-04-15 20:14:52 +00:00
cris-dis.c cris: Support disassembly of crisv10 2011-01-10 22:31:09 +01:00
cursor.c
cursor_hidden.xpm
cursor_left_ptr.xpm
cutils.c QCOW2: bug fix - read base image beyond its size 2011-02-10 13:23:44 +01:00
def-helper.h tcg: Optionally sign-extend 32-bit arguments for 64-bit hosts. 2010-06-16 11:29:11 +02:00
device_tree.c Remove unused sysemu.h include directives 2011-04-15 18:25:41 +00:00
device_tree.h Allow qemu_devtree_setprop() to take arbitrary values 2011-04-01 18:34:54 +02:00
dis-asm.h Delete useless 'extern' qualifiers for functions 2011-01-23 16:21:20 +00:00
disas.c Replace cpu_physical_memory_rw were possible 2011-04-12 21:51:50 +02:00
disas.h Remove special handling of system include files (no longer needed) 2010-10-22 17:11:28 +00:00
dma-helpers.c
dma.h
dyngen-exec.h Remove special handling of system include files (no longer needed) 2010-10-22 17:11:28 +00:00
elf.h unicore32: necessary modifications for other files to support unicore32 2011-04-12 18:49:05 +00:00
envlist.c
envlist.h Delete useless 'extern' qualifiers for functions 2011-01-23 16:21:20 +00:00
exec-all.h Remove unused function parameter from cpu_restore_state 2011-04-20 10:37:03 +02:00
exec.c Redirect cpu_interrupt to callback handler 2011-05-02 09:38:35 -03:00
gdbstub.c gdbstub: Catch and report more vmstop reasons 2011-04-03 23:57:39 +02:00
gdbstub.h Add scripts directory 2011-01-20 20:54:21 +00:00
gen-icount.h Fix conversions from pointer to tcg_target_long 2011-04-10 00:45:16 +02:00
hmp-commands.hx hmp-commands.hx: fix badly merged client_migrate_info command 2011-03-10 16:12:21 -06:00
host-utils.c
host-utils.h
hpet.h
hppa-dis.c
hppa.ld
i386-dis.c
i386.ld
ia64-dis.c
ia64.ld
input.c event: trivial coding style fixes 2011-04-09 10:56:17 +01:00
iohandler.c add a service to reap zombies, use it in SLIRP 2011-03-29 08:14:11 -05:00
ioport-user.c
ioport.c ioport: Improve error output 2011-03-06 21:01:32 +01:00
ioport.h Type-safe ioport callbacks 2010-11-21 09:16:57 -06:00
iorange.h Type-safe ioport callbacks 2010-11-21 09:16:57 -06:00
iov.c
iov.h
json-lexer.c json-lexer: fix conflict with mingw32 ERROR definition 2011-04-15 18:25:38 +00:00
json-lexer.h
json-parser.c Use GCC_FMT_ATTR (format checking) 2010-10-03 06:34:51 +00:00
json-parser.h
json-streamer.c json-streamer: Don't use qdict_put_obj() 2010-06-11 15:25:14 -03:00
json-streamer.h
kvm-all.c kvm: use qemu_free consistently 2011-05-02 09:51:59 -03:00
kvm-stub.c Remove unused sysemu.h include directives 2011-04-15 18:25:41 +00:00
kvm.h kvm: x86: Push kvm_arch_debug to kvm_arch_handle_exit 2011-03-16 17:11:06 -03:00
libfdt_env.h
linux-aio.c
m68k-dis.c *-dis: Replace fprintf_ftype by fprintf_function (format checking) 2010-12-04 20:50:30 +00:00
m68k-semi.c Move qemu_gettimeofday() to OS specific files 2010-10-30 08:02:38 +00:00
m68k.ld
microblaze-dis.c *-dis: Replace fprintf_ftype by fprintf_function (format checking) 2010-12-04 20:50:30 +00:00
migration-exec.c Remove unused sysemu.h include directives 2011-04-15 18:25:41 +00:00
migration-fd.c Remove unused sysemu.h include directives 2011-04-15 18:25:41 +00:00
migration-tcp.c Remove unused sysemu.h include directives 2011-04-15 18:25:41 +00:00
migration-unix.c Remove unused sysemu.h include directives 2011-04-15 18:25:41 +00:00
migration.c Improve vm_stop reason declarations 2011-02-14 12:39:46 -02:00
migration.h migration: move some declarations to migration.h 2011-04-15 20:14:54 +00:00
mips-dis.c *-dis: Replace fprintf_ftype by fprintf_function (format checking) 2010-12-04 20:50:30 +00:00
mips.ld
module.c
module.h
monitor.c Replace cpu_physical_memory_rw were possible 2011-04-12 21:51:50 +02:00
monitor.h spice: connection events. 2010-12-09 14:23:24 +01:00
nbd.c NBD: Use qemu_socket functions to open TCP and UNIX sockets 2011-04-07 13:51:48 +02:00
nbd.h NBD: Use qemu_socket functions to open TCP and UNIX sockets 2011-04-07 13:51:48 +02:00
net.c Remove unused sysemu.h include directives 2011-04-15 18:25:41 +00:00
net.h Add bootindex parameter to net/block/fd device 2010-12-11 21:32:46 +00:00
notify.c
notify.h
os-posix.c add a service to reap zombies, use it in SLIRP 2011-03-29 08:14:11 -05:00
os-win32.c Expose thread_id in info cpus 2011-03-16 17:11:07 -03:00
osdep.c Remove unused sysemu.h include directives 2011-04-15 18:25:41 +00:00
osdep.h Merge remote branch 'qemu-kvm/uq/master' into staging 2011-03-21 17:42:20 -05:00
oslib-posix.c virtio-9p: fix build on !CONFIG_UTIMENSAT 2010-12-02 16:08:40 -08:00
oslib-win32.c w32: Remove implementation of function ffs 2011-02-20 20:18:21 +00:00
path.c user: speed up init_paths a bit 2011-02-09 10:33:54 +02:00
pci-ids.txt
pflib.c add pflib: PixelFormat conversion library. 2010-09-21 18:35:30 +02:00
pflib.h add pflib: PixelFormat conversion library. 2010-09-21 18:35:30 +02:00
poison.h LatticeMico32 target support 2011-03-07 13:42:36 +01:00
posix-aio-compat.c trace: Trace posix-aio-compat.c completion and cancellation 2011-03-07 15:34:46 +00:00
ppc-dis.c
ppc.ld
ppc64.ld
qbool.c
qbool.h
qdict-test-data.txt
qdict.c QDict: Introduce qdict_get_try_bool() 2010-07-01 14:27:13 -03:00
qdict.h QDict: Introduce qdict_get_try_bool() 2010-07-01 14:27:13 -03:00
qemu-aio.h
qemu-barrier.h Introduce proper compiler barrier 2010-07-22 05:52:08 +02:00
qemu-char.c char: Detect chardev release by NULL handlers as well as NULL opaque 2011-04-28 11:11:04 +05:30
qemu-char.h char: Allow devices to use a single multiplexed chardev. 2011-04-28 11:03:07 +05:30
qemu-common.h Move generic or OS function declarations to qemu-common.h 2011-04-15 18:25:46 +00:00
qemu-config.c Remove unused sysemu.h include directives 2011-04-15 18:25:41 +00:00
qemu-config.h spice: core bits 2010-09-21 18:36:42 +02:00
qemu-doc.texi Documentation: add Sheepdog disk images 2011-02-07 09:44:45 +01:00
qemu-error.c Remove unused sysemu.h include directives 2011-04-15 18:25:41 +00:00
qemu-error.h Use GCC_FMT_ATTR (format checking) 2010-10-03 06:34:51 +00:00
qemu-img-cmds.hx qemu-img: Initial progress printing support 2011-04-07 13:51:47 +02:00
qemu-img.c qemu-img resize: Fix option parsing 2011-05-03 11:29:21 +02:00
qemu-img.texi Documentation: Add qemu-img check/rebase 2011-01-24 16:41:49 +01:00
qemu-io.c qemu-io: Fix discard command 2011-01-31 10:03:00 +01:00
qemu-lock.h qemu-lock.h: Remove non-pthreads spinlock implementations 2011-02-20 15:20:06 +01:00
qemu-log.h
qemu-malloc.c Add missing tracing to qemu_mallocz() 2010-12-14 15:44:21 +01:00
qemu-nbd.c Remove NULL checks for bdrv_new return value 2010-12-17 16:11:03 +01:00
qemu-nbd.texi
qemu-objects.h
qemu-option.c qemu-option: Fix parse_option_parameters() documentation typo 2010-12-14 15:44:21 +01:00
qemu-option.h error: New qemu_opts_loc_restore() 2010-07-06 17:05:49 +02:00
qemu-options.h Introduce OS specific cmdline argument handling and move SMB arg to os-posix.c 2010-06-12 08:49:15 +03:00
qemu-options.hx doc: fix slirp description 2011-04-25 23:10:04 +02:00
qemu-os-posix.h virtio-9p: fix build on !CONFIG_UTIMENSAT 2010-12-02 16:08:40 -08:00
qemu-os-win32.h Move generic or OS function declarations to qemu-common.h 2011-04-15 18:25:46 +00:00
qemu-progress.c qemu-progress.c: printf isn't signal safe 2011-05-03 11:29:21 +02:00
qemu-queue.h
qemu-sockets.c Set errno=ENOTSUP for attempts to use UNIX sockets on Windows platforms 2011-04-07 13:51:48 +02:00
qemu-tech.texi qemu-tech: Spelling fixes 2011-01-09 20:59:53 +00:00
qemu-thread-posix.c qemu-thread: delete unused functions 2011-03-19 08:30:28 +00:00
qemu-thread-posix.h add Win32 IPI service 2011-03-13 14:44:22 +00:00
qemu-thread-win32.c w32: Add missing functions qemu_mutex_destroy, qemu_cond_destroy 2011-03-19 08:29:35 +00:00
qemu-thread-win32.h add win32 qemu-thread implementation 2011-03-13 14:44:21 +00:00
qemu-thread.h qemu-thread.h: include inttypes.h 2011-04-01 19:07:48 -05:00
qemu-timer-common.c Add OpenBSD to ifdef list since it has CLOCK_MONOTONIC. 2010-12-21 19:44:42 +00:00
qemu-timer.c qemu-timer: Fix timers for w32 2011-04-27 13:30:18 +02:00
qemu-timer.h qemu-timer: Remove unneeded include statement (w32) 2011-04-27 13:30:18 +02:00
qemu-tool.c Remove unused sysemu.h include directives 2011-04-15 18:25:41 +00:00
qemu-x509.h
qemu.sasl
qemu_socket.h net: remove parse_host_src_port() function 2011-03-06 20:06:50 +01:00
qerror.c qerror: Add QERR_UNKNOWN_BLOCK_FORMAT_FEATURE 2011-02-10 13:23:44 +01:00
qerror.h Make VNC support optional 2011-03-22 08:39:12 -05:00
qfloat.c
qfloat.h
qint.c
qint.h
qjson.c Add support for JSON pretty printing 2010-10-01 10:12:43 -03:00
qjson.h Merge remote branch 'qmp/for-anthony' into staging 2010-10-05 13:54:49 -05:00
qlist.c
qlist.h
qmp-commands.hx qmp-commands.hx: Clean up mess of client_migrate_info 2011-03-22 08:39:12 -05:00
qobject.h
qstring.c
qstring.h
range.h Introduce range.h 2010-09-18 05:53:14 +00:00
readline.c
readline.h
rules.mak Add scripts directory 2011-01-20 20:54:21 +00:00
rwhandler.c Make simple io mem handler endian aware 2010-12-11 15:24:25 +00:00
rwhandler.h Make simple io mem handler endian aware 2010-12-11 15:24:25 +00:00
s390-dis.c s390: Disassemble some general-instruction-extension insns. 2010-06-10 00:46:41 +02:00
s390.ld
savevm.c Fix some typos in comments and documentation 2011-04-16 12:24:28 +01:00
sh4-dis.c *-dis: Replace fprintf_ftype by fprintf_function (format checking) 2010-12-04 20:50:30 +00:00
simpletrace.c simpletrace: Move st_init() error reporting 2011-03-15 18:03:26 +00:00
simpletrace.h simpletrace: Move st_init() error reporting 2011-03-15 18:03:26 +00:00
softmmu-semi.h
softmmu_defs.h
softmmu_exec.h
softmmu_header.h
softmmu_template.h
sparc-dis.c
sparc.ld
sparc64.ld
spice-qemu-char.c spice-chardev: listen to frontend guest open / close 2011-04-28 11:02:31 +05:30
sysemu.h migration: move some declarations to migration.h 2011-04-15 20:14:54 +00:00
targphys.h
tcg-runtime.c
thunk.c
thunk.h
trace-events lm32: add Milkymist Minimac2 support 2011-05-03 10:48:40 +02:00
translate-all.c Remove unused function parameter from cpu_restore_state 2011-04-20 10:37:03 +02:00
uboot_image.h
usb-bsd.c Fix trivial "endianness bugs" 2011-04-03 21:42:57 +02:00
usb-linux.c usb-linux: Add support for buffering iso usb packets 2011-05-04 12:25:24 +02:00
usb-stub.c
version.rc mingw: add version information to the executables 2010-09-26 16:07:57 +00:00
vgafont.h
vl.c vl.c: Replace -virtfs string manipulation with QemuOpts 2011-04-27 08:31:29 -07:00
x86_64.ld

README

Read the documentation in qemu-doc.html.

Fabrice Bellard.