Commit bdb21167 authored by Zefan Li's avatar Zefan Li

Revert "drm/radeon: Use drm_calloc_ab for CS relocs"

This reverts commit 961bd135.

Both Satoshi-san and Cal reported a kernel crash due to this commit.
Reported-by: default avatarSatoshi Iwamoto <satoshi.iwamoto@nifty.ne.jp>
Reported-by: default avatarCal Peake <cp@absolutedigital.net>
Signed-off-by: default avatarZefan Li <lizefan@huawei.com>
parent a0b13721
......@@ -49,7 +49,7 @@ int radeon_cs_parser_relocs(struct radeon_cs_parser *p)
if (p->relocs_ptr == NULL) {
return -ENOMEM;
}
p->relocs = drm_calloc_large(p->nrelocs, sizeof(struct radeon_bo_list));
p->relocs = kcalloc(p->nrelocs, sizeof(struct radeon_cs_reloc), GFP_KERNEL);
if (p->relocs == NULL) {
return -ENOMEM;
}
......@@ -324,7 +324,7 @@ static void radeon_cs_parser_fini(struct radeon_cs_parser *parser, int error)
}
}
kfree(parser->track);
drm_free_large(parser->relocs);
kfree(parser->relocs);
kfree(parser->relocs_ptr);
for (i = 0; i < parser->nchunks; i++) {
kfree(parser->chunks[i].kdata);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment