Thread (13 messages) flat view 13 messages, 3 authors, 2021-01-12

Re: [PATCH v2 2/8] serial: stm32: fix code cleaning warnings and checks

From: Erwan LE RAY <hidden>
Date: 2021-01-12 10:03:56
Also in: linux-devicetree, linux-serial, lkml

Hello Greg,

As the V2 is already in your tty-next branch, how do want me to proceed 
to deliver the fix for Jiri remark ?
Do you expect a V3 or a new fix ?

Best Regards, Erwan.


On 1/11/21 10:58 AM, Jiri Slaby wrote:
On 06. 01. 21, 17:21, Erwan Le Ray wrote:
quoted
--- a/drivers/tty/serial/stm32-usart.c
+++ b/drivers/tty/serial/stm32-usart.c
...
quoted
@@ -973,18 +971,17 @@ static int stm32_init_port(struct stm32_port 
*stm32port,
      struct resource *res;
      int ret;
+    ret = platform_get_irq(pdev, 0);
+    if (ret <= 0)
+        return ret ? : -ENODEV;
+
      port->iotype    = UPIO_MEM;
      port->flags    = UPF_BOOT_AUTOCONF;
      port->ops    = &stm32_uart_ops;
      port->dev    = &pdev->dev;
      port->fifosize    = stm32port->info->cfg.fifosize;
      port->has_sysrq = IS_ENABLED(CONFIG_SERIAL_STM32_CONSOLE);
-
-    ret = platform_get_irq(pdev, 0);
-    if (ret <= 0)
-        return ret ? : -ENODEV;
      port->irq = ret;
I would move this set from ret above too. Or introduce a new variable, 
e.g. "irq".

thanks,
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help