diff options
author | Zefan Li <lizefan@huawei.com> | 2015-10-11 16:03:09 +0800 |
---|---|---|
committer | Zefan Li <lizefan@huawei.com> | 2015-10-22 09:20:07 +0800 |
commit | bdb211672fec45cbf48de2b1acddae8fb1924ef1 (patch) | |
tree | 58586fb5bd50e435e8e24b64dbfb8cee5c4bd2ef | |
parent | a0b13721e2df7d316080520fb870464ed0a3ce14 (diff) | |
download | lwn-bdb211672fec45cbf48de2b1acddae8fb1924ef1.tar.gz lwn-bdb211672fec45cbf48de2b1acddae8fb1924ef1.zip |
Revert "drm/radeon: Use drm_calloc_ab for CS relocs"
This reverts commit 961bd13539b9e7ca5d2e667668141496b7a1d6bc.
Both Satoshi-san and Cal reported a kernel crash due to this commit.
Reported-by: Satoshi Iwamoto <satoshi.iwamoto@nifty.ne.jp>
Reported-by: Cal Peake <cp@absolutedigital.net>
Signed-off-by: Zefan Li <lizefan@huawei.com>
-rw-r--r-- | drivers/gpu/drm/radeon/radeon_cs.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/gpu/drm/radeon/radeon_cs.c b/drivers/gpu/drm/radeon/radeon_cs.c index d66d2cdf4f0a..f3ee36036487 100644 --- a/drivers/gpu/drm/radeon/radeon_cs.c +++ b/drivers/gpu/drm/radeon/radeon_cs.c @@ -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); |