From e037f95ffb5355ffe295e1d106d02fefd284d882 Mon Sep 17 00:00:00 2001 From: "Matwey V. Kornilov" Date: Wed, 22 May 2013 11:13:38 +0400 Subject: tty: mxser: Fix build warning introduced by dfc7b837c7f9 (Re: linux-next: build warning after merge of the tty.current tree) Fix build warning at mxser.c introduced by dfc7b837c7f9 (tty: mxser: fix usage of opmode_ioaddr) Signed-off-by: Matwey V. Kornilov Reported-by: kbuild test robot Reported-by: Stephen Rothwell Signed-off-by: Greg Kroah-Hartman --- drivers/tty/mxser.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'drivers/tty/mxser.c') diff --git a/drivers/tty/mxser.c b/drivers/tty/mxser.c index f97b196693c..4c4a2367456 100644 --- a/drivers/tty/mxser.c +++ b/drivers/tty/mxser.c @@ -1674,15 +1674,15 @@ static int mxser_ioctl(struct tty_struct *tty, return mxser_ioctl_special(cmd, argp); if (cmd == MOXA_SET_OP_MODE || cmd == MOXA_GET_OP_MODE) { - if (info->board->chip_flag != MOXA_MUST_MU860_HWID) - return -EFAULT; - int p; unsigned long opmode; static unsigned char ModeMask[] = { 0xfc, 0xf3, 0xcf, 0x3f }; int shiftbit; unsigned char val, mask; + if (info->board->chip_flag != MOXA_MUST_MU860_HWID) + return -EFAULT; + p = tty->index % 4; if (cmd == MOXA_SET_OP_MODE) { if (get_user(opmode, (int __user *) argp)) -- cgit v1.2.3