VirtualBox

source: vbox/trunk/src/VBox/Additions/linux/drm/vboxvideo_drv.h@ 48242

Last change on this file since 48242 was 47480, checked in by vboxsync, 12 years ago

Additions/linux/drm: synchronising local tree with repository, currently not buildable.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 4.2 KB
Line 
1/** @file $Id: vboxvideo_drv.h 47480 2013-07-30 18:47:16Z vboxsync $
2 *
3 * VirtualBox Additions Linux kernel video driver
4 */
5
6/*
7 * Copyright (C) 2011-2012 Oracle Corporation
8 *
9 * This file is part of VirtualBox Open Source Edition (OSE), as
10 * available from http://www.virtualbox.org. This file is free software;
11 * you can redistribute it and/or modify it under the terms of the GNU
12 * General Public License (GPL) as published by the Free Software
13 * Foundation, in version 2 as it comes in the "COPYING" file of the
14 * VirtualBox OSE distribution. VirtualBox OSE is distributed in the
15 * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind.
16 * --------------------------------------------------------------------
17 *
18 * This code is based on
19 * glint_drv.h
20 * with the following copyright and permission notice:
21 *
22 * Copyright 2010 Matt Turner.
23 *
24 * Permission is hereby granted, free of charge, to any person obtaining a
25 * copy of this software and associated documentation files (the "Software"),
26 * to deal in the Software without restriction, including without limitation
27 * the rights to use, copy, modify, merge, publish, distribute, sublicense,
28 * and/or sell copies of the Software, and to permit persons to whom the
29 * Software is furnished to do so, subject to the following conditions:
30 *
31 * The above copyright notice and this permission notice shall be included in
32 * all copies or substantial portions of the Software.
33 *
34 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
35 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
36 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
37 * THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR
38 * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
39 * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
40 * OTHER DEALINGS IN THE SOFTWARE.
41 *
42 * Authors: Matt Turner
43 */
44
45#ifndef __DRM_VBOXVIDEO_DRV_H__
46#define __DRM_VBOXVIDEO_DRV_H__
47
48/* General customization:
49 */
50
51#include "vboxvideo.h"
52
53#include "product-generated.h"
54
55#define DRIVER_AUTHOR VBOX_VENDOR
56
57#define DRIVER_NAME "vboxvideo"
58#define DRIVER_DESC VBOX_PRODUCT " Graphics Card"
59#define DRIVER_DATE "20090303"
60
61#define DRIVER_MAJOR 1
62#define DRIVER_MINOR 0
63#define DRIVER_PATCHLEVEL 0
64
65#define VBOXVIDEO_INFO(fmt, arg...) DRM_INFO(DRIVER_NAME ": " fmt, ##arg)
66#define VBOXVIDEO_ERROR(fmt, arg...) DRM_ERROR(DRIVER_NAME ": " fmt, ##arg)
67
68#define MB (1024 * 1024)
69
70#define VBOXVIDEOFB_CONN_LIMIT VBOX_VIDEO_MAX_SCREENS°°
71
72/* vboxvideo_crtc.c */
73void vboxvideo_crtc_fb_gamma_set(struct drm_crtc *crtc, u16 red, u16 green,
74 u16 blue, int regno);
75void vboxvideo_crtc_fb_gamma_get(struct drm_crtc *crtc, u16 *red, u16 *green,
76 u16 *blue, int regno);
77void vboxvideo_crtc_init(struct drm_device *dev, int index);
78
79/* vboxvideo_dac.c */
80struct drm_encoder *vboxvideo_dac_init(struct drm_device *dev);
81
82/* vboxvideo_fbdev.c */
83int vboxvideo_fbdev_init(struct vboxvideo_device *gdev);
84void vboxvideo_fbdev_fini(struct vboxvideo_device *gdev);
85
86/* vboxvideo_framebuffer.c */
87int vboxvideo_framebuffer_init(struct drm_device *dev,
88 struct vboxvideo_framebuffer *gfb,
89 struct DRM_MODE_FB_CMD *mode_cmd);
90
91/* vboxvideo_device.c */
92int vboxvideo_device_init(struct vboxvideo_device *gdev,
93 struct drm_device *ddev,
94 struct pci_dev *pdev,
95 uint32_t flags);
96void vboxvideo_device_fini(struct vboxvideo_device *gdev);
97
98/* vboxvideo_display.c */
99int vboxvideo_modeset_init(struct vboxvideo_device *gdev);
100void vboxvideo_modeset_fini(struct vboxvideo_device *gdev);
101
102/* vboxvideo_kms.c */
103int vboxvideo_driver_load(struct drm_device *dev, unsigned long flags);
104int vboxvideo_driver_unload(struct drm_device *dev);
105extern struct drm_ioctl_desc vboxvideo_ioctls[];
106extern int vboxvideo_max_ioctl;
107
108/* vboxvideo_vga.c */
109struct drm_connector *vboxvideo_vga_init(struct drm_device *dev);
110
111#define vboxvideo_PCI_IDS \
112 {0x80ee, 0xbeef, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0}, \
113 {0, 0, 0}
114
115#endif /* __DRM_VBOXVIDEO_DRV_H__ */
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette