summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/gma500/framebuffer.h
diff options
context:
space:
mode:
authorAlan Cox2011-11-03 19:21:20 +0100
committerDave Airlie2011-11-16 12:24:36 +0100
commit4d8d096e9ae86621cc38b5417f4353305c5fd3a9 (patch)
treec158eec1389cfaaf7f4945440453bb63caceddc3 /drivers/gpu/drm/gma500/framebuffer.h
parentgma500: introduce the GTT and MMU handling logic (diff)
downloadkernel-qcow2-linux-4d8d096e9ae86621cc38b5417f4353305c5fd3a9.tar.gz
kernel-qcow2-linux-4d8d096e9ae86621cc38b5417f4353305c5fd3a9.tar.xz
kernel-qcow2-linux-4d8d096e9ae86621cc38b5417f4353305c5fd3a9.zip
gma500: introduce the framebuffer support code
We support 2D acceleration on some devices but we try and do tricks with the GTT as a starting point as this is far faster. The GTT logic could be improved further but for most display sizes it already makes a pretty good decision. Signed-off-by: Alan Cox <alan@linux.intel.com> Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/gma500/framebuffer.h')
-rw-r--r--drivers/gpu/drm/gma500/framebuffer.h48
1 files changed, 48 insertions, 0 deletions
diff --git a/drivers/gpu/drm/gma500/framebuffer.h b/drivers/gpu/drm/gma500/framebuffer.h
new file mode 100644
index 000000000000..d1b2289447f0
--- /dev/null
+++ b/drivers/gpu/drm/gma500/framebuffer.h
@@ -0,0 +1,48 @@
+/*
+ * Copyright (c) 2008-2011, Intel Corporation
+ *
+ * This program is free software; you can redistribute it and/or modify it
+ * under the terms and conditions of the GNU General Public License,
+ * version 2, as published by the Free Software Foundation.
+ *
+ * This program is distributed in the hope it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
+ * more details.
+ *
+ * You should have received a copy of the GNU General Public License along with
+ * this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin St - Fifth Floor, Boston, MA 02110-1301 USA.
+ *
+ * Authors:
+ * Eric Anholt <eric@anholt.net>
+ *
+ */
+
+#ifndef _FRAMEBUFFER_H_
+#define _FRAMEBUFFER_H_
+
+#include <drm/drmP.h>
+#include <drm/drm_fb_helper.h>
+
+#include "psb_drv.h"
+
+struct psb_framebuffer {
+ struct drm_framebuffer base;
+ struct address_space *addr_space;
+ struct fb_info *fbdev;
+ struct gtt_range *gtt;
+ bool vm_map; /* True if we must undo a vm_map_ram */
+};
+
+struct psb_fbdev {
+ struct drm_fb_helper psb_fb_helper;
+ struct psb_framebuffer pfb;
+};
+
+#define to_psb_fb(x) container_of(x, struct psb_framebuffer, base)
+
+extern int psb_intel_connector_clones(struct drm_device *dev, int type_mask);
+
+#endif
+