From: Julien Grall Date: Tue, 14 Jan 2014 01:41:18 +0000 (+0000) Subject: xen/hypercall: Allow HYPERVISOR_console_write to take a const string X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=19f3aaef68d529d0a037150b1c26f3b959dfbdfd;p=people%2Fjulieng%2Ffreebsd.git xen/hypercall: Allow HYPERVISOR_console_write to take a const string The hypercall console write won't modify the string. It's safe to put a const here. --- diff --git a/sys/amd64/include/xen/hypercall.h b/sys/amd64/include/xen/hypercall.h index 4ed0cdbee244..600adf7b2ac5 100644 --- a/sys/amd64/include/xen/hypercall.h +++ b/sys/amd64/include/xen/hypercall.h @@ -308,7 +308,7 @@ HYPERVISOR_xen_version( static inline int __must_check HYPERVISOR_console_io( - int cmd, unsigned int count, char *str) + int cmd, unsigned int count, const char *str) { return _hypercall3(int, console_io, cmd, count, str); } diff --git a/sys/i386/include/xen/hypercall.h b/sys/i386/include/xen/hypercall.h index f90b26da6fbe..59ef4ff0bd6f 100644 --- a/sys/i386/include/xen/hypercall.h +++ b/sys/i386/include/xen/hypercall.h @@ -299,7 +299,7 @@ HYPERVISOR_xen_version( static inline int HYPERVISOR_console_io( - int cmd, int count, char *str) + int cmd, int count, const char *str) { return _hypercall3(int, console_io, cmd, count, str); } diff --git a/sys/xen/hypervisor.h b/sys/xen/hypervisor.h index fe83496bd90d..96e558222982 100644 --- a/sys/xen/hypervisor.h +++ b/sys/xen/hypervisor.h @@ -55,7 +55,7 @@ extern uint64_t get_system_time(int ticks); static inline int -HYPERVISOR_console_write(char *str, int count) +HYPERVISOR_console_write(const char *str, int count) { return HYPERVISOR_console_io(CONSOLEIO_write, count, str); }