[PATCH] drm/amd/pm: use kmemdup() rather than kmalloc+memcpy

2020-08-24 Thread Alex Dewar
Issue identified with Coccinelle. Signed-off-by: Alex Dewar --- .../drm/amd/pm/powerplay/hwmgr/vega20_processpptables.c | 8 +++- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/drivers/gpu/drm/amd/pm/powerplay/hwmgr/vega20_processpptables.c b/drivers/gpu/drm/amd/pm

[PATCH] drm/amd/pm: Remove unnecessary cast

2020-08-20 Thread Alex Dewar
In init_powerplay_table_information() the value returned from kmalloc() is cast unnecessarily. Remove cast. Issue identified with Coccinelle. Signed-off-by: Alex Dewar --- drivers/gpu/drm/amd/pm/powerplay/hwmgr/vega12_processpptables.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion