Thread (7 messages) 7 messages, 5 authors, 2011-06-02

Re: [TRIVIAL PATCH next 12/15] video: Convert vmalloc/memset to vzalloc

From: Heiko Stübner <heiko@sntech.de>
Date: 2011-05-28 17:48:35
Also in: lkml, xen-devel

Am Samstag 28 Mai 2011, 19:36:32 schrieb Joe Perches:
quoted hunk ↗ jump to hunk
diff --git a/drivers/video/arcfb.c b/drivers/video/arcfb.c
index 3ec4923..86573e2 100644
--- a/drivers/video/arcfb.c
+++ b/drivers/video/arcfb.c
@@ -515,11 +515,10 @@ static int __devinit arcfb_probe(struct
platform_device *dev)

 	/* We need a flat backing store for the Arc's
 	   less-flat actual paged framebuffer */
-	if (!(videomemory = vmalloc(videomemorysize)))
+	videomemory = vmalloc(videomemorysize);
+	if (!videomemory)
 		return retval;
shouldn't this be vzalloc too?
-	memset(videomemory, 0, videomemorysize);
-
 	info = framebuffer_alloc(sizeof(struct arcfb_par), &dev->dev);
 	if (!info)
 		goto err;

Heiko
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help