[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [PATCH v5 2/2] xl: Add escape character argument to xl console
On Wed, Jul 12, 2023 at 11:29:17AM +0100, Peter Hoyes wrote: > @@ -1968,9 +1979,12 @@ int libxl_console_exec(libxl_ctx *ctx, uint32_t domid, > int cons_num, > * guests using pygrub. > * If notify_fd is not -1, xenconsole will write 0x00 to it to nofity > * the caller that it has connected to the guest console. > + * If escape_character is not NULL, the provided value is used to exit > + * the guest console. > */ > int libxl_primary_console_exec(libxl_ctx *ctx, uint32_t domid_vm, > - int notify_fd); > + int notify_fd, > + char* escape_character); > > #if defined(LIBXL_API_VERSION) && LIBXL_API_VERSION < 0x040800 > > @@ -1989,6 +2003,25 @@ static inline int > libxl_primary_console_exec_0x040700(libxl_ctx *ctx, > } > #define libxl_primary_console_exec libxl_primary_console_exec_0x040700 > > +#elif defined(LIBXL_API_VERSION) && LIBXL_API_VERSION < 0x041800 > + > +static inline int libxl_console_exec_0x041800(libxl_ctx *ctx, uint32_t domid, Is is preferred to name these compatibility function with the version of Xen that last presented this API, so could you rename it to "libxl_console_exec_0x041700" ? > + int cons_num, > + libxl_console_type type, > + int notify_fd) > +{ > + return libxl_console_exec(ctx, domid, cons_num, type, notify_fd, NULL); > +} > +#define libxl_console_exec libxl_console_exec_0x041800 > + > +static inline int libxl_primary_console_exec_0x041800(libxl_ctx *ctx, Same thing here. > + uint32_t domid_vm, > + int notify_fd) > +{ > + return libxl_primary_console_exec(ctx, domid_vm, notify_fd, NULL); > +} > +#define libxl_primary_console_exec libxl_primary_console_exec_0x041800 > + Also, could you add the extra NULL argument in the function call of both "libxl_console_exec_0x040700()" and "libxl_primary_console_exec_0x040700()" ? Thanks, -- Anthony PERARD
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |