[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH] libxl: mark internal functions hidden



On Thu, 2012-04-12 at 09:30 +0100, Ian Campbell wrote:
> @@ -597,21 +598,21 @@ _hidden void libxl__event_disaster(libxl
>  
>  /* Fills in, or disposes of, the resources held by, a poller whose
>   * space the caller has allocated.  ctx must be locked. */
> -int libxl__poller_init(libxl_ctx *ctx, libxl__poller *p);
> -void libxl__poller_dispose(libxl__poller *p);
> +_hidden int libxl__poller_init(libxl_ctx *ctx, libxl__poller *p);
> +_hidden void libxl__poller_dispose(libxl__poller *p);

BTW, I noticed a bunch of libxl__ functions which take a ctx instead of
a gc while doing this.

$ grep libxl_ctx tools/libxl/libxl_internal.h
_hidden void libxl__logv(libxl_ctx *ctx, xentoollog_level msglevel, int 
errnoval,
_hidden void libxl__log(libxl_ctx *ctx, xentoollog_level msglevel, int errnoval,
_hidden void libxl__alloc_failed(libxl_ctx *, const char *func,
[...]
_hidden int libxl__poller_init(libxl_ctx *ctx, libxl__poller *p);
_hidden libxl__poller *libxl__poller_get(libxl_ctx *ctx);
_hidden void libxl__poller_put(libxl_ctx *ctx, libxl__poller *p);
_hidden int libxl__atfork_init(libxl_ctx *ctx);
_hidden char *libxl__object_to_json(libxl_ctx *ctx, const char *type,
_hidden int libxl__init_recursive_mutex(libxl_ctx *ctx, pthread_mutex_t *lock);
[...]
_hidden libxl__ao *libxl__ao_create(libxl_ctx*, uint32_t domid,
_hidden void libxl__ao__destroy(libxl_ctx*, libxl__ao *ao);
_hidden libxl__carefd *libxl__carefd_record(libxl_ctx *ctx, int fd);
_hidden libxl__carefd *libxl__carefd_opened(libxl_ctx *ctx, int fd);
static inline void libxl__ctx_lock(libxl_ctx *ctx) {
static inline void libxl__ctx_unlock(libxl_ctx *ctx) {

libxl__log*, libxl__alloc_failed and libxl__ctx_{un}lock are probably
fine, libxl__object_to_json probably is too, but the others ought to
take a gc? Something to be left for 4.3 IMHO but I thought I'd mention
it.

Ian.


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.