serial: imx: Fix warning when !CONFIG_SERIAL_IMX_CONSOLE
commite8bfa7607342a21af06a0d365bf2f1d3062643bd
authorFabio Estevam <fabio.estevam@freescale.com>
Wed, 5 Jun 2013 03:58:46 +0000 (5 00:58 -0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 6 Jun 2013 20:09:55 +0000 (6 13:09 -0700)
tree65771b961006cc0bd2c0ec9ccb1df8c8dea644e3
parent9f6d20ff848c23506c2ec55431479cb350179886
serial: imx: Fix warning when !CONFIG_SERIAL_IMX_CONSOLE

When CONFIG_SERIAL_IMX_CONSOLE is not selected the following build warnings
appear:

drivers/tty/serial/imx.c:274:13: warning: 'imx_port_ucrs_save' defined but not used [-Wunused-function]
drivers/tty/serial/imx.c:283:13: warning: 'imx_port_ucrs_restore' defined but not used [-Wunused-function]

imx_port_ucrs_save() and imx_port_ucrs_restore() are only used when
CONFIG_CONSOLE_POLL or CONFIG_SERIAL_IMX_CONSOLE are selected, so protect these
functions declaration with a proper ifdef.

Signed-off-by: Fabio Estevam <fabio.estevam@freescale.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/tty/serial/imx.c