From: "Jan Beulich" Subject: Re: out of dma-memory when using usblp-module in driverdomain Date: Mon, 26 Mar 2007 08:23:22 +0100 Message-ID: <4607910A.76E4.0078.0@novell.com> References: <46068738.1000802@web.de> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <46068738.1000802@web.de> Content-Disposition: inline List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Patrick Scharrenberg Cc: xen-devel List-Id: xen-devel@lists.xenproject.org >>> Patrick Scharrenberg 25.03.07 16:29 >>> >I tried attaching an usb-printer to an usb-port of a driver-domain. >On loading the module usblp I get the following error: > > /usr/src/xen/xen-unstable.hg/linux-2.6.18-xen/drivers/usb/class/usblp.c: > out of memory for write buf > usblp: probe of 2-1:1.0 failed with error -5 > >I figured out, that reducing USBLP_BUF_SIZE (usb/class/usblp.c) form >8192 to some smaller value, e.g. 4096 it works fine, but that's just a >workaround. > >USBLP_BUF_SIZE is used to "usb_buffer_alloc" (usb/core/usb.c) dma memory: > >>From usb.c: > usb_buffer_alloc - allocate dma-consistent buffer for >URB_NO_xxx_DMA_MAP > >but here I'm out.. Probably you're just suffering from domains without any I/O memory ranges assigned not being permitted to have multi-page contiguous memory ranges assigned? If not, do you force swiotlb on in the domain? And what resources does the USB HC require? Jan