]> git.karo-electronics.de Git - linux-beck.git/commitdiff
serial: msm_serial: fix comparison of different types
authorJingoo Han <jg1.han@samsung.com>
Thu, 8 Aug 2013 08:38:20 +0000 (17:38 +0900)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 12 Aug 2013 18:35:32 +0000 (11:35 -0700)
Fix the following sparse warning:

drivers/tty/serial/msm_serial.c:237:37: error: incompatible types in comparison expression (different type sizes)

Signed-off-by: Jingoo Han <jg1.han@samsung.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/tty/serial/msm_serial.c

index 252d514b47fb46b93c1ce16efd4b683d2fe30f51..8f58540d2c71a23ed8eb7aee1958ed8e4d97197a 100644 (file)
@@ -234,7 +234,8 @@ static void handle_tx(struct uart_port *port)
                        break;
 
                if (msm_port->is_uartdm)
-                       num_chars = min(tx_count - tf_pointer, sizeof(buf));
+                       num_chars = min(tx_count - tf_pointer,
+                                       (unsigned int)sizeof(buf));
                else
                        num_chars = 1;