[bug report] drm/amdkfd: Track SDMA utilization per process

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello Mukul Joshi,

This is a semi-automatic email about new static checker warnings.

The patch 522b89c63370: "drm/amdkfd: Track SDMA utilization per 
process" from May 26, 2020, leads to the following Smatch complaint:

    drivers/gpu/drm/amd/amdgpu/../amdkfd/kfd_process.c:109 kfd_sdma_activity_worker()
    warn: variable dereferenced before check 'pdd' (see line 106)

    drivers/gpu/drm/amd/amdgpu/../amdkfd/kfd_process.c:109 kfd_sdma_activity_worker()
    warn: address of 'pdd->qpd' is non-NULL

drivers/gpu/drm/amd/amdgpu/../amdkfd/kfd_process.c
   105		pdd = workarea->pdd;
   106		dqm = pdd->dev->dqm;
                      ^^^^^^^^
Dereference.

   107		qpd = &pdd->qpd;
   108	
   109		if (!pdd || !dqm || !qpd)
                     ^^^             ^^^
pdd is checked too late and qpd can't possibly be NULL.

   110			return;
   111	

regards,
dan carpenter
_______________________________________________
amd-gfx mailing list
amd-gfx@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/amd-gfx



[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux