On Thu, Mar 12, 2026 at 07:14:15PM +0530, Srinivasan Shanmugam wrote:
> amdgpu_dma_buf_attach() locks bo->tbo.base.resv before updating the BO
> sharing state and unlocks it before returning.
> 
> Return the local status variable after the unlock so the function has a
> single consistent success return path, which avoids the Smatch warning
> about inconsistent reservation lock handling.
> 
> Fixes the below:
> drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c:111 amdgpu_dma_buf_attach() warn: 
> inconsistent returns 'bo->tbo.base.resv'.
> 

This seems like a false positive to me and I don't like this solution
very much really... :/

I don't get this warning on my system on linux-next.  I have tested the
released version with and without the database...  :/

regards,
dan carpenter

Reply via email to