| .. | .. |
|---|
| 1 | +/* SPDX-License-Identifier: GPL-2.0-only */ |
|---|
| 1 | 2 | /* |
|---|
| 2 | 3 | * Copyright (c) 2009-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 | | - * |
|---|
| 17 | 4 | */ |
|---|
| 18 | 5 | |
|---|
| 19 | 6 | #ifndef __INTEL_DRV_H__ |
|---|
| .. | .. |
|---|
| 24 | 11 | #include <drm/drm_crtc.h> |
|---|
| 25 | 12 | #include <drm/drm_crtc_helper.h> |
|---|
| 26 | 13 | #include <drm/drm_encoder.h> |
|---|
| 27 | | -#include <linux/gpio.h> |
|---|
| 14 | +#include <drm/drm_probe_helper.h> |
|---|
| 15 | +#include <drm/drm_vblank.h> |
|---|
| 28 | 16 | #include "gma_display.h" |
|---|
| 29 | 17 | |
|---|
| 30 | 18 | /* |
|---|
| .. | .. |
|---|
| 66 | 54 | #define INTEL_OUTPUT_MIPI2 8 |
|---|
| 67 | 55 | #define INTEL_OUTPUT_DISPLAYPORT 9 |
|---|
| 68 | 56 | #define INTEL_OUTPUT_EDP 10 |
|---|
| 69 | | - |
|---|
| 70 | | -#define INTEL_MODE_PIXEL_MULTIPLIER_SHIFT (0x0) |
|---|
| 71 | | -#define INTEL_MODE_PIXEL_MULTIPLIER_MASK (0xf << INTEL_MODE_PIXEL_MULTIPLIER_SHIFT) |
|---|
| 72 | | - |
|---|
| 73 | | -static inline void |
|---|
| 74 | | -psb_intel_mode_set_pixel_multiplier(struct drm_display_mode *mode, |
|---|
| 75 | | - int multiplier) |
|---|
| 76 | | -{ |
|---|
| 77 | | - mode->clock *= multiplier; |
|---|
| 78 | | - mode->private_flags |= multiplier; |
|---|
| 79 | | -} |
|---|
| 80 | | - |
|---|
| 81 | | -static inline int |
|---|
| 82 | | -psb_intel_mode_get_pixel_multiplier(const struct drm_display_mode *mode) |
|---|
| 83 | | -{ |
|---|
| 84 | | - return (mode->private_flags & INTEL_MODE_PIXEL_MULTIPLIER_MASK) |
|---|
| 85 | | - >> INTEL_MODE_PIXEL_MULTIPLIER_SHIFT; |
|---|
| 86 | | -} |
|---|
| 87 | | - |
|---|
| 88 | 57 | |
|---|
| 89 | 58 | /* |
|---|
| 90 | 59 | * Hold information useally put on the device driver privates here, |
|---|
| .. | .. |
|---|
| 194 | 163 | struct psb_intel_crtc_state *crtc_state; |
|---|
| 195 | 164 | |
|---|
| 196 | 165 | const struct gma_clock_funcs *clock_funcs; |
|---|
| 166 | + |
|---|
| 167 | + struct drm_pending_vblank_event *page_flip_event; |
|---|
| 197 | 168 | }; |
|---|
| 198 | 169 | |
|---|
| 199 | 170 | #define to_gma_crtc(x) \ |
|---|
| .. | .. |
|---|
| 261 | 232 | struct drm_property *property, |
|---|
| 262 | 233 | uint64_t value); |
|---|
| 263 | 234 | extern void psb_intel_lvds_destroy(struct drm_connector *connector); |
|---|
| 264 | | -extern const struct drm_encoder_funcs psb_intel_lvds_enc_funcs; |
|---|
| 265 | 235 | |
|---|
| 266 | 236 | /* intel_gmbus.c */ |
|---|
| 267 | 237 | extern void gma_intel_i2c_reset(struct drm_device *dev); |
|---|