~ubuntu-branches/debian/wheezy/linux-2.6/wheezy

« back to all changes in this revision

Viewing changes to include/drm/drm_mode.h

  • Committer: Bazaar Package Importer
  • Author(s): Ben Hutchings, Ben Hutchings, Aurelien Jarno, Martin Michlmayr
  • Date: 2011-04-06 13:53:30 UTC
  • mfrom: (43.1.5 sid)
  • Revision ID: james.westby@ubuntu.com-20110406135330-wjufxhd0tvn3zx4z
Tags: 2.6.38-3
[ Ben Hutchings ]
* [ppc64] Add to linux-tools package architectures (Closes: #620124)
* [amd64] Save cr4 to mmu_cr4_features at boot time (Closes: #620284)
* appletalk: Fix bugs introduced when removing use of BKL
* ALSA: Fix yet another race in disconnection
* cciss: Fix lost command issue
* ath9k: Fix kernel panic in AR2427
* ses: Avoid kernel panic when lun 0 is not mapped
* PCI/ACPI: Report ASPM support to BIOS if not disabled from command line

[ Aurelien Jarno ]
* rtlwifi: fix build when PCI is not enabled.

[ Martin Michlmayr ]
* rtlwifi: Eliminate udelay calls with too large values (Closes: #620204)

Show diffs side-by-side

added added

removed removed

Lines of Context:
27
27
#ifndef _DRM_MODE_H
28
28
#define _DRM_MODE_H
29
29
 
30
 
#include <linux/kernel.h>
31
 
#include <linux/types.h>
32
 
 
33
30
#define DRM_DISPLAY_INFO_LEN    32
34
31
#define DRM_CONNECTOR_NAME_LEN  32
35
32
#define DRM_DISPLAY_MODE_LEN    32
77
74
/* Dithering mode options */
78
75
#define DRM_MODE_DITHERING_OFF  0
79
76
#define DRM_MODE_DITHERING_ON   1
 
77
#define DRM_MODE_DITHERING_AUTO 2
 
78
 
 
79
/* Dirty info options */
 
80
#define DRM_MODE_DIRTY_OFF      0
 
81
#define DRM_MODE_DIRTY_ON       1
 
82
#define DRM_MODE_DIRTY_ANNOTATE 2
80
83
 
81
84
struct drm_mode_modeinfo {
82
85
        __u32 clock;
83
86
        __u16 hdisplay, hsync_start, hsync_end, htotal, hskew;
84
87
        __u16 vdisplay, vsync_start, vsync_end, vtotal, vscan;
85
88
 
86
 
        __u32 vrefresh; /* vertical refresh * 1000 */
 
89
        __u32 vrefresh;
87
90
 
88
91
        __u32 flags;
89
92
        __u32 type;
158
161
#define DRM_MODE_CONNECTOR_HDMIA        11
159
162
#define DRM_MODE_CONNECTOR_HDMIB        12
160
163
#define DRM_MODE_CONNECTOR_TV           13
 
164
#define DRM_MODE_CONNECTOR_eDP          14
161
165
 
162
166
struct drm_mode_get_connector {
163
167
 
225
229
        __u32 handle;
226
230
};
227
231
 
 
232
#define DRM_MODE_FB_DIRTY_ANNOTATE_COPY 0x01
 
233
#define DRM_MODE_FB_DIRTY_ANNOTATE_FILL 0x02
 
234
#define DRM_MODE_FB_DIRTY_FLAGS         0x03
 
235
 
 
236
/*
 
237
 * Mark a region of a framebuffer as dirty.
 
238
 *
 
239
 * Some hardware does not automatically update display contents
 
240
 * as a hardware or software draw to a framebuffer. This ioctl
 
241
 * allows userspace to tell the kernel and the hardware what
 
242
 * regions of the framebuffer have changed.
 
243
 *
 
244
 * The kernel or hardware is free to update more then just the
 
245
 * region specified by the clip rects. The kernel or hardware
 
246
 * may also delay and/or coalesce several calls to dirty into a
 
247
 * single update.
 
248
 *
 
249
 * Userspace may annotate the updates, the annotates are a
 
250
 * promise made by the caller that the change is either a copy
 
251
 * of pixels or a fill of a single color in the region specified.
 
252
 *
 
253
 * If the DRM_MODE_FB_DIRTY_ANNOTATE_COPY flag is given then
 
254
 * the number of updated regions are half of num_clips given,
 
255
 * where the clip rects are paired in src and dst. The width and
 
256
 * height of each one of the pairs must match.
 
257
 *
 
258
 * If the DRM_MODE_FB_DIRTY_ANNOTATE_FILL flag is given the caller
 
259
 * promises that the region specified of the clip rects is filled
 
260
 * completely with a single color as given in the color argument.
 
261
 */
 
262
 
 
263
struct drm_mode_fb_dirty_cmd {
 
264
        __u32 fb_id;
 
265
        __u32 flags;
 
266
        __u32 color;
 
267
        __u32 num_clips;
 
268
        __u64 clips_ptr;
 
269
};
 
270
 
228
271
struct drm_mode_mode_cmd {
229
272
        __u32 connector_id;
230
273
        struct drm_mode_modeinfo mode;
268
311
        __u64 blue;
269
312
};
270
313
 
 
314
#define DRM_MODE_PAGE_FLIP_EVENT 0x01
 
315
#define DRM_MODE_PAGE_FLIP_FLAGS DRM_MODE_PAGE_FLIP_EVENT
 
316
 
 
317
/*
 
318
 * Request a page flip on the specified crtc.
 
319
 *
 
320
 * This ioctl will ask KMS to schedule a page flip for the specified
 
321
 * crtc.  Once any pending rendering targeting the specified fb (as of
 
322
 * ioctl time) has completed, the crtc will be reprogrammed to display
 
323
 * that fb after the next vertical refresh.  The ioctl returns
 
324
 * immediately, but subsequent rendering to the current fb will block
 
325
 * in the execbuffer ioctl until the page flip happens.  If a page
 
326
 * flip is already pending as the ioctl is called, EBUSY will be
 
327
 * returned.
 
328
 *
 
329
 * The ioctl supports one flag, DRM_MODE_PAGE_FLIP_EVENT, which will
 
330
 * request that drm sends back a vblank event (see drm.h: struct
 
331
 * drm_event_vblank) when the page flip is done.  The user_data field
 
332
 * passed in with this ioctl will be returned as the user_data field
 
333
 * in the vblank event struct.
 
334
 *
 
335
 * The reserved field must be zero until we figure out something
 
336
 * clever to use it for.
 
337
 */
 
338
 
 
339
struct drm_mode_crtc_page_flip {
 
340
        __u32 crtc_id;
 
341
        __u32 fb_id;
 
342
        __u32 flags;
 
343
        __u32 reserved;
 
344
        __u64 user_data;
 
345
};
 
346
 
271
347
#endif