Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

drivers/char/mxser.c: fix compilation warning in mxser.c

Both mxser_disable_must_enchance_mode() and mxser_get_must_hardware_id()
called from function CheckIsMoxaMust(), when CONFIG_PCI=y. So mark both
the functions under CONFIG_PCI.

We were warned by the following warning.

drivers/char/mxser.c:306: warning: `mxser_disable_must_enchance_mode' defined but not used
drivers/char/mxser.c:391: warning: `mxser_get_must_hardware_id'
defined but not used

Signed-off-by: Rakib Mullick <rakib.mullick@gmail.com>
Cc: Jiri Slaby <jirislaby@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>

authored by

Rakib Mullick and committed by
Linus Torvalds
e89d67cf 5a780fc0

+4
+4
drivers/char/mxser.c
··· 303 303 outb(oldlcr, baseio + UART_LCR); 304 304 } 305 305 306 + #ifdef CONFIG_PCI 306 307 static void mxser_disable_must_enchance_mode(unsigned long baseio) 307 308 { 308 309 u8 oldlcr; ··· 318 317 outb(efr, baseio + MOXA_MUST_EFR_REGISTER); 319 318 outb(oldlcr, baseio + UART_LCR); 320 319 } 320 + #endif 321 321 322 322 static void mxser_set_must_xon1_value(unsigned long baseio, u8 value) 323 323 { ··· 390 388 outb(oldlcr, baseio + UART_LCR); 391 389 } 392 390 391 + #ifdef CONFIG_PCI 393 392 static void mxser_get_must_hardware_id(unsigned long baseio, u8 *pId) 394 393 { 395 394 u8 oldlcr; ··· 407 404 *pId = inb(baseio + MOXA_MUST_HWID_REGISTER); 408 405 outb(oldlcr, baseio + UART_LCR); 409 406 } 407 + #endif 410 408 411 409 static void SET_MOXA_MUST_NO_SOFTWARE_FLOW_CONTROL(unsigned long baseio) 412 410 {