DaemonForums  

Go Back   DaemonForums > OpenBSD > OpenBSD Packages and Ports

OpenBSD Packages and Ports Installation and upgrading of packages and ports on OpenBSD.

Reply
 
Thread Tools Display Modes
  #1   (View Single Post)  
Old 26th August 2011
kolaloka kolaloka is offline
New User
 
Join Date: Nov 2008
Posts: 8
Thanked 0 Times in 0 Posts
Default OpenBSD qemu usb passthrough

I am stuck with one problem. Since 2008 the -usb support has been enabled in qemu, so I thought, I might access my non-bsd compatible scanner through a linux instance from qemu.

I tried:
-usb -usbdevice host:04a9:1734
(that is the correct vendor hostnumber - verified on 2 other systems)
but I get back this:
Warning: could not add USB device host:04a9:1734

after a lot of googling I read that qemu needs procfs to read where what is.
So I added:
/proc /proc procfs rw,linux 0 0
into fstab.

Now, procfs on my beloved OpenBSD does not generate usb devices list similar to the one linux or freebsd does, and I am afraid here is the problem.

Can anybody competent confirm my thought and help me find any workaround, even the dirtiest solution, like copying the whole procfs from another machine and handpicking there is welcome....

Thank everybody in advance!
kolaloka
Reply With Quote
  #2   (View Single Post)  
Old 26th August 2011
BSDfan666 BSDfan666 is offline
Real Name: N/A, this is the interweb.
Helpful companion
 
Join Date: Apr 2008
Location: Ontario, Canada
Posts: 2,223
Thanked 193 Times in 184 Posts
Default

I don't believe OpenBSD's port of QEMU has support for USB pass-through at this time, and if it did it wouldn't be over a /proc interface as that is a deprecated/unmaintained feature on OpenBSD.

mount_procfs(8) is a memory based filesystem that represents kernel structures and devices, copying it from a Linux system would obviously not work as they don't exist or match up with OpenBSD.
Reply With Quote
  #3   (View Single Post)  
Old 27th August 2011
kolaloka kolaloka is offline
New User
 
Join Date: Nov 2008
Posts: 8
Thanked 0 Times in 0 Posts
Default

Thanks, for your reply, BSDfan666,
what do you think then the "USB support added" means in the log of qemu openbsd package history?
Reply With Quote
  #4   (View Single Post)  
Old 27th August 2011
BSDfan666 BSDfan666 is offline
Real Name: N/A, this is the interweb.
Helpful companion
 
Join Date: Apr 2008
Location: Ontario, Canada
Posts: 2,223
Thanked 193 Times in 184 Posts
Default

It seems at one point it was supported, I'm seeing references on the QEMU mailing lists for patches as late as August 4th for fixing USB host on BSD.

Sorry, I wasn't aware there was a backend on BSD, it was silently disabled by one of the QEMU developers upstream in 2009.

http://lists.gnu.org/archive/html/qe.../msg00692.html

You should bring this up on the OpenBSD ports@ mailing list, or mail the port maintainer and see if he will add this for you.
Reply With Quote
  #5   (View Single Post)  
Old 6th September 2011
kolaloka kolaloka is offline
New User
 
Join Date: Nov 2008
Posts: 8
Thanked 0 Times in 0 Posts
Default

Thank you very much for what you've found, I will definitely try to bring this up on the developers' table again!
kolaloka
Reply With Quote
  #6   (View Single Post)  
Old 7th September 2011
BSDfan666 BSDfan666 is offline
Real Name: N/A, this is the interweb.
Helpful companion
 
Join Date: Apr 2008
Location: Ontario, Canada
Posts: 2,223
Thanked 193 Times in 184 Posts
Default

The changes have been committed in QEMU's upstream git repo, so the functionality will presumably be restored when they next make a release and OpenBSD updates to it.

You can make a unified diff of the changes and send an email to the ports@ mailing list or to the maintainer so that the fix can be backported if it's important enough to you.
Reply With Quote
  #7   (View Single Post)  
Old 7th September 2011
BSDfan666 BSDfan666 is offline
Real Name: N/A, this is the interweb.
Helpful companion
 
Join Date: Apr 2008
Location: Ontario, Canada
Posts: 2,223
Thanked 193 Times in 184 Posts
Default

Looking back at your initial question, OpenBSD doesn't really support scanners, but other software in ports capable of using libusb and has userland support, sane is a popular Unix library and collection of utilities used by many "desktop" applications for scanning in documents.

Using QEMU is entirely unnecessary.
Reply With Quote
  #8   (View Single Post)  
Old 10th September 2011
wimwauters wimwauters is offline
Port Guard
 
Join Date: Aug 2008
Posts: 36
Thanked 1 Time in 1 Post
Default

If you check the online hardware support pages (it's under each platform),
then figure out the names of the scanner drivers, you can then look for the driver man pages on the online man pages.

From there you will get a list of scanners, and buy one on eBAY for about $20 or £10. Job done.

I actually ended up with 2 working great under 4.9 (4.8 seems to be broken in this area ?), so I had to sell one.
Reply With Quote
  #9   (View Single Post)  
Old 8th October 2011
kolaloka kolaloka is offline
New User
 
Join Date: Nov 2008
Posts: 8
Thanked 0 Times in 0 Posts
Default solution

Yes, no chance of -usbdevice host:something:something in qemu under OBSD.

HP PSC with hplip works for scanning directly, I tried that. I will sell my canon pixma mp190 or just throw it out of the window, both the scanners are worth some CZK 1000,- which is approx USD 60.
Reply With Quote
Old 9th October 2011
BSDfan666 BSDfan666 is offline
Real Name: N/A, this is the interweb.
Helpful companion
 
Join Date: Apr 2008
Location: Ontario, Canada
Posts: 2,223
Thanked 193 Times in 184 Posts
Default

No chance? I believe I indicated that USB host support on BSD was disabled and enabled again upstream, does it work? I don't know, but, it might.

Indeed though, there are easier solutions to this problem.
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
OpenBSD on qemu: opera install problems Mr-Biscuit OpenBSD Packages and Ports 6 7th September 2009 03:29 AM
qemu sound Oko OpenBSD Packages and Ports 2 7th May 2009 06:59 AM
Jailed QEMU + other OS revzalot FreeBSD Installation and Upgrading 3 29th May 2008 06:00 PM
ssh to FreeBSD run in Qemu mfaridi FreeBSD Security 11 19th May 2008 01:00 PM


All times are GMT. The time now is 05:59 PM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content copyright © 2007-2010, the authors
Daemon image copyright ©1988, Marshall Kirk McKusick