提交 ce067913 编写于 作者: D Dan Carpenter 提交者: Dave Airlie

drm/radeon: check kmalloc() for failures

We can just return -ENOMEM here if the allocation fails.
Signed-off-by: NDan Carpenter <dan.carpenter@oracle.com>
Reviewed-by: NMichel Dänzer <michel.daenzer@amd.com>
Signed-off-by: NDave Airlie <airlied@redhat.com>
上级 bffd9de0
......@@ -2008,6 +2008,8 @@ int r100_cs_parse(struct radeon_cs_parser *p)
int r;
track = kzalloc(sizeof(*track), GFP_KERNEL);
if (!track)
return -ENOMEM;
r100_cs_track_clear(p->rdev, track);
p->track = track;
do {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册