Hello Alex Hung,

Commit 04bed7922fa9 ("drm/amd/display: Add KUnit tests for
mst_types") from Jun 17, 2026 (linux-next), leads to the following
Smatch static checker warning:

        
drivers/gpu/drm/amd/amdgpu/../display/amdgpu_dm/tests/amdgpu_dm_mst_types_test.c:1027
 dm_mst_test_fp_guarded_public_stubs()
        error: NULL dereference inside function

drivers/gpu/drm/amd/amdgpu/../display/amdgpu_dm/tests/amdgpu_dm_mst_types_test.c
    1025 static void dm_mst_test_fp_guarded_public_stubs(struct kunit *test)
    1026 {
--> 1027         KUNIT_EXPECT_EQ(test, dm_dp_mst_is_port_support_mode(NULL, 
NULL),
                                                                      ^^^^  ^^^^
Passing a NULL here will just crash right away.

    1028                         (enum dc_status)DC_OK);
    1029 }

This email is a free service from the Smatch-CI project [smatch.sf.net].

regards,
dan carpenter

Reply via email to