diff options
Diffstat (limited to 'drivers/gpu')
-rw-r--r-- | drivers/gpu/drm/radeon/radeon_drv.c | 5 | ||||
-rw-r--r-- | drivers/gpu/drm/radeon/radeon_kms.c | 49 |
2 files changed, 0 insertions, 54 deletions
diff --git a/drivers/gpu/drm/radeon/radeon_drv.c b/drivers/gpu/drm/radeon/radeon_drv.c index 50fce498910c..7f50fb864af8 100644 --- a/drivers/gpu/drm/radeon/radeon_drv.c +++ b/drivers/gpu/drm/radeon/radeon_drv.c | |||
@@ -62,9 +62,6 @@ void radeon_driver_irq_preinstall_kms(struct drm_device *dev); | |||
62 | int radeon_driver_irq_postinstall_kms(struct drm_device *dev); | 62 | int radeon_driver_irq_postinstall_kms(struct drm_device *dev); |
63 | void radeon_driver_irq_uninstall_kms(struct drm_device *dev); | 63 | void radeon_driver_irq_uninstall_kms(struct drm_device *dev); |
64 | irqreturn_t radeon_driver_irq_handler_kms(DRM_IRQ_ARGS); | 64 | irqreturn_t radeon_driver_irq_handler_kms(DRM_IRQ_ARGS); |
65 | int radeon_master_create_kms(struct drm_device *dev, struct drm_master *master); | ||
66 | void radeon_master_destroy_kms(struct drm_device *dev, | ||
67 | struct drm_master *master); | ||
68 | int radeon_dma_ioctl_kms(struct drm_device *dev, void *data, | 65 | int radeon_dma_ioctl_kms(struct drm_device *dev, void *data, |
69 | struct drm_file *file_priv); | 66 | struct drm_file *file_priv); |
70 | int radeon_gem_object_init(struct drm_gem_object *obj); | 67 | int radeon_gem_object_init(struct drm_gem_object *obj); |
@@ -260,8 +257,6 @@ static struct drm_driver kms_driver = { | |||
260 | .get_vblank_counter = radeon_get_vblank_counter_kms, | 257 | .get_vblank_counter = radeon_get_vblank_counter_kms, |
261 | .enable_vblank = radeon_enable_vblank_kms, | 258 | .enable_vblank = radeon_enable_vblank_kms, |
262 | .disable_vblank = radeon_disable_vblank_kms, | 259 | .disable_vblank = radeon_disable_vblank_kms, |
263 | .master_create = radeon_master_create_kms, | ||
264 | .master_destroy = radeon_master_destroy_kms, | ||
265 | #if defined(CONFIG_DEBUG_FS) | 260 | #if defined(CONFIG_DEBUG_FS) |
266 | .debugfs_init = radeon_debugfs_init, | 261 | .debugfs_init = radeon_debugfs_init, |
267 | .debugfs_cleanup = radeon_debugfs_cleanup, | 262 | .debugfs_cleanup = radeon_debugfs_cleanup, |
diff --git a/drivers/gpu/drm/radeon/radeon_kms.c b/drivers/gpu/drm/radeon/radeon_kms.c index 709bd892b3a9..ba128621057a 100644 --- a/drivers/gpu/drm/radeon/radeon_kms.c +++ b/drivers/gpu/drm/radeon/radeon_kms.c | |||
@@ -201,55 +201,6 @@ void radeon_disable_vblank_kms(struct drm_device *dev, int crtc) | |||
201 | 201 | ||
202 | 202 | ||
203 | /* | 203 | /* |
204 | * For multiple master (like multiple X). | ||
205 | */ | ||
206 | struct drm_radeon_master_private { | ||
207 | drm_local_map_t *sarea; | ||
208 | drm_radeon_sarea_t *sarea_priv; | ||
209 | }; | ||
210 | |||
211 | int radeon_master_create_kms(struct drm_device *dev, struct drm_master *master) | ||
212 | { | ||
213 | struct drm_radeon_master_private *master_priv; | ||
214 | unsigned long sareapage; | ||
215 | int ret; | ||
216 | |||
217 | master_priv = kzalloc(sizeof(*master_priv), GFP_KERNEL); | ||
218 | if (master_priv == NULL) { | ||
219 | return -ENOMEM; | ||
220 | } | ||
221 | /* prebuild the SAREA */ | ||
222 | sareapage = max_t(unsigned long, SAREA_MAX, PAGE_SIZE); | ||
223 | ret = drm_addmap(dev, 0, sareapage, _DRM_SHM, | ||
224 | _DRM_CONTAINS_LOCK, | ||
225 | &master_priv->sarea); | ||
226 | if (ret) { | ||
227 | DRM_ERROR("SAREA setup failed\n"); | ||
228 | return ret; | ||
229 | } | ||
230 | master_priv->sarea_priv = master_priv->sarea->handle + sizeof(struct drm_sarea); | ||
231 | master_priv->sarea_priv->pfCurrentPage = 0; | ||
232 | master->driver_priv = master_priv; | ||
233 | return 0; | ||
234 | } | ||
235 | |||
236 | void radeon_master_destroy_kms(struct drm_device *dev, | ||
237 | struct drm_master *master) | ||
238 | { | ||
239 | struct drm_radeon_master_private *master_priv = master->driver_priv; | ||
240 | |||
241 | if (master_priv == NULL) { | ||
242 | return; | ||
243 | } | ||
244 | if (master_priv->sarea) { | ||
245 | drm_rmmap_locked(dev, master_priv->sarea); | ||
246 | } | ||
247 | kfree(master_priv); | ||
248 | master->driver_priv = NULL; | ||
249 | } | ||
250 | |||
251 | |||
252 | /* | ||
253 | * IOCTL. | 204 | * IOCTL. |
254 | */ | 205 | */ |
255 | int radeon_dma_ioctl_kms(struct drm_device *dev, void *data, | 206 | int radeon_dma_ioctl_kms(struct drm_device *dev, void *data, |