lkml.org 
[lkml]   [2021]   [Dec]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH] serial: lantiq: store and compare return status correctly
On Tue, Dec 21, 2021 at 2:42 PM Muhammad Usama Anjum
<usama.anjum@collabora.com> wrote:
>
> platform_get_irq() returns signed status. It should be stored and
> compared as signed value before storing to unsigned variable. Implicit
> conversion from signed to unsigned and then comparison with less than
> zero is wrong as unsigned value can never be less than zero.
>
> Fixes: f087f01ca2 ("serial: lantiq: Use platform_get_irq() to get the interrupt")
> Signed-off-by: Muhammad Usama Anjum <usama.anjum@collabora.com>
> ---
> drivers/tty/serial/lantiq.c | 24 ++++++++++++++----------
> 1 file changed, 14 insertions(+), 10 deletions(-)

Thanks for fixing this.

Acked-by: Rob Herring <robh@kernel.org>

\
 
 \ /
  Last update: 2021-12-22 14:39    [W:0.030 / U:0.100 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site