xen: purge no longer used hypervisor functions
HYPERVISOR_poll(), HYPERVISOR_block(), and HYPERVISOR_crash() appear no longer used. Further get_system_time() appears to have disappeared at some point in the past, so HYPERVISOR_poll() was broken anyway. No functional change intended. Reviewed by: royger
This commit is contained in:
parent
b2c50bb934
commit
61ccede8cf
@ -23,8 +23,6 @@
|
|||||||
#include <contrib/xen/hvm/dm_op.h>
|
#include <contrib/xen/hvm/dm_op.h>
|
||||||
#include <machine/xen/hypercall.h>
|
#include <machine/xen/hypercall.h>
|
||||||
|
|
||||||
extern uint64_t get_system_time(int ticks);
|
|
||||||
|
|
||||||
static inline int
|
static inline int
|
||||||
HYPERVISOR_console_write(const char *str, int count)
|
HYPERVISOR_console_write(const char *str, int count)
|
||||||
{
|
{
|
||||||
@ -43,19 +41,6 @@ HYPERVISOR_yield(void)
|
|||||||
return (rc);
|
return (rc);
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline int
|
|
||||||
HYPERVISOR_block(
|
|
||||||
void)
|
|
||||||
{
|
|
||||||
int rc = HYPERVISOR_sched_op(SCHEDOP_block, NULL);
|
|
||||||
|
|
||||||
#if CONFIG_XEN_COMPAT <= 0x030002
|
|
||||||
if (rc == -ENOXENSYS)
|
|
||||||
rc = HYPERVISOR_sched_op_compat(SCHEDOP_block, 0);
|
|
||||||
#endif
|
|
||||||
return (rc);
|
|
||||||
}
|
|
||||||
|
|
||||||
static inline void
|
static inline void
|
||||||
HYPERVISOR_shutdown(unsigned int reason)
|
HYPERVISOR_shutdown(unsigned int reason)
|
||||||
{
|
{
|
||||||
@ -69,33 +54,4 @@ HYPERVISOR_shutdown(unsigned int reason)
|
|||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline void
|
|
||||||
HYPERVISOR_crash(void)
|
|
||||||
{
|
|
||||||
HYPERVISOR_shutdown(SHUTDOWN_crash);
|
|
||||||
/* NEVER REACHED */
|
|
||||||
for (;;) ; /* eliminate noreturn error */
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Transfer control to hypervisor until an event is detected on one */
|
|
||||||
/* of the specified ports or the specified number of ticks elapse */
|
|
||||||
static inline int
|
|
||||||
HYPERVISOR_poll(
|
|
||||||
evtchn_port_t *ports, unsigned int nr_ports, int ticks)
|
|
||||||
{
|
|
||||||
int rc;
|
|
||||||
struct sched_poll sched_poll = {
|
|
||||||
.nr_ports = nr_ports,
|
|
||||||
.timeout = get_system_time(ticks)
|
|
||||||
};
|
|
||||||
set_xen_guest_handle(sched_poll.ports, ports);
|
|
||||||
|
|
||||||
rc = HYPERVISOR_sched_op(SCHEDOP_poll, &sched_poll);
|
|
||||||
#if CONFIG_XEN_COMPAT <= 0x030002
|
|
||||||
if (rc == -ENOXENSYS)
|
|
||||||
rc = HYPERVISOR_sched_op_compat(SCHEDOP_yield, 0);
|
|
||||||
#endif
|
|
||||||
return (rc);
|
|
||||||
}
|
|
||||||
|
|
||||||
#endif /* __XEN_HYPERVISOR_H__ */
|
#endif /* __XEN_HYPERVISOR_H__ */
|
||||||
|
Loading…
Reference in New Issue
Block a user