USB: ftdi_sio: fix minor typo in get_ftdi_divisor
authorIonut Nicu <ionut.nicu@cloudbit.ro>
Mon, 11 Jul 2011 13:46:12 +0000 (16:46 +0300)
committerGreg Kroah-Hartman <gregkh@suse.de>
Mon, 8 Aug 2011 19:34:47 +0000 (12:34 -0700)
Even if it's unlikely for this to cause an error,
there is a typo in the code that uses the bitwise-AND
operator instead of the logical one.

Signed-off-by: Ionut Nicu <ionut.nicu@cloudbit.ro>
Cc: stable <stable@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/usb/serial/ftdi_sio.c

index 2e06b90aa1f8f50139c8873011f1c34956077b63..9afb361437387bc412f5e8f9ac31660152c4da8b 100644 (file)
@@ -1171,7 +1171,7 @@ static __u32 get_ftdi_divisor(struct tty_struct *tty,
        case FT2232H: /* FT2232H chip */
        case FT4232H: /* FT4232H chip */
        case FT232H:  /* FT232H chip */
-               if ((baud <= 12000000) & (baud >= 1200)) {
+               if ((baud <= 12000000) && (baud >= 1200)) {
                        div_value = ftdi_2232h_baud_to_divisor(baud);
                } else if (baud < 1200) {
                        div_value = ftdi_232bm_baud_to_divisor(baud);