drm/nouveau/gem: use kvfree() in u_free()
authorPekka Enberg <penberg@kernel.org>
Tue, 30 Jun 2015 21:59:18 +0000 (14:59 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Wed, 1 Jul 2015 02:44:59 +0000 (19:44 -0700)
Use kvfree() instead of open-coding it.

Signed-off-by: Pekka Enberg <penberg@kernel.org>
Cc: David Airlie <airlied@linux.ie>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
drivers/gpu/drm/nouveau/nouveau_gem.c

index 0e690bf19fc9c5d04d2fdab02df59a4eeddd3a2b..af1ee517f372212af7b432e13fa39d0490075b35 100644 (file)
@@ -555,10 +555,7 @@ nouveau_gem_pushbuf_validate(struct nouveau_channel *chan,
 static inline void
 u_free(void *addr)
 {
-       if (!is_vmalloc_addr(addr))
-               kfree(addr);
-       else
-               vfree(addr);
+       kvfree(addr);
 }
 
 static inline void *