Commit Graph

96 Commits (e0bbd04eb0e2395872983e243d242f5ba2f2306f)

Author SHA1 Message Date
Dave Airlie df9871064e radeon: add initial atombios modesetting and GEM -> TTM translation layer.
This is an initial import of the atom bios parser with modesetting support
for r500 hw using atombios. It also includes a simple memory manager
layer that translates a radeon GEM style interface onto TTM internally.

So far this memory manager has only been used for pinned object allocation
for the DDX to test modesetting.
2008-07-26 08:56:23 +10:00
Dave Airlie 11d3075087 modesetting: pass file_priv into cursor set functions 2008-07-26 08:41:01 +10:00
Maarten Maathuis 3ef1d05001 modesetting-101: set_property should return an int, not a bool 2008-07-20 14:51:22 +02:00
Maarten Maathuis 65803e53a6 modesetting-101: implement optional scaling and dithering properties 2008-07-20 13:49:18 +02:00
Maarten Maathuis c9915d695d modesetting-101: Move some defines used for enumeration into the public header.
- Otherwise userspace has no idea of the meaning.
2008-07-04 17:28:04 +02:00
Maarten Maathuis b29578103f [modesetting-101] Add subconnector and select_subconnector properties.
- These facilitate DVI-I and tv-out that can drive multiple types of signals.
2008-07-04 17:19:11 +02:00
Dave Airlie 142a309604 modesetting: rip out all of the generation code.
not needed, hotplug will work just as well hopefully.
2008-07-04 09:34:24 +10:00
Maarten Maathuis 087e3f577d Revert "modesetting-101: Make dpms property optional + misc cleanup."
This reverts commit 13943fe582.
2008-06-26 23:12:04 +02:00
Maarten Maathuis 13943fe582 modesetting-101: Make dpms property optional + misc cleanup.
- intel_crt seems the only one to provide it, so init it there.
2008-06-26 21:28:29 +02:00
Maarten Maathuis 473a1997ac NV50: Initial import of kernel modesetting. 2008-06-22 16:29:00 +02:00
Jesse Barnes c987e76d95 Add EDID quirk handling
Port over EDID quirks from X.Org so we can handle more monitors.  This meant
adding size info to the drm_display_mode struct, but other than that the
changes were isolated to the DRM EDID handling code (as they should be).
2008-06-09 16:20:45 -07:00
Dave Airlie 6d4ffd12cd drm: fix up fb resize again 2008-06-06 16:24:27 +10:00
Dave Airlie efcf066eff drm/modesetting: attempt to make fb code more sane 2008-06-05 15:21:07 +10:00
Dave Airlie f73e54bbf0 drm: modesetting unify the hotplug init paths a lot.
remove fb callbacks, just probe into the driver to sort it out
2008-06-05 13:40:08 +10:00
Dave Airlie 967bd21911 modesetting: initial attempt at debonging fb 2008-06-05 11:11:22 +10:00
Dave Airlie 382aa3ceeb drm: introduce generation counter to interface.
Idea being if you want to add new crtc/output/encoder dynamically later,
you just increase the generation counter and userspace should re-read
all the resources
2008-06-04 13:50:51 +10:00
Dave Airlie fd27591c6c drm/modesetting: pass object handle to driver !bo 2008-06-04 13:00:31 +10:00
Dave Airlie 76a44f14d6 drm/modesetting: overhaul the fb create/delete.
Move TTM code into the driver
2008-06-04 11:59:28 +10:00
Dave Airlie 149b17311a drm: initial mode object groups.
This creates a default group attached to the legacy drm minor nodes.

It covers all the objects in the set. make set resources only return
objects for this set. Need to fix up other functions to only work on
objects in their allowed set.
2008-06-02 16:45:44 +10:00
Dave Airlie 50d3e5bd02 drm/modesetting: redo object handles around a core object.
handle crtc/encoders/connectors/fb/mode/property/blob using this system.
2008-06-02 16:19:21 +10:00
Dave Airlie 4e7b246398 drm: add functions to get/set gamma ramps 2008-06-02 14:04:41 +10:00
Dave Airlie 46c78a2223 drm/modesetting: add best encoder finding for modesetting
This asks the driver to suggest the best encoder for the connector
during the pick crtcs stage.

Need to also do this during mode setting stages
2008-06-02 11:44:35 +10:00
Dave Airlie 0dd000b578 drm/modesetting: move some connector functions to helper.
Migrated the output mode collection into the helper.
2008-06-02 11:12:28 +10:00
Dave Airlie e439e74776 drm/modesetting: another re-org of some internals.
Move dpms into the helper functions.
Move crtc into the encoder.
Move disable unused functions into the helper.
2008-06-02 10:05:54 +10:00
Dave Airlie 5d47185eb6 drm: switch possible crtc/clones over to encoders 2008-05-30 15:32:58 +10:00
Dave Airlie 9d38448ed3 modesetting: the great renaming.
Okay we have crtc, encoder and connectors.

No more outputs exposed beyond driver internals

I've broken intel tv connector stuff.
Really for TV we should have one TV connector, with a sub property for the
type of signal been driven over it
2008-05-30 15:10:04 +10:00
Dave Airlie 6aeef92c0c drm: attach an encoder.
Time to do some renaming on the connectors I think
2008-05-30 13:57:27 +10:00
Dave Airlie 9239cf511f drm: add encoder attach/detach 2008-05-30 13:31:16 +10:00
Dave Airlie b72419a8f7 drm: add encoder ids to the output handling 2008-05-30 12:19:13 +10:00
Dave Airlie 8ae82f3a2f drm: add encoder / get encoder to the modesetting resources interface 2008-05-30 12:03:36 +10:00
Dave Airlie 6b970f193b drm: remove unused init func from outputs 2008-05-30 11:48:41 +10:00
Dave Airlie 9654c776fd drm/modesetting: add initial encoder structures and setup functions 2008-05-30 11:47:57 +10:00
Dave Airlie 98c5cf7f6f modesetting: reorganise out crtc/outputs are allocated.
Use subclassing from the drivers to allocate the objects. This saves
two objects being allocated for each crtc/output and generally makes
exit paths cleaner.
2008-05-30 11:25:41 +10:00
Dave Airlie df8cd54286 modesetting: reorganise code into core and helper functions.
This splits a lot of the core modesetting code out into a file of
helper functions, that are only called from themselves and/or the driver.

The driver gets called into more often or can call these functions from itself
if it is a helper using driver.

I've broken framebuffer resize doing this but I didn't like the API for that
in any case.
2008-05-29 14:02:14 +10:00
Jesse Barnes b4d8cda8e6 drm_mode_debug_printmodeline doesn't need struct drm_device *
Makes printing modelines from some routines easier.
2008-05-23 18:41:58 -07:00
Jakob Bornecrantz 7bcbc443f4 i915: Changed intel_fb to use the new drm_crtc_set_config interface 2008-05-08 20:10:18 +02:00
Jakob Bornecrantz ba36d54ad4 drm: Made set_config use drm_mode_set as a argument 2008-05-08 15:03:57 +02:00
Dave Airlie ed072ed075 drm_mode: initial replacefb implemenation 2008-05-08 14:02:05 +10:00
Jesse Barnes 83c3acb7da Split TV property creation into its own routine
It needs to take arguments from the caller about supported TV formats,
so declare it in drm_crtc.h and export it.
2008-04-10 20:30:12 -07:00
Jesse Barnes bee546ad69 Remove structure fields & code
Cleanup some random cruft left over from the initial port.
2008-04-10 19:02:53 -07:00
Jesse Barnes 0a6e301e6d Keep display info in struct display_info
Some fields had snuck into the drm_output structure.  Put them back and
fill in more stuff from the EDID block.
2008-04-10 11:23:55 -07:00
Jesse Barnes 6c92689dcc Port pipe reservation code for load detection
TV out needs to do load detection, which means we have to find an
available pipe to use for the detection.  Port over the pipe reservation
code for this purpose.
2008-04-09 14:13:38 -07:00
Jesse Barnes 5a3ce06f3a Improved DRM sysfs support
This patch ties outputs, output properties and hotplug events into the
DRM core.  Each output has a corresponding directory under the primary
DRM device (usually card0) containing dpms, edid, modes, and connection
status files.

New hotplug change events occur when outputs are added or hotplug events
are detected.
2008-04-08 12:42:23 -07:00
Alan Hourihane 2476cb209e Implement short circuit for base change only
Allow mode to be set with fb_id set to -1, meaning set
the mode with the current fb (if we have one bound).

Allow intelfb to hook back up it's fb if modesetting
clears it (maybe temporary).

Move any crtc->fb related register changes to set_base
in intel_fb.

General intelfb cleanups.
2008-02-26 15:19:34 +00:00
Dave Airlie 0d1cb1e840 hopefully shit works now without this... 2008-02-22 13:49:51 +10:00
Dave Airlie 8844245cfc drm/fb: get rid of offset from structure use bo offset 2008-02-20 11:27:22 +10:00
Jesse Barnes 2b1c9cd696 i915: initial (and untested) TV out support
Ported from xf86-video-intel.  Still need to tie in TV modes somehow, though
preferably w/o using the properties mechanism.
2008-02-15 16:13:21 -08:00
Jakob Bornecrantz 0618ac8a07 Added kernel part of hotplug ioctl 2008-02-07 19:24:58 +01:00
Alan Hourihane f2c706e247 Fix function declaration 2008-02-05 10:11:01 +00:00
Alan Hourihane c9772f8c03 consistency 2008-02-05 09:28:51 +00:00