All of lore.kernel.org
 help / color / mirror / Atom feed
* [radeon-alex:amd-staging-drm-next 170/201] drivers/gpu/drm/amd/amdgpu/../powerplay/hwmgr/smu_helper.c:663 smu_set_watermarks_for_clocks_ranges() error: we previously assumed 'wm_with_clock_ranges' could be null (see line 660)
@ 2018-04-19  4:56 Dan Carpenter
  0 siblings, 0 replies; only message in thread
From: Dan Carpenter @ 2018-04-19  4:56 UTC (permalink / raw)
  To: kbuild, Rex Zhu; +Cc: Huang Rui, kbuild-all, dri-devel

tree:   git://people.freedesktop.org/~agd5f/linux.git amd-staging-drm-next
head:   d64547a1cfa860e241b27723c88f86fa3d88d3d7
commit: d6c9a7dc86cd39146afb0f47c06b6f95d7dd4997 [170/201] drm/amd/pp: Move common code to smu_helper.c

smatch warnings:
drivers/gpu/drm/amd/amdgpu/../powerplay/hwmgr/smu_helper.c:663 smu_set_watermarks_for_clocks_ranges() error: we previously assumed 'wm_with_clock_ranges' could be null (see line 660)

git remote add radeon-alex git://people.freedesktop.org/~agd5f/linux.git
git remote update radeon-alex
git checkout d6c9a7dc86cd39146afb0f47c06b6f95d7dd4997
vim +/wm_with_clock_ranges +663 drivers/gpu/drm/amd/amdgpu/../powerplay/hwmgr/smu_helper.c

d6c9a7dc Rex Zhu 2018-04-08  653  
d6c9a7dc Rex Zhu 2018-04-08  654  int smu_set_watermarks_for_clocks_ranges(void *wt_table,
d6c9a7dc Rex Zhu 2018-04-08  655  		struct pp_wm_sets_with_clock_ranges_soc15 *wm_with_clock_ranges)
d6c9a7dc Rex Zhu 2018-04-08  656  {
d6c9a7dc Rex Zhu 2018-04-08  657  	uint32_t i;
d6c9a7dc Rex Zhu 2018-04-08  658  	struct watermarks *table = wt_table;
d6c9a7dc Rex Zhu 2018-04-08  659  
d6c9a7dc Rex Zhu 2018-04-08 @660  	if (!table || wm_with_clock_ranges)
                                                      ^^^^^^^^^^^^^^^^^^^^
This test is inverted.  We should be checking if it's NULL not non-NULL.

d6c9a7dc Rex Zhu 2018-04-08  661  		return -EINVAL;
d6c9a7dc Rex Zhu 2018-04-08  662  
d6c9a7dc Rex Zhu 2018-04-08 @663  	if (wm_with_clock_ranges->num_wm_sets_dmif > 4 || wm_with_clock_ranges->num_wm_sets_mcif > 4)

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2018-04-19  4:56 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-04-19  4:56 [radeon-alex:amd-staging-drm-next 170/201] drivers/gpu/drm/amd/amdgpu/../powerplay/hwmgr/smu_helper.c:663 smu_set_watermarks_for_clocks_ranges() error: we previously assumed 'wm_with_clock_ranges' could be null (see line 660) Dan Carpenter

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.