提交 288db882 编写于 作者: J Jesper Juhl 提交者: Jiri Kosina

GPU DRM: Remove unnecessary casts of void ptr returning alloc function return values

The [vk][cmz]alloc(_node) family of functions return void pointers which
it's completely unnecessary/pointless to cast to other pointer types since
that happens implicitly.

This patch removes such casts from drivers/gpu/drm/
Signed-off-by: NJesper Juhl <jj@chaosbits.net>
Signed-off-by: NJiri Kosina <jkosina@suse.cz>
上级 c5e0591a
......@@ -59,9 +59,7 @@ drm_sman_init(struct drm_sman * sman, unsigned int num_managers,
{
int ret = 0;
sman->mm = (struct drm_sman_mm *) kcalloc(num_managers,
sizeof(*sman->mm),
GFP_KERNEL);
sman->mm = kcalloc(num_managers, sizeof(*sman->mm), GFP_KERNEL);
if (!sman->mm) {
ret = -ENOMEM;
goto out;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册