Rev 2161 | Rev 3031 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 2161 | Rev 2967 | ||
---|---|---|---|
Line 27... | Line 27... | ||
27 | 27 | ||
28 | #include |
28 | #include |
29 | #include |
29 | #include |
30 | #include |
30 | #include |
31 | #include |
- | |
32 | 31 | #include |
|
Line -... | Line 32... | ||
- | 32 | #include |
|
- | 33 | ||
33 | #include |
34 | #include |
34 | 35 | ||
35 | struct drm_device; |
36 | struct drm_device; |
Line 42... | Line 43... | ||
42 | #define DRM_MODE_OBJECT_ENCODER 0xe0e0e0e0 |
43 | #define DRM_MODE_OBJECT_ENCODER 0xe0e0e0e0 |
43 | #define DRM_MODE_OBJECT_MODE 0xdededede |
44 | #define DRM_MODE_OBJECT_MODE 0xdededede |
44 | #define DRM_MODE_OBJECT_PROPERTY 0xb0b0b0b0 |
45 | #define DRM_MODE_OBJECT_PROPERTY 0xb0b0b0b0 |
45 | #define DRM_MODE_OBJECT_FB 0xfbfbfbfb |
46 | #define DRM_MODE_OBJECT_FB 0xfbfbfbfb |
46 | #define DRM_MODE_OBJECT_BLOB 0xbbbbbbbb |
47 | #define DRM_MODE_OBJECT_BLOB 0xbbbbbbbb |
- | 48 | #define DRM_MODE_OBJECT_PLANE 0xeeeeeeee |
|
Line 47... | Line 49... | ||
47 | 49 | ||
48 | struct drm_mode_object { |
50 | struct drm_mode_object { |
49 | uint32_t id; |
51 | uint32_t id; |
50 | uint32_t type; |
52 | uint32_t type; |
Line 116... | Line 118... | ||
116 | struct list_head head; |
118 | struct list_head head; |
117 | struct drm_mode_object base; |
119 | struct drm_mode_object base; |
Line 118... | Line 120... | ||
118 | 120 | ||
Line 119... | Line -... | ||
119 | char name[DRM_DISPLAY_MODE_LEN]; |
- | |
120 | 121 | char name[DRM_DISPLAY_MODE_LEN]; |
|
121 | int connector_count; |
122 | |
Line 122... | Line 123... | ||
122 | enum drm_mode_status status; |
123 | enum drm_mode_status status; |
123 | int type; |
124 | int type; |
Line 236... | Line 237... | ||
236 | struct drm_framebuffer { |
237 | struct drm_framebuffer { |
237 | struct drm_device *dev; |
238 | struct drm_device *dev; |
238 | struct list_head head; |
239 | struct list_head head; |
239 | struct drm_mode_object base; |
240 | struct drm_mode_object base; |
240 | const struct drm_framebuffer_funcs *funcs; |
241 | const struct drm_framebuffer_funcs *funcs; |
241 | unsigned int pitch; |
242 | unsigned int pitches[4]; |
- | 243 | unsigned int offsets[4]; |
|
242 | unsigned int width; |
244 | unsigned int width; |
243 | unsigned int height; |
245 | unsigned int height; |
244 | /* depth can be 15 or 16 */ |
246 | /* depth can be 15 or 16 */ |
245 | unsigned int depth; |
247 | unsigned int depth; |
246 | int bits_per_pixel; |
248 | int bits_per_pixel; |
247 | int flags; |
249 | int flags; |
- | 250 | uint32_t pixel_format; /* fourcc format */ |
|
248 | struct list_head filp_head; |
251 | struct list_head filp_head; |
249 | /* if you are using the helper */ |
252 | /* if you are using the helper */ |
250 | void *helper_private; |
253 | void *helper_private; |
251 | }; |
254 | }; |
Line 276... | Line 279... | ||
276 | 279 | ||
277 | struct drm_crtc; |
280 | struct drm_crtc; |
278 | struct drm_connector; |
281 | struct drm_connector; |
279 | struct drm_encoder; |
282 | struct drm_encoder; |
- | 283 | struct drm_pending_vblank_event; |
|
Line 280... | Line 284... | ||
280 | struct drm_pending_vblank_event; |
284 | struct drm_plane; |
281 | 285 | ||
282 | /** |
286 | /** |
283 | * drm_crtc_funcs - control CRTCs for a given device |
287 | * drm_crtc_funcs - control CRTCs for a given device |
Line 339... | Line 343... | ||
339 | struct drm_pending_vblank_event *event); |
343 | struct drm_pending_vblank_event *event); |
340 | }; |
344 | }; |
Line 341... | Line 345... | ||
341 | 345 | ||
342 | /** |
346 | /** |
- | 347 | * drm_crtc - central CRTC control structure |
|
- | 348 | * @dev: parent DRM device |
|
- | 349 | * @head: list management |
|
343 | * drm_crtc - central CRTC control structure |
350 | * @base: base KMS object for ID tracking etc. |
- | 351 | * @enabled: is this CRTC enabled? |
|
- | 352 | * @mode: current mode timings |
|
344 | * @enabled: is this CRTC enabled? |
353 | * @hwmode: mode timings as programmed to hw regs |
345 | * @x: x position on screen |
354 | * @x: x position on screen |
346 | * @y: y position on screen |
355 | * @y: y position on screen |
- | 356 | * @funcs: CRTC control functions |
|
- | 357 | * @gamma_size: size of gamma ramp |
|
- | 358 | * @gamma_store: gamma ramp values |
|
- | 359 | * @framedur_ns: precise frame timing |
|
- | 360 | * @framedur_ns: precise line timing |
|
- | 361 | * @pixeldur_ns: precise pixel timing |
|
347 | * @funcs: CRTC control functions |
362 | * @helper_private: mid-layer private data |
348 | * |
363 | * |
349 | * Each CRTC may have one or more connectors associated with it. This structure |
364 | * Each CRTC may have one or more connectors associated with it. This structure |
350 | * allows the CRTC to be controlled. |
365 | * allows the CRTC to be controlled. |
351 | */ |
366 | */ |
Line 421... | Line 436... | ||
421 | uint64_t val); |
436 | uint64_t val); |
422 | void (*destroy)(struct drm_connector *connector); |
437 | void (*destroy)(struct drm_connector *connector); |
423 | void (*force)(struct drm_connector *connector); |
438 | void (*force)(struct drm_connector *connector); |
424 | }; |
439 | }; |
Line -... | Line 440... | ||
- | 440 | ||
- | 441 | /** |
|
- | 442 | * drm_encoder_funcs - encoder controls |
|
- | 443 | * @reset: reset state (e.g. at init or resume time) |
|
- | 444 | * @destroy: cleanup and free associated data |
|
- | 445 | * |
|
- | 446 | * Encoders sit between CRTCs and connectors. |
|
425 | 447 | */ |
|
426 | struct drm_encoder_funcs { |
448 | struct drm_encoder_funcs { |
427 | void (*reset)(struct drm_encoder *encoder); |
449 | void (*reset)(struct drm_encoder *encoder); |
428 | void (*destroy)(struct drm_encoder *encoder); |
450 | void (*destroy)(struct drm_encoder *encoder); |
Line 429... | Line 451... | ||
429 | }; |
451 | }; |
430 | 452 | ||
431 | #define DRM_CONNECTOR_MAX_UMODES 16 |
453 | #define DRM_CONNECTOR_MAX_UMODES 16 |
432 | #define DRM_CONNECTOR_MAX_PROPERTY 16 |
454 | #define DRM_CONNECTOR_MAX_PROPERTY 16 |
Line 433... | Line 455... | ||
433 | #define DRM_CONNECTOR_LEN 32 |
455 | #define DRM_CONNECTOR_LEN 32 |
434 | #define DRM_CONNECTOR_MAX_ENCODER 2 |
456 | #define DRM_CONNECTOR_MAX_ENCODER 3 |
- | 457 | ||
- | 458 | /** |
|
- | 459 | * drm_encoder - central DRM encoder structure |
|
- | 460 | * @dev: parent DRM device |
|
- | 461 | * @head: list management |
|
- | 462 | * @base: base KMS object |
|
- | 463 | * @encoder_type: one of the %DRM_MODE_ENCODER_ |
|
- | 464 | * @possible_crtcs: bitmask of potential CRTC bindings |
|
- | 465 | * @possible_clones: bitmask of potential sibling encoders for cloning |
|
- | 466 | * @crtc: currently bound CRTC |
|
- | 467 | * @funcs: control functions |
|
- | 468 | * @helper_private: mid-layer private data |
|
435 | 469 | * |
|
436 | /** |
470 | * CRTCs drive pixels to encoders, which convert them into signals |
437 | * drm_encoder - central DRM encoder structure |
471 | * appropriate for a given connector or set of connectors. |
438 | */ |
472 | */ |
Line 464... | Line 498... | ||
464 | #define DRM_CONNECTOR_POLL_CONNECT (1 << 1) |
498 | #define DRM_CONNECTOR_POLL_CONNECT (1 << 1) |
465 | /* can cleanly poll for disconnections without flickering the screen */ |
499 | /* can cleanly poll for disconnections without flickering the screen */ |
466 | /* DACs should rarely do this without a lot of testing */ |
500 | /* DACs should rarely do this without a lot of testing */ |
467 | #define DRM_CONNECTOR_POLL_DISCONNECT (1 << 2) |
501 | #define DRM_CONNECTOR_POLL_DISCONNECT (1 << 2) |
Line -... | Line 502... | ||
- | 502 | ||
- | 503 | #define MAX_ELD_BYTES 128 |
|
468 | 504 | ||
469 | /** |
505 | /** |
- | 506 | * drm_connector - central DRM connector control structure |
|
- | 507 | * @dev: parent DRM device |
|
- | 508 | * @kdev: kernel device for sysfs attributes |
|
- | 509 | * @attr: sysfs attributes |
|
- | 510 | * @head: list management |
|
- | 511 | * @base: base KMS object |
|
470 | * drm_connector - central DRM connector control structure |
512 | * @connector_type: one of the %DRM_MODE_CONNECTOR_ |
471 | * @crtc: CRTC this connector is currently connected to, NULL if none |
513 | * @connector_type_id: index into connector type enum |
472 | * @interlace_allowed: can this connector handle interlaced modes? |
514 | * @interlace_allowed: can this connector handle interlaced modes? |
473 | * @doublescan_allowed: can this connector handle doublescan? |
515 | * @doublescan_allowed: can this connector handle doublescan? |
474 | * @available_modes: modes available on this connector (from get_modes() + user) |
516 | * @modes: modes available on this connector (from fill_modes() + user) |
475 | * @initial_x: initial x position for this connector |
517 | * @status: one of the drm_connector_status enums (connected, not, or unknown) |
476 | * @initial_y: initial y position for this connector |
518 | * @probed_modes: list of modes derived directly from the display |
477 | * @status: connector connected? |
519 | * @display_info: information about attached display (e.g. from EDID) |
- | 520 | * @funcs: connector control functions |
|
- | 521 | * @user_modes: user added mode list |
|
- | 522 | * @edid_blob_ptr: DRM property containing EDID if present |
|
- | 523 | * @property_ids: property tracking for this connector |
|
- | 524 | * @property_values: value pointers or data for properties |
|
- | 525 | * @polled: a %DRM_CONNECTOR_POLL_ |
|
- | 526 | * @dpms: current dpms state |
|
- | 527 | * @helper_private: mid-layer private data |
|
- | 528 | * @force: a %DRM_FORCE_ |
|
- | 529 | * @encoder_ids: valid encoders for this connector |
|
- | 530 | * @encoder: encoder driving this connector, if any |
|
- | 531 | * @eld: EDID-like data, if present |
|
- | 532 | * @dvi_dual: dual link DVI, if found |
|
- | 533 | * @max_tmds_clock: max clock rate, if found |
|
- | 534 | * @latency_present: AV delay info from ELD, if found |
|
- | 535 | * @video_latency: video latency info from ELD, if found |
|
- | 536 | * @audio_latency: audio latency info from ELD, if found |
|
478 | * @funcs: connector control functions |
537 | * @null_edid_counter: track sinks that give us all zeros for the EDID |
479 | * |
538 | * |
480 | * Each connector may be connected to one or more CRTCs, or may be clonable by |
539 | * Each connector may be connected to one or more CRTCs, or may be clonable by |
481 | * another connector if they can share a CRTC. Each connector also has a specific |
540 | * another connector if they can share a CRTC. Each connector also has a specific |
482 | * position in the broader display (referred to as a 'screen' though it could |
541 | * position in the broader display (referred to as a 'screen' though it could |
Line 494... | Line 553... | ||
494 | int connector_type_id; |
553 | int connector_type_id; |
495 | bool interlace_allowed; |
554 | bool interlace_allowed; |
496 | bool doublescan_allowed; |
555 | bool doublescan_allowed; |
497 | struct list_head modes; /* list of modes on this connector */ |
556 | struct list_head modes; /* list of modes on this connector */ |
Line 498... | Line -... | ||
498 | - | ||
499 | int initial_x, initial_y; |
557 | |
Line 500... | Line 558... | ||
500 | enum drm_connector_status status; |
558 | enum drm_connector_status status; |
501 | 559 | ||
Line 518... | Line 576... | ||
518 | void *helper_private; |
576 | void *helper_private; |
Line 519... | Line 577... | ||
519 | 577 | ||
520 | /* forced on connector */ |
578 | /* forced on connector */ |
521 | enum drm_connector_force force; |
579 | enum drm_connector_force force; |
522 | uint32_t encoder_ids[DRM_CONNECTOR_MAX_ENCODER]; |
- | |
523 | uint32_t force_encoder_id; |
580 | uint32_t encoder_ids[DRM_CONNECTOR_MAX_ENCODER]; |
Line -... | Line 581... | ||
- | 581 | struct drm_encoder *encoder; /* currently active encoder */ |
|
- | 582 | ||
- | 583 | /* EDID bits */ |
|
- | 584 | uint8_t eld[MAX_ELD_BYTES]; |
|
- | 585 | bool dvi_dual; |
|
- | 586 | int max_tmds_clock; /* in MHz */ |
|
- | 587 | bool latency_present[2]; |
|
524 | struct drm_encoder *encoder; /* currently active encoder */ |
588 | int video_latency[2]; /* [0]: progressive, [1]: interlaced */ |
525 | 589 | int audio_latency[2]; |
|
Line 526... | Line 590... | ||
526 | int null_edid_counter; /* needed to workaround some HW bugs where we get all 0s */ |
590 | int null_edid_counter; /* needed to workaround some HW bugs where we get all 0s */ |
- | 591 | }; |
|
- | 592 | ||
- | 593 | /** |
|
- | 594 | * drm_plane_funcs - driver plane control functions |
|
- | 595 | * @update_plane: update the plane configuration |
|
- | 596 | * @disable_plane: shut down the plane |
|
- | 597 | * @destroy: clean up plane resources |
|
- | 598 | */ |
|
- | 599 | struct drm_plane_funcs { |
|
- | 600 | int (*update_plane)(struct drm_plane *plane, |
|
- | 601 | struct drm_crtc *crtc, struct drm_framebuffer *fb, |
|
- | 602 | int crtc_x, int crtc_y, |
|
- | 603 | unsigned int crtc_w, unsigned int crtc_h, |
|
- | 604 | uint32_t src_x, uint32_t src_y, |
|
- | 605 | uint32_t src_w, uint32_t src_h); |
|
- | 606 | int (*disable_plane)(struct drm_plane *plane); |
|
- | 607 | void (*destroy)(struct drm_plane *plane); |
|
- | 608 | }; |
|
- | 609 | ||
- | 610 | /** |
|
- | 611 | * drm_plane - central DRM plane control structure |
|
- | 612 | * @dev: DRM device this plane belongs to |
|
- | 613 | * @head: for list management |
|
- | 614 | * @base: base mode object |
|
- | 615 | * @possible_crtcs: pipes this plane can be bound to |
|
- | 616 | * @format_types: array of formats supported by this plane |
|
- | 617 | * @format_count: number of formats supported |
|
- | 618 | * @crtc: currently bound CRTC |
|
- | 619 | * @fb: currently bound fb |
|
- | 620 | * @gamma_size: size of gamma table |
|
- | 621 | * @gamma_store: gamma correction table |
|
- | 622 | * @enabled: enabled flag |
|
- | 623 | * @funcs: helper functions |
|
- | 624 | * @helper_private: storage for drver layer |
|
- | 625 | */ |
|
- | 626 | struct drm_plane { |
|
527 | }; |
627 | struct drm_device *dev; |
- | 628 | struct list_head head; |
|
- | 629 | ||
- | 630 | struct drm_mode_object base; |
|
- | 631 | ||
- | 632 | uint32_t possible_crtcs; |
|
- | 633 | uint32_t *format_types; |
|
- | 634 | uint32_t format_count; |
|
- | 635 | ||
- | 636 | struct drm_crtc *crtc; |
|
- | 637 | struct drm_framebuffer *fb; |
|
- | 638 | ||
- | 639 | /* CRTC gamma size for reporting to userspace */ |
|
- | 640 | uint32_t gamma_size; |
|
- | 641 | uint16_t *gamma_store; |
|
- | 642 | ||
- | 643 | bool enabled; |
|
- | 644 | ||
- | 645 | const struct drm_plane_funcs *funcs; |
|
- | 646 | void *helper_private; |
|
- | 647 | }; |
|
- | 648 | ||
- | 649 | /** |
|
- | 650 | * drm_mode_set - new values for a CRTC config change |
|
- | 651 | * @head: list management |
|
- | 652 | * @fb: framebuffer to use for new config |
|
- | 653 | * @crtc: CRTC whose configuration we're about to change |
|
- | 654 | * @mode: mode timings to use |
|
- | 655 | * @x: position of this CRTC relative to @fb |
|
528 | 656 | * @y: position of this CRTC relative to @fb |
|
529 | /** |
657 | * @connectors: array of connectors to drive with this CRTC if possible |
530 | * struct drm_mode_set |
658 | * @num_connectors: size of @connectors array |
531 | * |
659 | * |
532 | * Represents a single crtc the connectors that it drives with what mode |
660 | * Represents a single crtc the connectors that it drives with what mode |
Line 547... | Line 675... | ||
547 | struct drm_connector **connectors; |
675 | struct drm_connector **connectors; |
548 | size_t num_connectors; |
676 | size_t num_connectors; |
549 | }; |
677 | }; |
Line 550... | Line 678... | ||
550 | 678 | ||
551 | /** |
679 | /** |
- | 680 | * struct drm_mode_config_funcs - basic driver provided mode setting functions |
|
- | 681 | * @fb_create: create a new framebuffer object |
|
- | 682 | * @output_poll_changed: function to handle output configuration changes |
|
- | 683 | * |
|
- | 684 | * Some global (i.e. not per-CRTC, connector, etc) mode setting functions that |
|
552 | * struct drm_mode_config_funcs - configure CRTCs for a given screen layout |
685 | * involve drivers. |
553 | */ |
686 | */ |
554 | struct drm_mode_config_funcs { |
687 | struct drm_mode_config_funcs { |
- | 688 | struct drm_framebuffer *(*fb_create)(struct drm_device *dev, |
|
- | 689 | struct drm_file *file_priv, |
|
555 | struct drm_framebuffer *(*fb_create)(struct drm_device *dev, struct drm_file *file_priv, struct drm_mode_fb_cmd *mode_cmd); |
690 | struct drm_mode_fb_cmd2 *mode_cmd); |
556 | void (*output_poll_changed)(struct drm_device *dev); |
691 | void (*output_poll_changed)(struct drm_device *dev); |
Line -... | Line 692... | ||
- | 692 | }; |
|
- | 693 | ||
- | 694 | /** |
|
- | 695 | * drm_mode_group - group of mode setting resources for potential sub-grouping |
|
- | 696 | * @num_crtcs: CRTC count |
|
- | 697 | * @num_encoders: encoder count |
|
- | 698 | * @num_connectors: connector count |
|
- | 699 | * @id_list: list of KMS object IDs in this group |
|
- | 700 | * |
|
- | 701 | * Currently this simply tracks the global mode setting state. But in the |
|
- | 702 | * future it could allow groups of objects to be set aside into independent |
|
- | 703 | * control groups for use by different user level processes (e.g. two X servers |
|
- | 704 | * running simultaneously on different heads, each with their own mode |
|
557 | }; |
705 | * configuration and freedom of mode setting). |
558 | 706 | */ |
|
559 | struct drm_mode_group { |
707 | struct drm_mode_group { |
560 | uint32_t num_crtcs; |
708 | uint32_t num_crtcs; |
Line 565... | Line 713... | ||
565 | uint32_t *id_list; |
713 | uint32_t *id_list; |
566 | }; |
714 | }; |
Line 567... | Line 715... | ||
567 | 715 | ||
568 | /** |
716 | /** |
- | 717 | * drm_mode_config - Mode configuration control structure |
|
- | 718 | * @mutex: mutex protecting KMS related lists and structures |
|
- | 719 | * @idr_mutex: mutex for KMS ID allocation and management |
|
- | 720 | * @crtc_idr: main KMS ID tracking object |
|
- | 721 | * @num_fb: number of fbs available |
|
- | 722 | * @fb_list: list of framebuffers available |
|
- | 723 | * @num_connector: number of connectors on this device |
|
- | 724 | * @connector_list: list of connector objects |
|
- | 725 | * @num_encoder: number of encoders on this device |
|
- | 726 | * @encoder_list: list of encoder objects |
|
- | 727 | * @num_crtc: number of CRTCs on this device |
|
- | 728 | * @crtc_list: list of CRTC objects |
|
- | 729 | * @min_width: minimum pixel width on this device |
|
- | 730 | * @min_height: minimum pixel height on this device |
|
- | 731 | * @max_width: maximum pixel width on this device |
|
- | 732 | * @max_height: maximum pixel height on this device |
|
- | 733 | * @funcs: core driver provided mode setting functions |
|
- | 734 | * @fb_base: base address of the framebuffer |
|
- | 735 | * @poll_enabled: track polling status for this device |
|
- | 736 | * @output_poll_work: delayed work for polling in process context |
|
569 | * drm_mode_config - Mode configuration control structure |
737 | * @*_property: core property tracking |
- | 738 | * |
|
- | 739 | * Core mode resource tracking structure. All CRTC, encoders, and connectors |
|
- | 740 | * enumerated by the driver are added here, as are global properties. Some |
|
570 | * |
741 | * global restrictions are also here, e.g. dimension restrictions. |
571 | */ |
742 | */ |
572 | struct drm_mode_config { |
743 | struct drm_mode_config { |
573 | struct mutex mutex; /* protects configuration (mode lists etc.) */ |
744 | struct mutex mutex; /* protects configuration (mode lists etc.) */ |
574 | struct mutex idr_mutex; /* for IDR management */ |
745 | struct mutex idr_mutex; /* for IDR management */ |
Line 578... | Line 749... | ||
578 | struct list_head fb_list; |
749 | struct list_head fb_list; |
579 | int num_connector; |
750 | int num_connector; |
580 | struct list_head connector_list; |
751 | struct list_head connector_list; |
581 | int num_encoder; |
752 | int num_encoder; |
582 | struct list_head encoder_list; |
753 | struct list_head encoder_list; |
- | 754 | int num_plane; |
|
- | 755 | struct list_head plane_list; |
|
Line 583... | Line 756... | ||
583 | 756 | ||
584 | int num_crtc; |
757 | int num_crtc; |
Line 585... | Line 758... | ||
585 | struct list_head crtc_list; |
758 | struct list_head crtc_list; |
Line 630... | Line 803... | ||
630 | #define obj_to_encoder(x) container_of(x, struct drm_encoder, base) |
803 | #define obj_to_encoder(x) container_of(x, struct drm_encoder, base) |
631 | #define obj_to_mode(x) container_of(x, struct drm_display_mode, base) |
804 | #define obj_to_mode(x) container_of(x, struct drm_display_mode, base) |
632 | #define obj_to_fb(x) container_of(x, struct drm_framebuffer, base) |
805 | #define obj_to_fb(x) container_of(x, struct drm_framebuffer, base) |
633 | #define obj_to_property(x) container_of(x, struct drm_property, base) |
806 | #define obj_to_property(x) container_of(x, struct drm_property, base) |
634 | #define obj_to_blob(x) container_of(x, struct drm_property_blob, base) |
807 | #define obj_to_blob(x) container_of(x, struct drm_property_blob, base) |
- | 808 | #define obj_to_plane(x) container_of(x, struct drm_plane, base) |
|
Line 635... | Line 809... | ||
635 | 809 | ||
636 | 810 | ||
637 | extern void drm_crtc_init(struct drm_device *dev, |
811 | extern void drm_crtc_init(struct drm_device *dev, |
Line 649... | Line 823... | ||
649 | extern void drm_encoder_init(struct drm_device *dev, |
823 | extern void drm_encoder_init(struct drm_device *dev, |
650 | struct drm_encoder *encoder, |
824 | struct drm_encoder *encoder, |
651 | const struct drm_encoder_funcs *funcs, |
825 | const struct drm_encoder_funcs *funcs, |
652 | int encoder_type); |
826 | int encoder_type); |
Line -... | Line 827... | ||
- | 827 | ||
- | 828 | extern int drm_plane_init(struct drm_device *dev, |
|
- | 829 | struct drm_plane *plane, |
|
- | 830 | unsigned long possible_crtcs, |
|
- | 831 | const struct drm_plane_funcs *funcs, |
|
- | 832 | const uint32_t *formats, uint32_t format_count, |
|
- | 833 | bool priv); |
|
- | 834 | extern void drm_plane_cleanup(struct drm_plane *plane); |
|
653 | 835 | ||
Line 654... | Line 836... | ||
654 | extern void drm_encoder_cleanup(struct drm_encoder *encoder); |
836 | extern void drm_encoder_cleanup(struct drm_encoder *encoder); |
655 | 837 | ||
656 | extern char *drm_get_connector_name(struct drm_connector *connector); |
838 | extern char *drm_get_connector_name(struct drm_connector *connector); |
Line 742... | Line 924... | ||
742 | extern struct drm_mode_object *drm_mode_object_find(struct drm_device *dev, |
924 | extern struct drm_mode_object *drm_mode_object_find(struct drm_device *dev, |
743 | uint32_t id, uint32_t type); |
925 | uint32_t id, uint32_t type); |
744 | /* IOCTLs */ |
926 | /* IOCTLs */ |
745 | extern int drm_mode_getresources(struct drm_device *dev, |
927 | extern int drm_mode_getresources(struct drm_device *dev, |
746 | void *data, struct drm_file *file_priv); |
928 | void *data, struct drm_file *file_priv); |
747 | - | ||
- | 929 | extern int drm_mode_getplane_res(struct drm_device *dev, void *data, |
|
- | 930 | struct drm_file *file_priv); |
|
748 | extern int drm_mode_getcrtc(struct drm_device *dev, |
931 | extern int drm_mode_getcrtc(struct drm_device *dev, |
749 | void *data, struct drm_file *file_priv); |
932 | void *data, struct drm_file *file_priv); |
750 | extern int drm_mode_getconnector(struct drm_device *dev, |
933 | extern int drm_mode_getconnector(struct drm_device *dev, |
751 | void *data, struct drm_file *file_priv); |
934 | void *data, struct drm_file *file_priv); |
752 | extern int drm_mode_setcrtc(struct drm_device *dev, |
935 | extern int drm_mode_setcrtc(struct drm_device *dev, |
753 | void *data, struct drm_file *file_priv); |
936 | void *data, struct drm_file *file_priv); |
- | 937 | extern int drm_mode_getplane(struct drm_device *dev, |
|
- | 938 | void *data, struct drm_file *file_priv); |
|
- | 939 | extern int drm_mode_setplane(struct drm_device *dev, |
|
- | 940 | void *data, struct drm_file *file_priv); |
|
754 | extern int drm_mode_cursor_ioctl(struct drm_device *dev, |
941 | extern int drm_mode_cursor_ioctl(struct drm_device *dev, |
755 | void *data, struct drm_file *file_priv); |
942 | void *data, struct drm_file *file_priv); |
756 | extern int drm_mode_addfb(struct drm_device *dev, |
943 | extern int drm_mode_addfb(struct drm_device *dev, |
757 | void *data, struct drm_file *file_priv); |
944 | void *data, struct drm_file *file_priv); |
- | 945 | extern int drm_mode_addfb2(struct drm_device *dev, |
|
- | 946 | void *data, struct drm_file *file_priv); |
|
- | 947 | extern uint32_t drm_mode_legacy_fb_format(uint32_t bpp, uint32_t depth); |
|
758 | extern int drm_mode_rmfb(struct drm_device *dev, |
948 | extern int drm_mode_rmfb(struct drm_device *dev, |
759 | void *data, struct drm_file *file_priv); |
949 | void *data, struct drm_file *file_priv); |
760 | extern int drm_mode_getfb(struct drm_device *dev, |
950 | extern int drm_mode_getfb(struct drm_device *dev, |
761 | void *data, struct drm_file *file_priv); |
951 | void *data, struct drm_file *file_priv); |
762 | extern int drm_mode_dirtyfb_ioctl(struct drm_device *dev, |
952 | extern int drm_mode_dirtyfb_ioctl(struct drm_device *dev, |