lkml.org 
[lkml]   [2015]   [Nov]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [RFC PATCH 04/28] lkl: host interface

At Tue, 3 Nov 2015 22:20:35 +0200,
Octavian Purdila wrote:
>
> This patch introduces the host operations that define the interface
> between the LKL and the host. These operations must be provided either
> by a host library or by the application itself.
(snip)
> +struct lkl_host_operations {
> + const char *virtio_devices;
> +
> + void (*print)(const char *str, int len);
> + void (*panic)(void);
> +
> + void* (*sem_alloc)(int count);
> + void (*sem_free)(void *sem);
> + void (*sem_up)(void *sem);
> + void (*sem_down)(void *sem);
> +
> + int (*thread_create)(void (*f)(void *), void *arg);
> + void (*thread_exit)(void);
> +
> + void* (*mem_alloc)(unsigned long);
> + void (*mem_free)(void *);
> +
> + unsigned long long (*time)(void);
> +
> + void* (*timer_alloc)(void (*fn)(void *), void *arg);
> + int (*timer_set_oneshot)(void *timer, unsigned long delta);
> + void (*timer_free)(void *timer);
> +
> + void* (*ioremap)(long addr, int size);
> + int (*iomem_access)(const volatile void *addr, void *val, int size,
> + int write);
> +
> +};

this is related to the thing that I'm improving libos right now.
my current conclusion is using rump hypercall interfaces,
which I'm currently working on.

we (libos and lkl) may have matured interface as well as
reduce/share the effort to have more underlying (host)
calls.

-- Hajime



\
 
 \ /
  Last update: 2015-11-04 00:41    [W:0.247 / U:1.888 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site