x86/HVM: make hvm_find_io_handler() static
authorJan Beulich <jbeulich@suse.com>
Thu, 2 Feb 2017 11:50:35 +0000 (12:50 +0100)
committerJan Beulich <jbeulich@suse.com>
Thu, 2 Feb 2017 11:50:35 +0000 (12:50 +0100)
This reduces the chance of misuse - calling it must in particular
always be accompanied by calling the corresponding ->complete() hook.
Constify its parameter at once.

Signed-off-by: Jan Beulich <jbeulich@suse.com>
Reviewed-by: Paul Durrant <paul.durrant@citrix.com>
xen/arch/x86/hvm/intercept.c
xen/include/asm-x86/hvm/io.h

index bf141c990575772f528e006d4dc608c24d7567e0..721fb380300c2f937263f4c344a2aaf6cd20b817 100644 (file)
@@ -210,7 +210,7 @@ int hvm_process_io_intercept(const struct hvm_io_handler *handler,
     return rc;
 }
 
-const struct hvm_io_handler *hvm_find_io_handler(ioreq_t *p)
+static const struct hvm_io_handler *hvm_find_io_handler(const ioreq_t *p)
 {
     struct domain *curr_d = current->domain;
     unsigned int i;
index 41ade5c959d737f893234b2eae0829b81f3a5b4e..d6801c17e09aeb7ee6f90165b69f8071710720d7 100644 (file)
@@ -97,8 +97,6 @@ struct hvm_io_ops {
 int hvm_process_io_intercept(const struct hvm_io_handler *handler,
                              ioreq_t *p);
 
-const struct hvm_io_handler *hvm_find_io_handler(ioreq_t *p);
-
 int hvm_io_intercept(ioreq_t *p);
 
 struct hvm_io_handler *hvm_next_io_handler(struct domain *d);