diff options
author | David Herrmann <dh.herrmann@gmail.com> | 2013-10-20 12:55:42 -0400 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2013-11-05 23:53:23 -0500 |
commit | a99ee459fd0ae38c0ccc7f93af718ef476657d1b (patch) | |
tree | f398913f175ccd379eb950d3b65a36896c6cd690 | |
parent | 4ac387f516bd3e5356cdb25266e244fa8a062281 (diff) |
drm: make drm_get_minor() static
drm_get_minor() is only used in one file. Make it static and add a
kernel-doc comment which documents the current semantics.
Signed-off-by: David Herrmann <dh.herrmann@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
-rw-r--r-- | drivers/gpu/drm/drm_stub.c | 19 | ||||
-rw-r--r-- | include/drm/drmP.h | 1 |
2 files changed, 11 insertions, 9 deletions
diff --git a/drivers/gpu/drm/drm_stub.c b/drivers/gpu/drm/drm_stub.c index dd0cb02830f4..76b4d718af60 100644 --- a/drivers/gpu/drm/drm_stub.c +++ b/drivers/gpu/drm/drm_stub.c | |||
@@ -255,16 +255,20 @@ int drm_dropmaster_ioctl(struct drm_device *dev, void *data, | |||
255 | } | 255 | } |
256 | 256 | ||
257 | /** | 257 | /** |
258 | * Get a secondary minor number. | 258 | * drm_get_minor - Allocate and register new DRM minor |
259 | * @dev: DRM device | ||
260 | * @minor: Pointer to where new minor is stored | ||
261 | * @type: Type of minor | ||
259 | * | 262 | * |
260 | * \param dev device data structure | 263 | * Allocate a new minor of the given type and register it. A pointer to the new |
261 | * \param sec-minor structure to hold the assigned minor | 264 | * minor is returned in @minor. |
262 | * \return negative number on failure. | 265 | * Caller must hold the global DRM mutex. |
263 | * | 266 | * |
264 | * Search an empty entry and initialize it to the given parameters. This | 267 | * RETURNS: |
265 | * routines assigns minor numbers to secondary heads of multi-headed cards | 268 | * 0 on success, negative error code on failure. |
266 | */ | 269 | */ |
267 | int drm_get_minor(struct drm_device *dev, struct drm_minor **minor, int type) | 270 | static int drm_get_minor(struct drm_device *dev, struct drm_minor **minor, |
271 | int type) | ||
268 | { | 272 | { |
269 | struct drm_minor *new_minor; | 273 | struct drm_minor *new_minor; |
270 | int ret; | 274 | int ret; |
@@ -321,7 +325,6 @@ err_idr: | |||
321 | *minor = NULL; | 325 | *minor = NULL; |
322 | return ret; | 326 | return ret; |
323 | } | 327 | } |
324 | EXPORT_SYMBOL(drm_get_minor); | ||
325 | 328 | ||
326 | /** | 329 | /** |
327 | * drm_unplug_minor - Unplug DRM minor | 330 | * drm_unplug_minor - Unplug DRM minor |
diff --git a/include/drm/drmP.h b/include/drm/drmP.h index 62da57e914f8..1d4a920ef7ff 100644 --- a/include/drm/drmP.h +++ b/include/drm/drmP.h | |||
@@ -1630,7 +1630,6 @@ struct drm_device *drm_dev_alloc(struct drm_driver *driver, | |||
1630 | void drm_dev_free(struct drm_device *dev); | 1630 | void drm_dev_free(struct drm_device *dev); |
1631 | int drm_dev_register(struct drm_device *dev, unsigned long flags); | 1631 | int drm_dev_register(struct drm_device *dev, unsigned long flags); |
1632 | void drm_dev_unregister(struct drm_device *dev); | 1632 | void drm_dev_unregister(struct drm_device *dev); |
1633 | int drm_get_minor(struct drm_device *dev, struct drm_minor **minor, int type); | ||
1634 | /*@}*/ | 1633 | /*@}*/ |
1635 | 1634 | ||
1636 | /* PCI section */ | 1635 | /* PCI section */ |