serial: samsung: fix prevent defects in serial driver
authorYoungmin Nam <youngmin.nam@samsung.com>
Tue, 1 Dec 2015 01:09:49 +0000 (10:09 +0900)
committermyung-su.cha <myung-su.cha@samsung.com>
Wed, 9 May 2018 12:14:45 +0000 (21:14 +0900)
This patch fixes prevent defects in serial drvier.
The "qos_timeout" value should be read as unsigned long type.

Change-Id: Ib335fcbd4580e034d97221827545b8072e5c13b8
Signed-off-by: Youngmin Nam <youngmin.nam@samsung.com>
drivers/tty/serial/samsung.c

index 6ae5d43e4be19e3eac55a330716a528d80c9a011..32ff12cada86b90fc04521ca5e550c85c92cc8c3 100644 (file)
@@ -1594,8 +1594,8 @@ static int s3c24xx_serial_probe(struct platform_device *pdev)
                                                &ourport->uart_irq_affinity))
                ourport->uart_irq_affinity = 0;
 
-       if (of_property_read_u32(pdev->dev.of_node, "qos_timeout",
-                                       (u32 *)&ourport->qos_timeout))
+       if (of_property_read_u64(pdev->dev.of_node, "qos_timeout",
+                                       (u64 *)&ourport->qos_timeout))
                ourport->qos_timeout = 0;
 
        if ((ourport->mif_qos_val || ourport->cpu_qos_val)