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: <20210126050901.GF1538@zhen-hp.sh.intel.com>
Date:   Tue, 26 Jan 2021 13:09:01 +0800
From:   Zhenyu Wang <zhenyuw@...ux.intel.com>
To:     Chris Wilson <chris@...is-wilson.co.uk>
Cc:     Dan Carpenter <dan.carpenter@...cle.com>,
        Yan Zhao <yan.y.zhao@...el.com>,
        David Airlie <airlied@...ux.ie>,
        intel-gfx@...ts.freedesktop.org, kernel-janitors@...r.kernel.org,
        linux-kernel@...r.kernel.org, dri-devel@...ts.freedesktop.org,
        Rodrigo Vivi <rodrigo.vivi@...el.com>,
        intel-gvt-dev@...ts.freedesktop.org,
        Zhi Wang <zhi.a.wang@...el.com>
Subject: Re: [PATCH] drm/i915/gvt: fix uninitialized return in
 intel_gvt_update_reg_whitelist()

On 2021.01.25 09:44:53 +0000, Chris Wilson wrote:
> Quoting Dan Carpenter (2021-01-25 08:48:30)
> > Smatch found an uninitialized variable bug in this code:
> > 
> >     drivers/gpu/drm/i915/gvt/cmd_parser.c:3191 intel_gvt_update_reg_whitelist()
> >     error: uninitialized symbol 'ret'.
> > 
> > The first thing that Smatch complains about is that "ret" isn't set if
> > we don't enter the "for_each_engine(engine, &dev_priv->gt, id) {" loop.
> > Presumably we always have at least one engine so that's a false
> > positive.
> > 
> > But it's definitely a bug to not set "ret" if i915_gem_object_pin_map()
> > fails.
> 
> True.
>  
> > Let's fix the bug and silence the false positive.
> > 
> > Fixes: 493f30cd086e ("drm/i915/gvt: parse init context to update cmd accessible reg whitelist")
> > Signed-off-by: Dan Carpenter <dan.carpenter@...cle.com>
> Reviewed-by: Chris Wilson <chris@...is-wilson.co.uk>

Thanks, Dan & Chris! Queued this up.

Download attachment "signature.asc" of type "application/pgp-signature" (196 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ