The amdgpu_vm_bo_rmv() function frees "bo_va" so we shouldn't free it
a second time.
Fixes: 4e4bbe7343a6 ("drm/amdgpu:add new file for SRIOV")
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_virt.c
b/drivers/gpu/dr
e.\n");
BUG_ON() takes a condition argument, not a format string.
311 break;
312 }
313 }
regards,
dan carpenter
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
reak;
425 mdelay(1);
426 }
427 break;
^^
428 }
429
regards,
dan carpenter
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
return -ENOMEM;
324 }
regards,
dan carpenter
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
k_dep_table->entries[i].usCKSVOffsetandDisable & 0x7F);
439 clk_table->entries[i].sclk_offset =
440 clk_dep_table->entries[i].usAVFSOffset;
441 }
442
regards,
dan carpenter
__
tch is trying to do or why it exists...
> adev->gfx.config.max_shader_engines is set in gfx_v6_0_gpu_init() and
> it must be < 4 so we'll never be beyond the end of the array.
Could you remove the condition then? We should either check it always
or not at all. We shouldn't check it half
This switch statement is missing breaks.
Fixes: 2a5071056e6a ("drm/amd/powerplay: add global PowerPlay mutex.")
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff --git a/drivers/gpu/drm/amd/powerplay/amd_powerplay.c
b/drivers/gpu/drm/amd/powerplay/amd_powerplay.c
in
We accidentally dereference "cb" if the kmalloc() fails.
Fixes: 451bc8eb8fe6 ("drm/amdgpu: fix PRT teardown on VM fini v3")
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
b/drivers/gpu/drm/amd/amdgpu/amdg
tate_adjust_rules() error: uninitialized symbol
'stable_pstate_sclk_dpm_percentage'.
regards,
dan carpenter
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
We should return unlock on the error path in pp_dpm_dispatch_tasks()
and there is a double lock bug in pp_dpm_set_sclk_od().
Fixes: 2a5071056e6a ("drm/amd/powerplay: add global PowerPlay mutex.")
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff --git a/drivers/gpu/d
On Mon, Apr 03, 2017 at 03:12:31PM -0400, Alex Deucher wrote:
> On Mon, Apr 3, 2017 at 2:53 PM, Dan Carpenter <dan.carpen...@oracle.com>
> wrote:
> > Hello Ken Wang,
> >
> > The patch 220ab9bd1ccf: "drm/amdgpu: soc15 enable (v3)" from Mar 6,
> > 2017,
If we added an:
else
BUG();
that would silence the warning.
regards,
dan carpenter
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
(i * 16 + j * 8));
3749 }
3750 }
3751
3752 gfx_v6_0_select_se_sh(adev, 0x, 0x, 0x);
3753 mutex_unlock(>grbm_idx_mutex);
3754
3755 cu_info->number = active_cu_number;
3756
On Thu, Aug 10, 2017 at 03:02:53PM +0200, Christian König wrote:
> Am 10.08.2017 um 14:53 schrieb Dan Carpenter:
> > On Thu, Aug 10, 2017 at 02:30:15PM +0200, Christian König wrote:
> > > Am 10.08.2017 um 14:16 schrieb Dan Carpenter:
> > > > "frag_align"
"frag_align" is a u64, so presumably we want to use the high bits as
well instead of shift wrapping.
Fixes: 6be7adb37d9b ("drm/amdgpu: increase fragmentation size for Vega10 v2")
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff --git a/drivers/gpu/drm
On Thu, Aug 10, 2017 at 02:30:15PM +0200, Christian König wrote:
> Am 10.08.2017 um 14:16 schrieb Dan Carpenter:
> > "frag_align" is a u64, so presumably we want to use the high bits as
> > well instead of shift wrapping.
> >
> > Fixes: 6be7adb37d9b (&qu
On Thu, Aug 10, 2017 at 02:30:15PM +0200, Christian König wrote:
> Am 10.08.2017 um 14:16 schrieb Dan Carpenter:
> > "frag_align" is a u64, so presumably we want to use the high bits as
> > well instead of shift wrapping.
> >
> > Fixes: 6be7adb37d9b (&qu
This is just future proofing code, not something that can be triggered
in real life. We're testing to make sure we don't shift wrap when we
do "1ull << i" so "i" has to be in the 0-63 range. If it's 64 then we
have gone too far.
Signed-off-by: Dan Carpenter <da
qpd, q);
194 *allocated_vmid = 0;
195 }
196 mutex_unlock(>lock);
197 return retval;
198 }
regards,
dan carpenter
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
My static checker complains that it's possible for "r" to be
uninitialized. It used to be set to zero so this returns it to the old
behavior.
Fixes: 98a7f88ce9a9 ("drm/amdgpu: bind BOs with GTT space allocated directly
v2")
Signed-off-by: Dan Carpenter <dan.carpen...@
ISCRETE_MC_REGISTER_ARRAY_SIZE".
The "table->last" value can't possibly be greater than the array size
and it is allowed to be equal to it. So let's just remove that test
entirely.
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
---
Not tested. Please review this one c
ISCRETE_MC_REGISTER_ARRAY_SIZE".
The "table->last" value can't possibly be greater than the array size
and it is allowed to be equal to it. So let's just remove that test
entirely.
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
---
Not tested. Please review this one care
I sent a patch for this bug earlier. There is a second bug later in the
function which my patch fixes as well.
regards,
dan carpenter
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
Smatch complains about a signedness bug here:
vega10_hwmgr.c:4202 vega10_force_clock_level()
warn: always true condition '(i >= 0) => (0-u32max >= 0)'
Fixes: 7b52db39a4c2 ("drm/amd/powerplay: fix bug sclk/mclk level can't be set
on vega10.")
Signed-of
We accidentally return ERR_PTR(0) which is NULL. The caller is not
expecting that and it leads to an Oops.
Fixes: dd59239a9862 ("amdkfd: init aperture once per process")
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_process.
also possible I may have missed something.
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c
b/drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c
index b46280c1279f..2918de2f39ec 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c
+++ b/
We accidentally inverted an if statement and turned amd_powerplay_reset()
into a no-op.
Fixes: ae97988fc89e ("drm/amd/powerplay: tidy up ret checks in amd_powerplay.c
(v3)")
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
---
IMHO, tidying unreadable double negatives is
On Tue, Oct 24, 2017 at 01:11:07PM +0300, Jani Nikula wrote:
> On Tue, 24 Oct 2017, Dan Carpenter <dan.carpen...@oracle.com> wrote:
> > We accidentally inverted an if statement and turned amd_powerplay_reset()
> > into a no-op.
> >
> > Fixes: ae97988fc89e ("
F,
0x);
3769 mutex_unlock(>grbm_idx_mutex);
3770
3771 while (size) {
3772 uint32_t value;
3773
3774 value = data[offset++];
^^
We're possibly reading beyond the end of the ar
hole
function is a no-op? My Brian is melting???
1369 }
regards,
dan carpenter
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
plane_state->plane_size.video.luma_pitch = awidth;
regards,
dan carpenter
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
On Sat, Nov 04, 2017 at 10:16:23AM +0100, walter harms wrote:
>
>
> Am 04.11.2017 07:12, schrieb Dan Carpenter:
> > The if statement wasn't indented so it makes static analysis tools and
> > probably very recent GCC versions complain.
> >
> > Signed-
not really appropriate here so it should be removed
as well.
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
---
v2: in v1 I just added a tab
diff --git a/drivers/gpu/drm/amd/display/dc/dcn10/dcn10_resource.c
b/drivers/gpu/drm/amd/display/dc/dcn10/dcn10_resource.c
index d91159
selves because it scales better than relying on me to do it.
regards,
dan carpenter
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c:2224 amdgpu_device_init() warn:
'adev->rio_mem' was not released on error
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c:2395 amdgpu_device_init() warn:
'adev->rio_mem' was
backlight_device_register() never returns NULL, it returns error
pointers on error so the check here is wrong.
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c
We assign "v_init = asic_blank_start;" a few lines earlier so there is
no need to do it again inside the if statements. Also "v_init" is
unsigned so it can't be less than zero.
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff --git a/drivers/gp
EGIONS_NUMBER then we're reading beyond the end of the array
1697 regamma_params->arr_curve_points[k].segments_num =
1698 seg_distr[k];
1699
regards,
dan carpenter
___
amd-gfx mailin
spin_unlock_irqrestore(>dev->event_lock, flags);
^^
Double unlock.
3896
3897 if (!pflip_needed) {
regards,
dan carpenter
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
The if statement wasn't indented so it makes static analysis tools and
probably very recent GCC versions complain.
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
---
I went over 80 characters because other lines do already and it seemed
like the cleanest thing here.
diff --git a/d
x_vddc'.
drivers/gpu/drm/amd/amdgpu/../powerplay/smumgr/vegam_smumgr.c:1588
vegam_populate_clock_stretcher_data_table() error: uninitialized symbol 'efuse'.
drivers/gpu/drm/amd/amdgpu/../powerplay/smumgr/vegam_smumgr.c:1725
vegam_populate_avfs_parameters() erro
hecked dereference.
195 (hwmgr->feature_mask & PP_GFXOFF_MASK)) {
196 ret = hwmgr->hwmgr_func->gfx_off_control(hwmgr, true);
197 if (ret)
198 pr_err("gfx off enabling failed!\n");
199
3248 bw_fixed_to_int(bw_mul(data->
3249 stutter_entry_watermark[0],
bw_int_to_fixed(1000)));
See also:
drivers/gpu/drm/amd/amdgpu/../display/dc/calcs/dce_calcs.c:3356 bw_calcs()
warn: inconsistent indenting
regards,
dan carpenter
_
(uint16_t)(PPSMC_MSG_EnableDpmDidt));
970 PP_ASSERT_WITH_CODE((0 == result),
971 "Failed to enable DPM DIDT.",
return result);
972 }
973 mutex_unlock(>grb
We added some more lines of code to this if statement but forgot to add
curly braces.
Fixes: 0c24e7ef233b ("drm/amd/powerplay: add specific changes for VEGAM in
smu7_hwmgr.c")
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff --git a/drivers/gpu/drm/amd/powerplay/hw
you
don't have to look at the surrounding code to see whether debugfs is
enabled or not.
Signed-off-by: Dan Carpenter
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c
b/drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c
index f5fb93795a69..dd9a4fb9ce39 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_debu
fill in from actual raven resource when we create
1014 * more than virtual encoder
1015 */
regards,
dan carpenter
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
Hi Samuel,
Thank you for the patch! Perhaps something to improve:
[auto build test WARNING on drm/drm-next]
[also build test WARNING on v4.15-rc7 next-20180110]
[if your patch is applied to the wrong git tree, please drop us a note to help
improve the system]
url:
(ent->d_inode, adev->rmmio_size);
debugfs_create_file() returns ERR_PTR(-ENODEV) if it's not enabled in
the .config or it returns a NULL pointer.
697 adev->debugfs_regs[i] = ent;
698 }
699
700 ret
because pp_late_fini() frees the parameter. The
amdgpu_pp_late_fini() function doesn't so that's a bit weird.
1504 adev->ip_blocks[i].status.late_initialized = false;
^^^
Dereference.
1505 }
1506
regards,
dan carpenter
_
76
);
677
678 break;
regards,
dan carpenter
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
The if statement isn't indented and it makes static checkers complain.
Signed-off-by: Dan Carpenter
diff --git a/drivers/gpu/drm/amd/display/dc/core/dc_resource.c
b/drivers/gpu/drm/amd/display/dc/core/dc_resource.c
index 4ca41d6e3bcf..d82ba58c720f 100644
--- a/drivers/gpu/drm/amd/display/dc
ist array after the list")
Signed-off-by: Dan Carpenter
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_bo_list.c
b/drivers/gpu/drm/amd/amdgpu/amdgpu_bo_list.c
index d472a2c8399f..b80243d3972e 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_bo_list.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_bo_l
speed_cntl |= LC_INITIATE_LINK_SPEED_CHANGE;
9651 WREG32_PCIE_PORT(PCIE_LC_SPEED_CNTL, speed_cntl);
9652
9653 for (i = 0; i < rdev->usec_timeout; i++) {
9654 speed_cntl = RREG32_PCIE_PORT(PCIE_LC_SPEED_CNTL);
9655 if ((speed
The ->info[] array has DAL_IRQ_SOURCES_NUMBER elements so this condition
should be >= instead of > or we could read one element beyond the end of
the array.
Fixes: 4562236b3bc0 ("drm/amd/dc: Add dc display driver (v2)")
Signed-off-by: Dan Carpenter
diff --git a/drivers/gpu
i++;
541 }
542
543 if (seg_distr[k] != -1)
^^
then this would be a problem.
544 lut_params->arr_curve_points[k].segments_num =
seg_distr[k];
545
regards,
dan carpenter
___
amd-g
return -EINVAL;
4830 }
4831 }
4832 return 0;
4833 }
regards,
dan carpenter
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
his.
>
> It's complex to have to remember the preferences for every subsystem.
> Preferences should be expressed in the MAINTAINERS file in some way.
> Also, since no one reads lkml, does it hurt to have even trivial patches?
I always tell people not to CC lkml when there
e should be using table->entries[0] here?
1487 return 0;
1488 }
1489 }
1490 return -EINVAL;
1491 }
regards,
dan carpenter
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
for this to be bigger than the number of GPUs in the system. The
> maximum number of GPUs supported due to device minor limit in DRM is 128.
>
128 is sort of a magic number. Is there a MAX_GPU define or something?
regards,
dan carpenter
___
a
args->n_devices is a u32 that comes from the user. The multiplication
could overflow on 32 bit systems possibly leading to privilege
escalation.
Fixes: 5ec7e02854b3 ("drm/amdkfd: Add ioctls for GPUVM memory management")
Signed-off-by: Dan Carpenter dan.carpen...@oracle.com>
diff
This has a static checker warning because "frev" and "crev" can be
uninitialized if "info" is NULL. I just changed the order of the checks
so that we check "info" first.
Signed-off-by: Dan Carpenter <dan.carpen...@oracle.com>
diff --git a/drive
c->crtc_id;
321
322 drm_handle_vblank(adev->ddev, crtc_index);
323 amdgpu_dm_crtc_handle_crc_irq(>base);
^^^
The new code dereferences without checking (inside the function call).
324 }
325
reg
t;)
Signed-off-by: Dan Carpenter
diff --git a/drivers/gpu/drm/amd/display/dc/dce110/dce110_compressor.c
b/drivers/gpu/drm/amd/display/dc/dce110/dce110_compressor.c
index e2994d337044..8e83ec66fd22 100644
--- a/drivers/gpu/drm/amd/display/dc/dce110/dce110_compressor.c
+++ b/drivers/gpu/drm/amd/
ms->asic_id);
676 if (!dc->res_pool)
677 goto fail;
678
679 dc_resource_state_construct(dc, dc->current_state);
680
681 if (!create_links(dc, init_params->num_virtual_links))
682 goto fail;
683
num_plane].surface->dst_rect =
5196
new_dm_plane_state->dc_state->dst_rect;
5197
updates[num_plane].surface->rotation =
regards,
dan carpenter
___
amd-gfx mailing list
amd-gfx@lists.free
The debugfs_create_file() returns error pointers if DEBUGFS isn't
enabled. But here, we know that it is enabled so it returns NULL on
error which could lead to a NULL dereference a few lines later.
Signed-off-by: Dan Carpenter
---
If someone wanted to delete the error handling as well
^
The old code didn't check.
1464 // if otg funcs defined check
if blanked before programming
1465 if
(!pipe_ctx->stream_res.tg->funcs->is_blanke
Hi Lyude,
Thank you for the patch! Perhaps something to improve:
url:
https://github.com/0day-ci/linux/commits/Lyude-Paul/Fix-legacy-DPMS-changes-with-MST/20180919-203434
base: git://anongit.freedesktop.org/drm-intel for-linux-next
smatch warnings:
truct kgd_mem **),
,
1646NULL);
1647 if (r)
1648 goto err_unlock;
regards,
dan carpenter
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
_params->max_content == 0 ||
^
Too late.
827 fs_params->max_display == 0)
828 return false;
regards,
dan carpenter
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.or
fails.
50 return 0;
51 }
regards,
dan carpenter
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
137 }
138
139 list_for_each_entry(tmp_adev, >device_list,
gmc.xgmi.head) {
140 ret = amdgpu_xgmi_update_topology(hive, tmp_adev);
141 if (ret)
142 break;
143 }
144
rrent_state" gets dereferenced inside the function. This style
of one function cleans up everything error handling is always buggy...
:/
https://plus.google.com/u/0/106378716002406849458/posts/1Ud9JbaYnPr
755 return false;
756 }
regards,
dan carpenter
_
On Thu, Mar 21, 2019 at 09:20:38AM +0100, Julia Lawall wrote:
>
>
> On Thu, 21 Mar 2019, Huang, Ray wrote:
>
> > > -Original Message-
> > > From: Dan Carpenter [mailto:dan.carpen...@oracle.com]
> > > Sent: Thursday, March 21, 2019 2:28 PM
> >
We already unlocked a few lines earlier so this code unlocks twice on
the success path.
Fixes: 5809d7420f97 ("drm/amd/powerplay: implement sysfs of pp_table for smu11
(v2)")
Signed-off-by: Dan Carpenter
---
I'm not sure what this bug looks like at runtime, but it's slightly
weird t
The "size" variable is unsigned. We never pass invalid sizes to this
function and we already used it as an array offset earlier so it's
too late to check here.
Signed-off-by: Dan Carpenter
---
drivers/gpu/drm/amd/powerplay/smu_v11_0.c | 3 ---
1 file changed, 3 deletions(-)
The > should be >= so that we don't read one element beyond the end of
the vega20_message_map[] array.
Fixes: 3ec3c931489f ("drm/amd/powerplay: implement smu vega20_message_map for
vega20")
Signed-off-by: Dan Carpenter
---
drivers/gpu/drm/amd/powerplay/vega20_ppt.c | 3 ++-
1
New check
551 return;
552
553 if (link_stream)
^^^
The old code used to check for NULL
554 decide_link_settings(link_stream, _settings);
555
regards,
dan carpenter
_
us_to_vupdate = lines_to_vupdate * us_per_line;
222
223 /* 70 us is a conservative estimate of cursor update
time*/
224 if (us_to_vupdate < 70)
225 udelay(us_to_vupdate);
226 }
4851 mutex_unlock(>dc_lock);
4852 }
4853
4854 if (planes_count) {
regards,
dan carpenter
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
^^
amdgpu_lockup_timeout is an int and I'm not sure if that's what you
want to test. MAX_SCHEDULE_TIMEOUT is LONG_MAX.
271 amdgpu_device_gpu_recover(adev, NULL);
272 }
regards,
dan carpenter
___
amd-gfx mailing list
|| pages <= 0)
Check
1216 return 0;
1217
regards,
dan carpenter
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
dm,
regards,
dan carpenter
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
^
Can link_stream be NULL?
2927 return;
2928
2929 if (link_stream)
^^^
We check here so maybe?
2930 decide_link_settings(link_stream, _settings);
2931
regards,
dan carpenter
__
ife, because debugfs is
generally root only.
Fixes: 36ea1bd2d084 ("drm/amdgpu: add debugfs ctrl node")
Signed-off-by: Dan Carpenter
---
drivers/gpu/drm/amd/amdgpu/amdgpu_ras.h | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_ras.h
b/drivers/gpu/drm
ders, because people naturally assume it
is not dead.
GCC has a feature to warn about uninitialized variables and we're
randomly initializing status to a bogus value to disable static
analysis...
regards,
dan carpenter
_6_MAX_COUNTERS);
You're resending this for other reasons, but don't forget to update the
indenting on the arguments so they still line up with the '('.
regards,
dan carpenter
that with comments. I'll try to address this in
> a coming patch.
>
Part of the reason for error handling is just to silence static checker
warnings because otherwise everyone has to review it to see if the
resource leaks are important. It's easier in the long run to just fix
everything
On Sat, Jun 22, 2019 at 01:43:19PM +0300, Dan Carpenter wrote:
> On Sat, Jun 22, 2019 at 11:03:14AM +0800, Mao Wenan wrote:
> > diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_pmu.c
> > b/drivers/gpu/drm/amd/amdgpu/amdgpu_pmu.c
> > index 0e6dba9..0bf4dd9 100644
> > --- a
ve to pull the arguments back
as well. I think this fix that Julia suggested is really the right so
leave the indenting alone.
It looks like you've right aligned the arguments. That's not the right
way, the original was correct.
regards,
dan carpenter
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
On Mon, Jun 24, 2019 at 05:29:33PM +0800, maowenan wrote:
>
>
> On 2019/6/24 16:39, Dan Carpenter wrote:
> > On Mon, Jun 24, 2019 at 11:45:32AM +0800, Mao Wenan wrote:
> >> There is one warning:
> >> drivers/gpu/drm/amd/amdgpu/amdgpu_pmu.c: In function ‘amdgpu_pm
quot;,
316 (int)process->lead_thread->pid);
Error handling and error code missing.
317 }
318 out:
319 mutex_unlock(_processes_mutex);
320
321 return process;
322 }
regards,
dan carpenter
___
gt; - if (ret)
> - return ret;
> + return -EINVAL;
From a naive reading of the code without knowing the hardware spec then
you would probably think that lo_base_addr can also be uninitialized.
regards,
dan carpenter
_
There is a typo so the code unlocks twice instead of taking the lock and
then releasing it.
Fixes: f14a323db5b0 ("drm/amd/powerplay: implement update enabled feature state
to smc for smu11")
Signed-off-by: Dan Carpenter
---
drivers/gpu/drm/amd/powerplay/amdgpu_smu.c | 2 +-
1 file
buffer before
flip\n");
5350
5351 amdgpu_bo_get_tiling_flags(abo, _flags);
5352
5353 amdgpu_bo_unreserve(abo);
regards,
dan carpenter
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
if (u->plane_info)
1491 format = u->plane_info->format;
1492 else if (u->surface)
^^
But the old code assumed it could be NULL
1493 format
On Tue, Apr 23, 2019 at 02:16:53PM +, Kazlauskas, Nicholas wrote:
> On 4/23/19 10:10 AM, Dan Carpenter wrote:
> > Hello David Francis,
> >
> > This is a semi-automatic email about new static checker warnings.
> >
> > The patch c238bfe0be9e: "drm/a
stly pointing this out because that NULL
check is written so higgledy-piggledy. At first I thought this was
staging code so I was planning to ignore the patch. :P
regards,
dan carpenter
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
0 if (!dc->clk_mgr->funcs->get_clock)
^
This will oops if ->clk_mgr is NULL
3231 return DC_FAIL_UNSUPPORTED_1;
3232
regards,
dan carpenter
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
lay_table_size = size;
400
401 return 0;
regards,
dan carpenter
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
1 - 100 of 344 matches
Mail list logo