[kbuild] Re: drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c:1433 amdgpu_discovery_get_vcn_info() error: buffer overflow 'adev->vcn.vcn_codec_disable_mask' 2 <= 3

2022-06-02 Thread Dan Carpenter
On Thu, Jun 02, 2022 at 10:24:58AM -0400, Alex Deucher wrote: > On Thu, Jun 2, 2022 at 7:51 AM Dan Carpenter wrote: > > > > On Thu, Jun 02, 2022 at 08:26:03AM +0200, Ernst Sjöstrand wrote: > > > Dan: I also ran Smatch which resulted in the following discussion: > > > > > >

[kbuild] Re: drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c:1433 amdgpu_discovery_get_vcn_info() error: buffer overflow 'adev->vcn.vcn_codec_disable_mask' 2 <= 3

2022-06-02 Thread Dan Carpenter
On Thu, Jun 02, 2022 at 08:26:03AM +0200, Ernst Sjöstrand wrote: > Dan: I also ran Smatch which resulted in the following discussion: > > https://lists.freedesktop.org/archives/amd-gfx/2022-May/079228.html Since the bounds check is dead code which does not make sense and is not required,

[kbuild] Re: drivers/gpu/drm/amd/amdgpu/amdgpu_discovery.c:1433 amdgpu_discovery_get_vcn_info() error: buffer overflow 'adev->vcn.vcn_codec_disable_mask' 2 <= 3

2022-05-27 Thread Dan Carpenter
On Fri, May 27, 2022 at 07:56:48AM +, Chen, Guchun wrote: > A patch was available already to protect against such scenario. > > https://patchwork.freedesktop.org/patch/486289/ , "drm/amdgpu/discovery: > validate VCN and SDMA instances" > What? That's an unrelated patch and it has already