qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] usb and qemu
@ 2005-08-09 20:33 Michael Hoeller
  2005-08-09 21:01 ` Jim C. Brown
  2005-08-09 21:17 ` Paul Brook
  0 siblings, 2 replies; 11+ messages in thread
From: Michael Hoeller @ 2005-08-09 20:33 UTC (permalink / raw)
  To: qemu-devel

Hello,

is there a way to access an usb stick from Windows which runs in qemu 
under Linux??

Michael

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [Qemu-devel] usb and qemu
  2005-08-09 20:33 [Qemu-devel] usb and qemu Michael Hoeller
@ 2005-08-09 21:01 ` Jim C. Brown
  2005-08-09 21:17 ` Paul Brook
  1 sibling, 0 replies; 11+ messages in thread
From: Jim C. Brown @ 2005-08-09 21:01 UTC (permalink / raw)
  To: Michael Hoeller, qemu-devel

On Tue, Aug 09, 2005 at 10:33:31PM +0200, Michael Hoeller wrote:
> Hello,
> 
> is there a way to access an usb stick from Windows which runs in qemu 
> under Linux??
> 
> Michael
> 

No.

http://usbip.naist.jp/ and http://sourceforge.net/projects/usbip/ might help
if the guest and the host were both linux 2.6, however afaict usbip does not work
under Windows yet.

-- 
Infinite complexity begets infinite beauty.
Infinite precision begets infinite perfection.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [Qemu-devel] usb and qemu
  2005-08-09 20:33 [Qemu-devel] usb and qemu Michael Hoeller
  2005-08-09 21:01 ` Jim C. Brown
@ 2005-08-09 21:17 ` Paul Brook
  1 sibling, 0 replies; 11+ messages in thread
From: Paul Brook @ 2005-08-09 21:17 UTC (permalink / raw)
  To: qemu-devel, Michael Hoeller

On Tuesday 09 August 2005 21:33, Michael Hoeller wrote:
> Hello,
>
> is there a way to access an usb stick from Windows which runs in qemu
> under Linux??

You can use the usb block device directly as a hard disk "image". ie something 
like
qemu -hdb /dev/sda ...

Obviously the guest will see it as an IDE drive, and hotpluging hasn't got a 
hope of working, but it's probably near enough for most purposes.

Note that you should never mount the same device on both the host and the 
guest at the same time. Doing so will cause data corruption.

Paul

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [Qemu-devel] usb and qemu
  2005-08-10 10:57 Ben Taylor
@ 2005-08-10 11:25 ` vaise
  2005-08-10 13:49 ` Mark Williamson
  1 sibling, 0 replies; 11+ messages in thread
From: vaise @ 2005-08-10 11:25 UTC (permalink / raw)
  To: sol10x86, qemu-devel

On Wednesday 10 August 2005 12:57, Ben Taylor wrote:
> I haven't tried it, but couldn't you either pass the
> physical device (like /dev/sda) as -hdb, or mount up
> the USB memory stick and use samba (either qemu's
> builtin or an existing samba server) to share it to
> the window's guest?
>
I do this way too
Dsant

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [Qemu-devel] usb and qemu
  2005-08-10 10:57 Ben Taylor
  2005-08-10 11:25 ` vaise
@ 2005-08-10 13:49 ` Mark Williamson
  2005-08-10 14:03   ` Paul Brook
  1 sibling, 1 reply; 11+ messages in thread
From: Mark Williamson @ 2005-08-10 13:49 UTC (permalink / raw)
  To: qemu-devel, sol10x86

Isn't there a USB patch floating around somewhere (emulates OHCI in the 
guest)?  Or am I remembering something else?

Cheers,
Mark

On Wednesday 10 August 2005 11:57, Ben Taylor wrote:
> "Jim C. Brown" <jma5@umd.edu>
>
> > On Tue, Aug 09, 2005 at 10:33:31PM +0200, Michael Hoeller wrote:
> > > Hello,
> > >
> > > is there a way to access an usb stick from Windows which runs in qemu
> > > under Linux??
> > >
> > > Michael
> >
> > No.
> >
> > http://usbip.naist.jp/ and http://sourceforge.net/projects/usbip/ might
> > help if the guest and the host were both linux 2.6, however afaict usbip
> > does not work under Windows yet.
>
> I haven't tried it, but couldn't you either pass the
> physical device (like /dev/sda) as -hdb, or mount up
> the USB memory stick and use samba (either qemu's
> builtin or an existing samba server) to share it to
> the window's guest?
>
> Ben
>
>
>
>
> _______________________________________________
> Qemu-devel mailing list
> Qemu-devel@nongnu.org
> http://lists.nongnu.org/mailman/listinfo/qemu-devel

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [Qemu-devel] usb and qemu
  2005-08-10 13:49 ` Mark Williamson
@ 2005-08-10 14:03   ` Paul Brook
  2005-08-10 17:07     ` Jim C. Brown
  2005-08-10 22:10     ` Mark Williamson
  0 siblings, 2 replies; 11+ messages in thread
From: Paul Brook @ 2005-08-10 14:03 UTC (permalink / raw)
  To: qemu-devel

On Wednesday 10 August 2005 14:49, Mark Williamson wrote:
> > > http://usbip.naist.jp/ and http://sourceforge.net/projects/usbip/ might
> > > help if the guest and the host were both linux 2.6, however afaict usbip
> > > does not work under Windows yet.
>...
> Isn't there a USB patch floating around somewhere (emulates OHCI in the 
> guest)?

Yes, but noone's written the code to wire it up to host devices. AFAIK it 
currently emulates the host controller and not much else.

Using the usb-over-ip protocol mentioned above seems like a nice way of 
getting it to talk to host USB devices in a host-independent way.

Paul

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [Qemu-devel] usb and qemu
  2005-08-10 14:03   ` Paul Brook
@ 2005-08-10 17:07     ` Jim C. Brown
  2005-08-10 17:28       ` Paul Brook
  2005-08-10 22:10     ` Mark Williamson
  1 sibling, 1 reply; 11+ messages in thread
From: Jim C. Brown @ 2005-08-10 17:07 UTC (permalink / raw)
  To: qemu-devel

On Wed, Aug 10, 2005 at 03:03:25PM +0100, Paul Brook wrote:
> > Isn't there a USB patch floating around somewhere (emulates OHCI in the 
> > guest)?
> 
> Yes, but noone's written the code to wire it up to host devices. AFAIK it 
> currently emulates the host controller and not much else.
> 
> Using the usb-over-ip protocol mentioned above seems like a nice way of 
> getting it to talk to host USB devices in a host-independent way.

IIRC, one of the authors of the patch wanted to use usbip in qemu, so the guest
could see and use host usb devices (thinking that they were connected to the
virtual machine) without having to be aware of, or have support for, usbip.

-- 
Infinite complexity begets infinite beauty.
Infinite precision begets infinite perfection.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [Qemu-devel] usb and qemu
  2005-08-10 17:07     ` Jim C. Brown
@ 2005-08-10 17:28       ` Paul Brook
  0 siblings, 0 replies; 11+ messages in thread
From: Paul Brook @ 2005-08-10 17:28 UTC (permalink / raw)
  To: qemu-devel

On Wednesday 10 August 2005 18:07, Jim C. Brown wrote:
> On Wed, Aug 10, 2005 at 03:03:25PM +0100, Paul Brook wrote:
> > > Isn't there a USB patch floating around somewhere (emulates OHCI in the
> > > guest)?
> >
> > Yes, but noone's written the code to wire it up to host devices. AFAIK it
> > currently emulates the host controller and not much else.
> >
> > Using the usb-over-ip protocol mentioned above seems like a nice way of
> > getting it to talk to host USB devices in a host-independent way.
>
> IIRC, one of the authors of the patch wanted to use usbip in qemu, so the
> guest could see and use host usb devices (thinking that they were connected
> to the virtual machine) without having to be aware of, or have support for,
> usbip.

Right, that's what I meant.

Paul

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [Qemu-devel] usb and qemu
  2005-08-10 14:03   ` Paul Brook
  2005-08-10 17:07     ` Jim C. Brown
@ 2005-08-10 22:10     ` Mark Williamson
  2005-08-10 23:37       ` Lonnie Mendez
  1 sibling, 1 reply; 11+ messages in thread
From: Mark Williamson @ 2005-08-10 22:10 UTC (permalink / raw)
  To: qemu-devel; +Cc: Paul Brook

> > Isn't there a USB patch floating around somewhere (emulates OHCI in the
> > guest)?
>
> Yes, but noone's written the code to wire it up to host devices. AFAIK it
> currently emulates the host controller and not much else.

Oh, OK that makes sense.

> Using the usb-over-ip protocol mentioned above seems like a nice way of
> getting it to talk to host USB devices in a host-independent way.

Actually that'd be a fairly neat trick...  As an alternative, IIRC there's a 
user space API for writing USB drivers under Linux - using that you could get 
access to both local and remote (IP encapsulated) USB devices, albeit not in 
a cross-platform (host-wise) way.

Cheers,
Mark

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [Qemu-devel] usb and qemu
  2005-08-10 22:10     ` Mark Williamson
@ 2005-08-10 23:37       ` Lonnie Mendez
  2005-08-11 14:47         ` Mark Williamson
  0 siblings, 1 reply; 11+ messages in thread
From: Lonnie Mendez @ 2005-08-10 23:37 UTC (permalink / raw)
  To: qemu-devel

On Wednesday 10 August 2005 5:10 pm, Mark Williamson wrote:
> > > Isn't there a USB patch floating around somewhere (emulates OHCI in the
> > > guest)?
> >
> > Yes, but noone's written the code to wire it up to host devices. AFAIK it
> > currently emulates the host controller and not much else.
> 
> Oh, OK that makes sense.
> 
> > Using the usb-over-ip protocol mentioned above seems like a nice way of
> > getting it to talk to host USB devices in a host-independent way.
> 
> Actually that'd be a fairly neat trick...  As an alternative, IIRC there's a 
> user space API for writing USB drivers under Linux - using that you could 
get 
> access to both local and remote (IP encapsulated) USB devices, albeit not in 
> a cross-platform (host-wise) way.

   That would be called libusb.  The libusb V1_0_DEVEL branch would be the 
prime candidate for this "wiring up", but is however incomplete.  libusb 
(<=0.1.10a) does not support asynchronous communications and does not have an 
api to deal with isochronous usb transfers as well.  I've been messing around 
with the ohci-hc / libusb 1.0 connection, albeit slowly.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [Qemu-devel] usb and qemu
  2005-08-10 23:37       ` Lonnie Mendez
@ 2005-08-11 14:47         ` Mark Williamson
  0 siblings, 0 replies; 11+ messages in thread
From: Mark Williamson @ 2005-08-11 14:47 UTC (permalink / raw)
  To: qemu-devel

> > Actually that'd be a fairly neat trick...  As an alternative, IIRC
> > there's a user space API for writing USB drivers under Linux - using that
> > you could
>
> get
>
> > access to both local and remote (IP encapsulated) USB devices, albeit not
> > in a cross-platform (host-wise) way.
>
>    That would be called libusb.  The libusb V1_0_DEVEL branch would be the
> prime candidate for this "wiring up", but is however incomplete.  libusb
> (<=0.1.10a) does not support asynchronous communications and does not have
> an api to deal with isochronous usb transfers as well.  I've been messing
> around with the ohci-hc / libusb 1.0 connection, albeit slowly.

Ah, OK.  I guess you can still get a good subset of functionality without iso 
transfers (e.g. supporting pendrives, network drives, etc.).  Do you find 
libusb to be good to work with?  I've done some similar stuff in the past but 
at the kernel level, rather than in user space.

Cheers,
Mark

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2005-08-11 14:52 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-08-09 20:33 [Qemu-devel] usb and qemu Michael Hoeller
2005-08-09 21:01 ` Jim C. Brown
2005-08-09 21:17 ` Paul Brook
  -- strict thread matches above, loose matches on Subject: below --
2005-08-10 10:57 Ben Taylor
2005-08-10 11:25 ` vaise
2005-08-10 13:49 ` Mark Williamson
2005-08-10 14:03   ` Paul Brook
2005-08-10 17:07     ` Jim C. Brown
2005-08-10 17:28       ` Paul Brook
2005-08-10 22:10     ` Mark Williamson
2005-08-10 23:37       ` Lonnie Mendez
2005-08-11 14:47         ` Mark Williamson

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).