.. | .. |
---|
| 1 | +// SPDX-License-Identifier: GPL-2.0-only |
---|
1 | 2 | /* |
---|
2 | 3 | * Copyright © 2006-2011 Intel Corporation |
---|
3 | | - * |
---|
4 | | - * This program is free software; you can redistribute it and/or modify it |
---|
5 | | - * under the terms and conditions of the GNU General Public License, |
---|
6 | | - * version 2, as published by the Free Software Foundation. |
---|
7 | | - * |
---|
8 | | - * This program is distributed in the hope it will be useful, but WITHOUT |
---|
9 | | - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
---|
10 | | - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for |
---|
11 | | - * more details. |
---|
12 | | - * |
---|
13 | | - * You should have received a copy of the GNU General Public License along with |
---|
14 | | - * this program; if not, write to the Free Software Foundation, Inc., |
---|
15 | | - * 51 Franklin St - Fifth Floor, Boston, MA 02110-1301 USA. |
---|
16 | 4 | * |
---|
17 | 5 | * Authors: |
---|
18 | 6 | * Eric Anholt <eric@anholt.net> |
---|
19 | 7 | */ |
---|
20 | 8 | |
---|
| 9 | +#include <linux/delay.h> |
---|
21 | 10 | #include <linux/i2c.h> |
---|
22 | 11 | |
---|
23 | | -#include <drm/drmP.h> |
---|
| 12 | +#include <drm/drm_crtc.h> |
---|
| 13 | + |
---|
| 14 | +#include "cdv_device.h" |
---|
24 | 15 | #include "framebuffer.h" |
---|
| 16 | +#include "gma_display.h" |
---|
| 17 | +#include "power.h" |
---|
25 | 18 | #include "psb_drv.h" |
---|
26 | 19 | #include "psb_intel_drv.h" |
---|
27 | 20 | #include "psb_intel_reg.h" |
---|
28 | | -#include "gma_display.h" |
---|
29 | | -#include "power.h" |
---|
30 | | -#include "cdv_device.h" |
---|
31 | 21 | |
---|
32 | 22 | static bool cdv_intel_find_dp_pll(const struct gma_limit_t *limit, |
---|
33 | 23 | struct drm_crtc *crtc, int target, |
---|
.. | .. |
---|
592 | 582 | struct gma_clock_t clock; |
---|
593 | 583 | u32 dpll = 0, dspcntr, pipeconf; |
---|
594 | 584 | bool ok; |
---|
595 | | - bool is_crt = false, is_lvds = false, is_tv = false; |
---|
596 | | - bool is_hdmi = false, is_dp = false; |
---|
| 585 | + bool is_lvds = false, is_tv = false; |
---|
| 586 | + bool is_dp = false; |
---|
597 | 587 | struct drm_mode_config *mode_config = &dev->mode_config; |
---|
598 | 588 | struct drm_connector *connector; |
---|
599 | 589 | const struct gma_limit_t *limit; |
---|
.. | .. |
---|
617 | 607 | is_tv = true; |
---|
618 | 608 | break; |
---|
619 | 609 | case INTEL_OUTPUT_ANALOG: |
---|
620 | | - is_crt = true; |
---|
621 | | - break; |
---|
622 | 610 | case INTEL_OUTPUT_HDMI: |
---|
623 | | - is_hdmi = true; |
---|
624 | 611 | break; |
---|
625 | 612 | case INTEL_OUTPUT_DISPLAYPORT: |
---|
626 | 613 | is_dp = true; |
---|
.. | .. |
---|
989 | 976 | .gamma_set = gma_crtc_gamma_set, |
---|
990 | 977 | .set_config = gma_crtc_set_config, |
---|
991 | 978 | .destroy = gma_crtc_destroy, |
---|
| 979 | + .page_flip = gma_crtc_page_flip, |
---|
| 980 | + .enable_vblank = psb_enable_vblank, |
---|
| 981 | + .disable_vblank = psb_disable_vblank, |
---|
| 982 | + .get_vblank_counter = psb_get_vblank_counter, |
---|
992 | 983 | }; |
---|
993 | 984 | |
---|
994 | 985 | const struct gma_clock_funcs cdv_clock_funcs = { |
---|