qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Gerd Hoffmann <kraxel@redhat.com>
To: Dmitri Vorobiev <dmitri.vorobiev@gmail.com>
Cc: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] Problems with USB Mass Storage emulation
Date: Mon, 28 Sep 2009 09:17:24 +0200	[thread overview]
Message-ID: <4AC06304.4050506@redhat.com> (raw)
In-Reply-To: <90edad820909260942w64f183d1wc2ebdc377249c2dd@mail.gmail.com>

[-- Attachment #1: Type: text/plain, Size: 777 bytes --]

On 09/26/09 18:42, Dmitri Vorobiev wrote:
> Hello,
>
> We tried to use an emulated USB Mass Storage device with my QEMU-emulated
> system (Debian GNU/Linux, MIPS architecture, but the same problem is
> present also for a similar x86 version). fdisk(1) works fine. However,
> when formatting is going on or a big file is being copied into the
> USB-MS partition, some errors occur and the system starts working
> extremely slowly.

qemu emulates usb 1.1, which *is* slow.

Attached patch gets usb-storage going for me, but I'd classify it as 
'hack', not as 'fix'.  Fixing it for real would be adding usb 2.0 supprt 
to qemu.  Or fix the linux kernel to deal with usb 1.1 more sanely, 
which is probably just adjusting the scsi timeouts to the device speed ...

cheers,
   Gerd

[-- Attachment #2: 0001-make-usb-1.1-go-insane-fast.patch --]
[-- Type: text/plain, Size: 587 bytes --]

>From 540a948fed07ef3e686097083f078b4803939fb4 Mon Sep 17 00:00:00 2001
From: Gerd Hoffmann <kraxel@redhat.com>
Date: Tue, 8 Sep 2009 13:53:15 +0200
Subject: [PATCH] make usb 1.1 go insane fast

---
 hw/usb-uhci.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/hw/usb-uhci.c b/hw/usb-uhci.c
index 6807413..3a770e5 100644
--- a/hw/usb-uhci.c
+++ b/hw/usb-uhci.c
@@ -63,7 +63,7 @@
 #define UHCI_PORT_CSC   (1 << 1)
 #define UHCI_PORT_CCS   (1 << 0)
 
-#define FRAME_TIMER_FREQ 1000
+#define FRAME_TIMER_FREQ 100000
 
 #define FRAME_MAX_LOOPS  100
 
-- 
1.6.2.5


      reply	other threads:[~2009-09-28  7:17 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1253983134.3374.12.camel@codedot>
2009-09-26 16:42 ` [Qemu-devel] Problems with USB Mass Storage emulation Dmitri Vorobiev
2009-09-28  7:17   ` Gerd Hoffmann [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4AC06304.4050506@redhat.com \
    --to=kraxel@redhat.com \
    --cc=dmitri.vorobiev@gmail.com \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).