Lines Matching defs:dev
13 typedef void (*drmres_release_t)(struct drm_device *dev, void *res);
17 * @dev: DRM device
18 * @action: function which should be called when @dev is released
22 * list of cleanup actions for @dev. The cleanup actions will be run in reverse
23 * order in the final drm_dev_put() call for @dev.
25 #define drmm_add_action(dev, action, data) \
26 __drmm_add_action(dev, action, data, #action)
28 int __must_check __drmm_add_action(struct drm_device *dev,
34 * @dev: DRM device
35 * @action: function which should be called when @dev is released
41 #define drmm_add_action_or_reset(dev, action, data) \
42 __drmm_add_action_or_reset(dev, action, data, #action)
44 int __must_check __drmm_add_action_or_reset(struct drm_device *dev,
48 void *drmm_kmalloc(struct drm_device *dev, size_t size, gfp_t gfp) __malloc;
52 * @dev: DRM device
60 static inline void *drmm_kzalloc(struct drm_device *dev, size_t size, gfp_t gfp)
62 return drmm_kmalloc(dev, size, gfp | __GFP_ZERO);
67 * @dev: DRM device
76 static inline void *drmm_kmalloc_array(struct drm_device *dev,
84 return drmm_kmalloc(dev, bytes, flags);
89 * @dev: DRM device
98 static inline void *drmm_kcalloc(struct drm_device *dev,
101 return drmm_kmalloc_array(dev, n, size, flags | __GFP_ZERO);
104 char *drmm_kstrdup(struct drm_device *dev, const char *s, gfp_t gfp);
106 void drmm_kfree(struct drm_device *dev, void *data);
108 void __drmm_mutex_release(struct drm_device *dev, void *res);
112 * @dev: DRM device
121 #define drmm_mutex_init(dev, lock) ({ \
123 drmm_add_action_or_reset(dev, __drmm_mutex_release, lock); \