From mboxrd@z Thu Jan 1 00:00:00 1970 From: George Dunlap Subject: Re: [PATCH V3 3/6] libxl: add pvusb API Date: Tue, 19 May 2015 19:20:48 +0100 Message-ID: References: <1429415452-6161-1-git-send-email-cyliu@suse.com> <1429415452-6161-4-git-send-email-cyliu@suse.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <1429415452-6161-4-git-send-email-cyliu@suse.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Chunyan Liu Cc: Lars Kurth , Wei Liu , Ian Campbell , "xen-devel@lists.xen.org" , Ian Jackson , Simon Cao List-Id: xen-devel@lists.xenproject.org On Sun, Apr 19, 2015 at 4:50 AM, Chunyan Liu wrote: > +int libxl_device_usbctrl_getinfo(libxl_ctx *ctx, uint32_t domid, > + libxl_device_usbctrl *usbctrl, > + libxl_usbctrlinfo *usbctrlinfo) > +{ > + GC_INIT(ctx); > + char *dompath, *usbctrlpath; > + char *val; > + int rc = 0; > + > + usbctrlinfo->devid = usbctrl->devid; > + usbctrlinfo->ports = usbctrl->ports; > + usbctrlinfo->version = usbctrl->version; ...and following on from the previous mail, it looks like the other device_*_getinfo() functions *only* read devid -- which means you just have to make the struct and fill in devid, and getinfo() will tell *you* the ports, the version, and so on. -George