From: Ian Jackson Subject: Re: [PATCH] [mq]: patch_libxl_get_console_tty.diff Date: Thu, 10 May 2012 18:02:32 +0100 Message-ID: <20395.62632.654951.334814@mariner.uk.xensource.com> References: <4a6043e1434a458506c3.1335626069@linux-bhi8.site> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <4a6043e1434a458506c3.1335626069@linux-bhi8.site> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Bamvor Jian Zhang Cc: xen-devel@lists.xensource.com List-Id: xen-devel@lists.xenproject.org Bamvor Jian Zhang writes ("[Xen-devel] [PATCH] [mq]: patch_libxl_get_console_tty.diff"): > diff -r 9dda0efd8ce1 -r 4a6043e1434a tools/libxl/libxl.c > --- a/tools/libxl/libxl.c Fri Apr 27 17:57:55 2012 +0200 > +++ b/tools/libxl/libxl.c Sat Apr 28 22:36:56 2012 +0800 > @@ -15,6 +15,8 @@ > */ > > #include "libxl_osdeps.h" > +//#include "libxl_osdeps.h" > +//#include "libxl_osdeps.h" Thanks for posting this but was int actually inteded for inclusion in the tree ? If so we need a commit message and a Signed-off-by and so forth. Also we may be too late for 4.2 considering the feature freeze. > +int libxl_get_console_tty(libxl_ctx *ctx, uint32_t domid, char **path) > +{ We already have various functions to refer to and open consoles, which have much of this functionality in them already. That shouldn't be duplicated. Also we need to make a policy decision about whether the fact that the console looks like a tty is a part of the API. > +/* libxl_get_console_tty get the tty path from xenstore according to the > + * domain id. > + */ > +int libxl_get_console_tty(libxl_ctx *ctx, uint32_t domid, char **path); In any case the doc comment should not mention xenstore. It should also document the memory allocation behaviour. Ian.