lkml.org 
[lkml]   [2021]   [Jun]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRE: [PATCH v4] serial: samsung: change to platform_get_irq_optional
Date


> -----Original Message-----
> From: Tamseel Shams <m.shams@samsung.com>
> Sent: Monday, June 21, 2021 10:18 AM
> To: kgene@kernel.org; krzk@kernel.org; gregkh@linuxfoundation.org;
> jslaby@suse.com
> Cc: linux-arm-kernel@lists.infradead.org; linux-samsung-soc@vger.kernel.org;
> linux-serial@vger.kernel.org; linux-kernel@vger.kernel.org;
> alim.akhtar@samsung.com; ajaykumar.rs@samsung.com; Tamseel Shams
> <m.shams@samsung.com>
> Subject: [PATCH v4] serial: samsung: change to platform_get_irq_optional
>
> In few older Samsung SoCs like s3c2410, s3c2412 and s3c2440, UART IP is having
> 2 interrupt lines.
> However, in other SoCs like s3c6400, s5pv210, exynos5433, and exynos4210
> UART is having only 1 interrupt line. Due to this, "platform_get_irq(platdev, 1)"
> call in the driver gives the following false-positive error:
> "IRQ index 1 not found" on recent platforms.
>
> This patch replaces the platform_get_irq() call with
> platform_get_irq_optional() and hence avoiding the false-positive error.
>
> Signed-off-by: Tamseel Shams <m.shams@samsung.com>
> ---
> Commit message is changed.
> Addressed Krzysztof's previous comment.
>
> drivers/tty/serial/samsung_tty.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/tty/serial/samsung_tty.c b/drivers/tty/serial/samsung_tty.c
> index 6ef614d8648c..c44582011b9b 100644
> --- a/drivers/tty/serial/samsung_tty.c
> +++ b/drivers/tty/serial/samsung_tty.c
> @@ -1911,7 +1911,7 @@ static int s3c24xx_serial_init_port(struct
> s3c24xx_uart_port *ourport,
> ourport->tx_irq = ret + 1;
> }
>
> - ret = platform_get_irq(platdev, 1);
> + ret = platform_get_irq_optional(platdev, 1);
> if (ret > 0)
> ourport->tx_irq = ret;
> /*
> --
>

Please ignore this patch.
Sorry for the spam.

Thanks & Regards,
Tamseel Shams


\
 
 \ /
  Last update: 2021-06-21 07:37    [W:0.040 / U:0.324 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site