Skip to content
Commit bada22d0 authored by Georgiana Chelu's avatar Georgiana Chelu Committed by Alex Deucher
Browse files

drm/amd/powerplay: Don't cast kzalloc() return value



The kzalloc function returns a void pointer and the assignment
operator converts it to the type of pointer it is assigned to.
Therefore, there is no need to cast.

Issue found by alloc_cast.cocci:
* WARNING: casting value returned by memory allocation function
to <struct type> is useless.

Path to the cocci script: scripts/coccinelle/api/alloc/alloc_cast.cocci

Signed-off-by: default avatarGeorgiana Chelu <georgiana.chelu93@gmail.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent d2d7cc33
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment