From: Gianni Tedesco Subject: Re: [PATCH] xl/libxl: introducing libxl_primary_console_exec Date: Fri, 16 Jul 2010 18:40:42 +0100 Message-ID: <1279302042.1723.1872.camel@qabil.uk.xensource.com> References: Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Stefano Stabellini Cc: "xen-devel@lists.xensource.com" List-Id: xen-devel@lists.xenproject.org On Fri, 2010-07-16 at 18:03 +0100, Stefano Stabellini wrote: > Hi all, > this patch introduces libxl_primary_console_exec: a new libxl function > that finds the domid and console number corresponding to the primary > console of a given vm. The domid might be different from the domid of > the VM and the console number might not be 0 when using stubdoms. > The caller (xl_cmdimpl.c in this case) has to make sure that the stubdom > is already created before calling libxl_primary_console_exec in the hvm > case. In the PV case libxl_primary_console_exec has to be called before > libxl_run_bootloader. ... snip ... > int libxl_console_exec(struct libxl_ctx *ctx, uint32_t domid, int cons_num); > +/* libxl_primary_console_exec finds the domid and console number > + * corresponding to the primary console of the given vm, then calls > + * libxl_console_exec with the right arguments (domid might be different > + * if the guest is using stubdoms) */ > +int libxl_primary_console_exec(struct libxl_ctx *ctx, uint32_t domid_vm); If this call has some none-obvious ordering constraints then that should be mentioned in the header no? Gianni