drm/radeon: add audio support for DCE6/8 GPUs (v12)

Dan Carpenter dan.carpenter at oracle.com
Tue Sep 3 02:24:00 PDT 2013


Hello Alex Deucher,

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

The patch b530602fd462: "drm/radeon: add audio support for DCE6/8 
GPUs (v12)" from Jul 31, 2013, leads to the following Smatch 
complaint:

drivers/gpu/drm/radeon/dce6_afmt.c:91 dce6_afmt_select_pin()
	 warn: variable dereferenced before check 'dig->afmt->pin' (see line 89)

drivers/gpu/drm/radeon/dce6_afmt.c
    88		u32 offset = dig->afmt->offset;
    89		u32 id = dig->afmt->pin->id;
                         ^^^^^^^^^^^^^^^^^^
Patch adds dereference.

    90	
    91		if (!dig->afmt->pin)
                    ^^^^^^^^^^^^^^^
Patch adds check.

    92			return;
    93	

regards,
dan carpenter


More information about the dri-devel mailing list