aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/char/drm/drmP.h
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/char/drm/drmP.h')
-rw-r--r--drivers/char/drm/drmP.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/drivers/char/drm/drmP.h b/drivers/char/drm/drmP.h
index b04ddf12a0ff..2c7b1fc3bb2e 100644
--- a/drivers/char/drm/drmP.h
+++ b/drivers/char/drm/drmP.h
@@ -806,7 +806,6 @@ extern ssize_t drm_read(struct file *filp, char __user *buf, size_t count,
806extern void drm_mem_init(void); 806extern void drm_mem_init(void);
807extern int drm_mem_info(char *buf, char **start, off_t offset, 807extern int drm_mem_info(char *buf, char **start, off_t offset,
808 int request, int *eof, void *data); 808 int request, int *eof, void *data);
809extern void *drm_calloc(size_t nmemb, size_t size, int area);
810extern void *drm_realloc(void *oldpt, size_t oldsize, size_t size, 809extern void *drm_realloc(void *oldpt, size_t oldsize, size_t size,
811 int area); 810 int area);
812extern unsigned long drm_alloc_pages(int order, int area); 811extern unsigned long drm_alloc_pages(int order, int area);
@@ -1064,9 +1063,16 @@ static __inline__ void drm_free(void *pt, size_t size, int area)
1064{ 1063{
1065 kfree(pt); 1064 kfree(pt);
1066} 1065}
1066
1067/** Wrapper around kcalloc() */
1068static __inline__ void *drm_calloc(size_t nmemb, size_t size, int area)
1069{
1070 return kcalloc(nmemb, size, GFP_KERNEL);
1071}
1067#else 1072#else
1068extern void *drm_alloc(size_t size, int area); 1073extern void *drm_alloc(size_t size, int area);
1069extern void drm_free(void *pt, size_t size, int area); 1074extern void drm_free(void *pt, size_t size, int area);
1075extern void *drm_calloc(size_t nmemb, size_t size, int area);
1070#endif 1076#endif
1071 1077
1072/*@}*/ 1078/*@}*/