]> git.baikalelectronics.ru Git - kernel.git/commit
drivers/xen: make [xen-]ballon explicitly non-modular
authorPaul Gortmaker <paul.gortmaker@windriver.com>
Mon, 22 Feb 2016 00:06:05 +0000 (19:06 -0500)
committerDavid Vrabel <david.vrabel@citrix.com>
Mon, 21 Mar 2016 15:13:44 +0000 (15:13 +0000)
commit4b4950ec005f476f93836aea432274df0a805e97
treea1815cfb5e97966a6b7a583f54ccda07d3200279
parentab6ae1e2ffad7947db7a696a96454b17fb622cc2
drivers/xen: make [xen-]ballon explicitly non-modular

The Makefile / Kconfig currently controlling compilation here is:

obj-y   += grant-table.o features.o balloon.o manage.o preempt.o time.o
[...]
obj-$(CONFIG_XEN_BALLOON)               += xen-balloon.o

...with:

drivers/xen/Kconfig:config XEN_BALLOON
drivers/xen/Kconfig:    bool "Xen memory balloon driver"

...meaning that they currently are not being built as modules by anyone.

Lets remove the modular code that is essentially orphaned, so that
when reading the driver there is no doubt it is builtin-only.

In doing so we uncover two implict includes that were obtained
by module.h having such a wide include scope itself:

In file included from drivers/xen/xen-balloon.c:41:0:
include/xen/balloon.h:26:51: warning: ‘struct page’ declared inside parameter list [enabled by default]
 int alloc_xenballooned_pages(int nr_pages, struct page **pages);
                                                   ^
include/xen/balloon.h: In function ‘register_xen_selfballooning’:
include/xen/balloon.h:35:10: error: ‘ENOSYS’ undeclared (first use in this function)
  return -ENOSYS;
          ^

This is fixed by adding mm-types.h and errno.h to the list.

We also delete the MODULE_LICENSE tags since all that information
is already contained at the top of the file in the comments.

Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
Reviewed-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
Signed-off-by: David Vrabel <david.vrabel@citrix.com>
drivers/xen/balloon.c
drivers/xen/xen-balloon.c