提交 b369839b 编写于 作者: R Rob Clark 提交者: Greg Kroah-Hartman

staging: drm/omap: allocation fail check

Signed-off-by: NRob Clark <rob@ti.com>
Signed-off-by: NGreg Kroah-Hartman <gregkh@suse.de>
上级 16772a49
......@@ -1094,6 +1094,10 @@ void omap_gem_init(struct drm_device *dev)
}
usergart = kzalloc(3 * sizeof(*usergart), GFP_KERNEL);
if (!usergart) {
dev_warn(dev->dev, "could not allocate usergart\n");
return;
}
/* reserve 4k aligned/wide regions for userspace mappings: */
for (i = 0; i < ARRAY_SIZE(fmts); i++) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册