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:   Fri, 9 Oct 2020 09:39:47 -0500
From:   "Gustavo A. R. Silva" <gustavoars@...nel.org>
To:     Christian König <christian.koenig@....com>
Cc:     Alex Deucher <alexander.deucher@....com>,
        David Airlie <airlied@...ux.ie>,
        Daniel Vetter <daniel@...ll.ch>, amd-gfx@...ts.freedesktop.org,
        dri-devel@...ts.freedesktop.org, linux-kernel@...r.kernel.org,
        linux-hardening@...r.kernel.org
Subject: Re: [PATCH][next] amd/amdgpu_ctx: Use struct_size() helper and
 kmalloc()

On Fri, Oct 09, 2020 at 04:29:55PM +0200, Christian König wrote:
> > > > -	entity = kcalloc(1, offsetof(typeof(*entity), fences[amdgpu_sched_jobs]),
> > > > +	entity = kmalloc(struct_size(entity, fences, amdgpu_sched_jobs),
> > > NAK. You could use kzalloc() here, but kmalloc won't zero initialize the
> > > memory which could result in unforeseen consequences.
> > Oh I see.. I certainly didn't take that into account.
> > 
> > I'll fix that up and respin.
> 
> Shit happens, we already have a fix for this. Alex merged it and it
> immediately broke our testing systems.

:/

> So one of our engineers came up with a fix which should already have been
> applied.

Great. Good to know it's already fixed! :)

Thanks
--
Gustavo

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ