lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Wed, 21 Oct 2020 14:33:11 -0400
From:   Alex Deucher <alexdeucher@...il.com>
To:     Sumera Priyadarsini <sylphrenadin@...il.com>
Cc:     Maling list - DRI developers <dri-devel@...ts.freedesktop.org>,
        Dave Airlie <airlied@...ux.ie>,
        "Kuehling, Felix" <Felix.Kuehling@....com>,
        LKML <linux-kernel@...r.kernel.org>,
        amd-gfx list <amd-gfx@...ts.freedesktop.org>,
        Melissa Wen <melissa.srw@...il.com>,
        Daniel Vetter <daniel@...ll.ch>,
        "Deucher, Alexander" <alexander.deucher@....com>,
        Christian Koenig <christian.koenig@....com>
Subject: Re: [Outreachy kernel][PATCH] gpu: amd: Return boolean types instead
 of integer values

Applied.  Thanks!

Alex

On Wed, Oct 21, 2020 at 2:29 PM Sumera Priyadarsini
<sylphrenadin@...il.com> wrote:
>
> Return statements for functions returning bool should use truth
> and false instead of 1 and 0 respectively.
>
> Modify cik_event_interrupt.c to return false instead of 0.
>
> Issue found with Coccinelle.
>
> Signed-off-by: Sumera Priyadarsini <sylphrenadin@...il.com>
> ---
>  drivers/gpu/drm/amd/amdkfd/cik_event_interrupt.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/amd/amdkfd/cik_event_interrupt.c b/drivers/gpu/drm/amd/amdkfd/cik_event_interrupt.c
> index 24b471734117..8e64c01565ac 100644
> --- a/drivers/gpu/drm/amd/amdkfd/cik_event_interrupt.c
> +++ b/drivers/gpu/drm/amd/amdkfd/cik_event_interrupt.c
> @@ -66,12 +66,12 @@ static bool cik_event_interrupt_isr(struct kfd_dev *dev,
>         vmid  = (ihre->ring_id & 0x0000ff00) >> 8;
>         if (vmid < dev->vm_info.first_vmid_kfd ||
>             vmid > dev->vm_info.last_vmid_kfd)
> -               return 0;
> +               return false;
>
>         /* If there is no valid PASID, it's likely a firmware bug */
>         pasid = (ihre->ring_id & 0xffff0000) >> 16;
>         if (WARN_ONCE(pasid == 0, "FW bug: No PASID in KFD interrupt"))
> -               return 0;
> +               return false;
>
>         /* Interrupt types we care about: various signals and faults.
>          * They will be forwarded to a work queue (see below).
> --
> 2.25.1
>
> _______________________________________________
> amd-gfx mailing list
> amd-gfx@...ts.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/amd-gfx

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ