OSDN Git Service

tty: hvc_xen: hide xen_console_remove when unused
authorArnd Bergmann <arnd@arndb.de>
Mon, 25 Jan 2016 21:54:58 +0000 (22:54 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 25 Feb 2018 10:03:46 +0000 (11:03 +0100)
commitf1691276e5e96d3922d6082130decb49e6524f5d
tree6b01f6ce536afa05100baeb2128ff743b89f8311
parent86f630e5b7cc1ef02f1e7de20a55bd84c09b3330
tty: hvc_xen: hide xen_console_remove when unused

commit e36ae3439936e13c33f5841c7c2c1a9875acbb6d upstream.

xencons_disconnect_backend() is only called from xen_console_remove(),
which is conditionally compiled, so we get a harmless warning when
CONFIG_HVC_XEN_FRONTEND is unset:

hvc/hvc_xen.c:350:12: error: 'xen_console_remove' defined but not used [-Werror=unused-function]

This moves the function down into the same #ifdef section to silence
the warning.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/tty/hvc/hvc_xen.c