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]
Message-ID: <CACO55tt3FF1gEffPjQTS+m3oW1yWG_xUQL_kP=kezyesj_oYkg@mail.gmail.com>
Date:   Tue, 28 Sep 2021 13:17:50 +0200
From:   Karol Herbst <kherbst@...hat.com>
To:     CGEL <cgel.zte@...il.com>
Cc:     Ben Skeggs <bskeggs@...hat.com>, David Airlie <airlied@...ux.ie>,
        Daniel Vetter <daniel@...ll.ch>,
        Alistair Popple <apopple@...dia.com>,
        dri-devel <dri-devel@...ts.freedesktop.org>,
        nouveau <nouveau@...ts.freedesktop.org>,
        LKML <linux-kernel@...r.kernel.org>,
        Luo penghao <luo.penghao@....com.cn>,
        Zeal Robot <zealci@....com.cn>
Subject: Re: [PATCH linux-next] drm/nouveau/mmu/gp100-: drop unneeded
 assignment in the if condition.

Reviewed-by: Karol Herbst <kherbst@...hat.com>

but I will remove the unnecessary brackets as well

On Sat, Aug 21, 2021 at 10:46 AM CGEL <cgel.zte@...il.com> wrote:
>
> From: Luo penghao <luo.penghao@....com.cn>
>
> In order to keep the code style consistency of the whole file,
> the 'inst' assignments should be deleted.
>
> The clang_analyzer complains as follows:
>
> drivers/gpu/drm/nouveau/nvkm/subdev/mmu/vmmgp100.c:499:8: warning:
> Although the value storedto 'inst' is used in the enclosing expression,
> the value is never actually read from 'inst'.
>
> Reported-by: Zeal Robot <zealci@....com.cn>
> Signed-off-by: Luo penghao <luo.penghao@....com.cn>
> ---
>  drivers/gpu/drm/nouveau/nvkm/subdev/mmu/vmmgp100.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/mmu/vmmgp100.c b/drivers/gpu/drm/nouveau/nvkm/subdev/mmu/vmmgp100.c
> index f02abd9..5d7766a 100644
> --- a/drivers/gpu/drm/nouveau/nvkm/subdev/mmu/vmmgp100.c
> +++ b/drivers/gpu/drm/nouveau/nvkm/subdev/mmu/vmmgp100.c
> @@ -502,7 +502,7 @@ gp100_vmm_fault_cancel(struct nvkm_vmm *vmm, void *argv, u32 argc)
>         args->v0.inst |= 0x80000000;
>
>         if (!WARN_ON(nvkm_gr_ctxsw_pause(device))) {
> -               if ((inst = nvkm_gr_ctxsw_inst(device)) == args->v0.inst) {
> +               if ((nvkm_gr_ctxsw_inst(device)) == args->v0.inst) {
>                         gf100_vmm_invalidate(vmm, 0x0000001b
>                                              /* CANCEL_TARGETED. */ |
>                                              (args->v0.hub    << 20) |
> --
> 2.15.2
>
>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ