Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

drm/client: Rename drm_client_add() to drm_client_register()

This is done to stay consistent with our naming scheme of
_register() = others can start calling us from any thread.

Suggested-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Noralf Trønnes <noralf@tronnes.org>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Link: https://patchwork.freedesktop.org/patch/msgid/20190403125658.32389-1-noralf@tronnes.org

+8 -7
+6 -5
drivers/gpu/drm/drm_client.c
··· 69 69 * @name: Client name 70 70 * @funcs: DRM client functions (optional) 71 71 * 72 - * This initialises the client and opens a &drm_file. Use drm_client_add() to complete the process. 72 + * This initialises the client and opens a &drm_file. 73 + * Use drm_client_register() to complete the process. 73 74 * The caller needs to hold a reference on @dev before calling this function. 74 75 * The client is freed when the &drm_device is unregistered. See drm_client_release(). 75 76 * ··· 109 108 EXPORT_SYMBOL(drm_client_init); 110 109 111 110 /** 112 - * drm_client_add - Add client to the device list 111 + * drm_client_register - Register client 113 112 * @client: DRM client 114 113 * 115 114 * Add the client to the &drm_device client list to activate its callbacks. 116 115 * @client must be initialized by a call to drm_client_init(). After 117 - * drm_client_add() it is no longer permissible to call drm_client_release() 116 + * drm_client_register() it is no longer permissible to call drm_client_release() 118 117 * directly (outside the unregister callback), instead cleanup will happen 119 118 * automatically on driver unload. 120 119 */ 121 - void drm_client_add(struct drm_client_dev *client) 120 + void drm_client_register(struct drm_client_dev *client) 122 121 { 123 122 struct drm_device *dev = client->dev; 124 123 ··· 126 125 list_add(&client->list, &dev->clientlist); 127 126 mutex_unlock(&dev->clientlist_mutex); 128 127 } 129 - EXPORT_SYMBOL(drm_client_add); 128 + EXPORT_SYMBOL(drm_client_register); 130 129 131 130 /** 132 131 * drm_client_release - Release DRM client resources
+1 -1
drivers/gpu/drm/drm_fb_helper.c
··· 3322 3322 if (ret) 3323 3323 DRM_DEV_DEBUG(dev->dev, "client hotplug ret=%d\n", ret); 3324 3324 3325 - drm_client_add(&fb_helper->client); 3325 + drm_client_register(&fb_helper->client); 3326 3326 3327 3327 return 0; 3328 3328 }
+1 -1
include/drm/drm_client.h
··· 90 90 int drm_client_init(struct drm_device *dev, struct drm_client_dev *client, 91 91 const char *name, const struct drm_client_funcs *funcs); 92 92 void drm_client_release(struct drm_client_dev *client); 93 - void drm_client_add(struct drm_client_dev *client); 93 + void drm_client_register(struct drm_client_dev *client); 94 94 95 95 void drm_client_dev_unregister(struct drm_device *dev); 96 96 void drm_client_dev_hotplug(struct drm_device *dev);