浏览代码

drm: small cleanups

This patch contains the following small cleanups:
- make two needlessly global functions static
- drm_sysfs.c: every file should #include the header with the prototypes
              of the global functions it is offering

Signed-off-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: Dave Airlie <airlied@linux.ie>
Dave Airlie 19 年之前
父节点
当前提交
f210973bb6
共有 3 个文件被更改,包括 3 次插入2 次删除
  1. 1 1
      drivers/char/drm/drm_bufs.c
  2. 1 1
      drivers/char/drm/drm_context.c
  3. 1 0
      drivers/char/drm/drm_sysfs.c

+ 1 - 1
drivers/char/drm/drm_bufs.c

@@ -1041,7 +1041,7 @@ static int drm_addbufs_sg(drm_device_t *dev, drm_buf_desc_t *request)
 	return 0;
 }
 
-int drm_addbufs_fb(drm_device_t *dev, drm_buf_desc_t *request)
+static int drm_addbufs_fb(drm_device_t *dev, drm_buf_desc_t *request)
 {
 	drm_device_dma_t *dma = dev->dma;
 	drm_buf_entry_t *entry;

+ 1 - 1
drivers/char/drm/drm_context.c

@@ -308,7 +308,7 @@ found:
  *
  * Attempt to set drm_device::context_flag.
  */
-int drm_context_switch( drm_device_t *dev, int old, int new )
+static int drm_context_switch( drm_device_t *dev, int old, int new )
 {
         if ( test_and_set_bit( 0, &dev->context_flag ) ) {
                 DRM_ERROR( "Reentering -- FIXME\n" );

+ 1 - 0
drivers/char/drm/drm_sysfs.c

@@ -17,6 +17,7 @@
 #include <linux/err.h>
 
 #include "drm_core.h"
+#include "drmP.h"
 
 struct drm_sysfs_class {
 	struct class_device_attribute attr;