Dave Airlie [Thu, 31 Jul 2008 03:13:21 +0000 (13:13 +1000)]
drm: userspace rip out TTM API
Dave Airlie [Thu, 31 Jul 2008 03:12:36 +0000 (13:12 +1000)]
drm: add fault handler support so as to be more like possible upstream
(cherry picked from commit
10d5b037b85706037df89bf0275436797e4eb559)
Dave Airlie [Thu, 31 Jul 2008 02:54:48 +0000 (12:54 +1000)]
TTM: remove API and userspace objects.
This removes all the TTM userspace API and all userspace objects.
It also removes the drm_bo_lock.c code
Dave Airlie [Wed, 30 Jul 2008 07:06:11 +0000 (17:06 +1000)]
radeon: hack gem to get an offset back for Mesa.
Dave Airlie [Wed, 30 Jul 2008 07:05:50 +0000 (17:05 +1000)]
radeon: add some handles to the sarea + kernel mm available check
Dave Airlie [Tue, 29 Jul 2008 08:05:11 +0000 (18:05 +1000)]
radeon: move code around putting emit into cs
Dave Airlie [Tue, 29 Jul 2008 06:51:47 +0000 (16:51 +1000)]
radeon_cs: add relocate hook for mm and non-mm relocations
Dave Airlie [Mon, 28 Jul 2008 08:18:28 +0000 (18:18 +1000)]
radeon_cs: extract some offsets from packet data
Dave Airlie [Mon, 28 Jul 2008 07:42:53 +0000 (17:42 +1000)]
r300: add some packet 3 decodes
Dave Airlie [Mon, 28 Jul 2008 07:27:24 +0000 (17:27 +1000)]
r300: initial command stream parser for packet 0.
this at least parses the DDX stream and lets me run gnome-terminal/metacity
Dave Airlie [Mon, 28 Jul 2008 05:21:13 +0000 (15:21 +1000)]
radeon command submission start
take code from Jerome munge into a TTM IB re-use
Alex Deucher [Sat, 26 Jul 2008 20:57:02 +0000 (16:57 -0400)]
NV50: s/FALSE/false/
Dave Airlie [Fri, 25 Jul 2008 22:56:43 +0000 (08:56 +1000)]
tests: add some basic radeon gem tests
Dave Airlie [Fri, 25 Jul 2008 22:56:23 +0000 (08:56 +1000)]
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.
Dave Airlie [Fri, 25 Jul 2008 22:46:38 +0000 (08:46 +1000)]
Merge remote branch 'origin/modesetting-101' into modesetting-gem
Dave Airlie [Fri, 25 Jul 2008 03:30:08 +0000 (13:30 +1000)]
drm: don't set the signal blocker on the master process.
this lets us debug the X server through xkb startup.
Not sure what the correct answer is, probably X needs to drop
the lock when execing stuff, with input hotplug it can get
xkb stuff at any time I believe.
Dave Airlie [Fri, 25 Jul 2008 22:43:59 +0000 (08:43 +1000)]
modesetting: pass file priv to cursor
Dave Airlie [Fri, 25 Jul 2008 22:43:01 +0000 (08:43 +1000)]
nv50: remove TRUE/FALSE
Dave Airlie [Fri, 25 Jul 2008 22:41:01 +0000 (08:41 +1000)]
modesetting: pass file_priv into cursor set functions
Dave Airlie [Fri, 25 Jul 2008 22:38:59 +0000 (08:38 +1000)]
Merge remote branch 'origin/modesetting-101' into modesetting-gem
Dave Airlie [Thu, 24 Jul 2008 05:22:44 +0000 (15:22 +1000)]
drm: use correct mode destructor
Maarten Maathuis [Mon, 21 Jul 2008 14:57:25 +0000 (16:57 +0200)]
NV50: Don't create a "native" mode for LVDS when there is none.
Maarten Maathuis [Mon, 21 Jul 2008 14:40:55 +0000 (16:40 +0200)]
NV50: don't fail on LVDS by default
Maarten Maathuis [Mon, 21 Jul 2008 12:50:07 +0000 (14:50 +0200)]
NV50: Use bios table for load pattern when possible.
Maarten Maathuis [Mon, 21 Jul 2008 12:29:13 +0000 (14:29 +0200)]
NV50: Do detect with hpd and load detect if possible.
- Appropriate error messages when an unknown situation is encountered are included.
- Fallback to i2c will occur when needed.
Maarten Maathuis [Sun, 20 Jul 2008 13:40:40 +0000 (15:40 +0200)]
NV50: delay changing gpu<->non-gpu scaling modes until next modeset
Maarten Maathuis [Sun, 20 Jul 2008 12:58:46 +0000 (14:58 +0200)]
modesetting-101: Only store property value when set_property was successful.
Maarten Maathuis [Sun, 20 Jul 2008 12:55:59 +0000 (14:55 +0200)]
NV50: LVDS always needs some kind of gpu scaling
Maarten Maathuis [Sun, 20 Jul 2008 12:51:22 +0000 (14:51 +0200)]
modesetting-101: set_property should return an int, not a bool
Maarten Maathuis [Sun, 20 Jul 2008 11:49:18 +0000 (13:49 +0200)]
modesetting-101: implement optional scaling and dithering properties
Maarten Maathuis [Sat, 19 Jul 2008 22:09:06 +0000 (00:09 +0200)]
drm: As a workaround don't tear down sg with a modesetting driver.
- This allows me to maintain a useful prototype driver.
Ben Skeggs [Sun, 22 Jun 2008 15:24:11 +0000 (01:24 +1000)]
nv50: use same dma object for fb/tt access
We depend on the VM fully now for memory protection, separate DMA objects
for VRAM and GART are unneccesary. However, until the next interface break
(soon) a client can't depend on the objects being the same and must still
call NV_OBJ_SET_DMA_* methods appropriately.
Ben Skeggs [Tue, 24 Jun 2008 18:39:32 +0000 (04:39 +1000)]
nouveau: interface changes for nv5x 3d
Dave Airlie [Sat, 12 Jul 2008 06:32:09 +0000 (16:32 +1000)]
modesetting/helper: fix array overrun - count should be reset here
Dave Airlie [Wed, 9 Jul 2008 04:53:47 +0000 (14:53 +1000)]
Merge remote branch 'origin/modesetting-101' into modesetting-gem
Kristian Høgsberg [Mon, 7 Jul 2008 22:00:23 +0000 (18:00 -0400)]
Add back flink, open and close ioctls.
They fell through the cracks in
86accbcb.
Kristian Høgsberg [Mon, 7 Jul 2008 19:43:43 +0000 (15:43 -0400)]
Merge commit 'origin/drm-gem' into ms-gem
Conflicts:
linux-core/drmP.h
linux-core/drm_drv.c
linux-core/drm_stub.c
linux-core/i915_drv.c
linux-core/i915_gem.c
shared-core/i915_drv.h
shared-core/i915_irq.c
Kristian Høgsberg [Mon, 7 Jul 2008 15:56:59 +0000 (11:56 -0400)]
Use lowercase bool constants.
Alan Hourihane [Mon, 7 Jul 2008 14:11:48 +0000 (15:11 +0100)]
Synchronize the DDC EDID read to it's fb_ddc.c counterpart
Maarten Maathuis [Sun, 6 Jul 2008 10:51:43 +0000 (12:51 +0200)]
NV50: init gamma storage
Maarten Maathuis [Sun, 6 Jul 2008 09:23:17 +0000 (11:23 +0200)]
NV50: fix minor bug in fbcon crtc selection
Maarten Maathuis [Sun, 6 Jul 2008 09:08:49 +0000 (11:08 +0200)]
modesetting-101: Rename DPMS modes to avoid compatibility issues with xorg definitions.
Maarten Maathuis [Sun, 6 Jul 2008 08:52:25 +0000 (10:52 +0200)]
modesetting-101: rename modeflags, as to avoid conflicts with the xorg definitions
Maarten Maathuis [Sun, 6 Jul 2008 08:11:33 +0000 (10:11 +0200)]
NV50: minor fix
Maarten Maathuis [Sat, 5 Jul 2008 18:17:49 +0000 (20:17 +0200)]
NV50: remove edid when monitor is gone, improve fbcon, misc fixes
- This should avoid switching crtc's when going to fbcon.
Maarten Maathuis [Sat, 5 Jul 2008 14:54:26 +0000 (16:54 +0200)]
NV50: fix switch_fb and connector_is_digital
Maarten Maathuis [Sat, 5 Jul 2008 10:04:07 +0000 (12:04 +0200)]
modesetting-101: Make the interface variable names a little more consistent + modeprint changes.
- All things are now called _id when they are id's.
- modeprint now accepts driver name as first argument.
Maarten Maathuis [Fri, 4 Jul 2008 16:47:59 +0000 (18:47 +0200)]
modesetting-101: tv_left_margin_property shouldn't be immutable.
Maarten Maathuis [Fri, 4 Jul 2008 15:37:45 +0000 (17:37 +0200)]
Forgot the 0'th element for the tv property.
Maarten Maathuis [Fri, 4 Jul 2008 15:28:04 +0000 (17:28 +0200)]
modesetting-101: Move some defines used for enumeration into the public header.
- Otherwise userspace has no idea of the meaning.
Maarten Maathuis [Fri, 4 Jul 2008 15:17:11 +0000 (17:17 +0200)]
[modesetting-101] Add subconnector and select_subconnector properties.
- These facilitate DVI-I and tv-out that can drive multiple types of signals.
Dave Airlie [Thu, 3 Jul 2008 23:34:24 +0000 (09:34 +1000)]
modesetting: rip out all of the generation code.
not needed, hotplug will work just as well hopefully.
Maarten Maathuis [Thu, 3 Jul 2008 15:25:37 +0000 (17:25 +0200)]
libdrm: fix typo in comment
Maarten Maathuis [Thu, 3 Jul 2008 07:08:01 +0000 (09:08 +0200)]
nv50: s/FALSE/false && s/TRUE/true
Maarten Maathuis [Thu, 3 Jul 2008 06:07:35 +0000 (08:07 +0200)]
[drm-sysfs] connected is ambigious in the context of a connector, replace with enabled
Maarten Maathuis [Thu, 3 Jul 2008 05:18:18 +0000 (07:18 +0200)]
NV50: replace active by enabled
Maarten Maathuis [Wed, 2 Jul 2008 23:05:07 +0000 (01:05 +0200)]
[modeseting-101] add connected field to sysfs
Maarten Maathuis [Wed, 2 Jul 2008 22:30:00 +0000 (00:30 +0200)]
Forgot to fix the modeprint test.
Maarten Maathuis [Wed, 2 Jul 2008 22:25:06 +0000 (00:25 +0200)]
[libdrm] count connectors and such has no place in a crtc object
Dave Airlie [Wed, 2 Jul 2008 22:05:51 +0000 (08:05 +1000)]
modesetting: lookup blob using correct identifier.
blob is a blob not a connector
Jakob Bornecrantz [Wed, 2 Jul 2008 22:03:48 +0000 (00:03 +0200)]
tests: Fix faulty error messages in modeprint
Dave Airlie [Wed, 2 Jul 2008 22:00:39 +0000 (08:00 +1000)]
drm: fix encoders get permissions
Jakob Bornecrantz [Wed, 2 Jul 2008 21:12:33 +0000 (23:12 +0200)]
tests: modeprint s/fb/fd/
Jakob Bornecrantz [Wed, 2 Jul 2008 20:46:44 +0000 (22:46 +0200)]
tests: Updated modeprint
Maarten Maathuis [Wed, 2 Jul 2008 14:13:54 +0000 (16:13 +0200)]
NV50: basic fbcon + misc fixes
- There is one fb, used for as many outputs as possible.
- Eventually smaller screens will be scaled to see the full console, but for the moment this'll do.
Jakob Bornecrantz [Wed, 2 Jul 2008 11:59:19 +0000 (13:59 +0200)]
tests: Improved and renamed the mode app to modeprint
Maarten Maathuis [Tue, 1 Jul 2008 14:00:09 +0000 (16:00 +0200)]
NV50: switch to fixed point scale factor calculations
Maarten Maathuis [Tue, 1 Jul 2008 13:14:30 +0000 (15:14 +0200)]
NV50: some i2c cleanup
Maarten Maathuis [Fri, 27 Jun 2008 16:58:13 +0000 (18:58 +0200)]
NV50: use list_head item instead of list_head head to avoid confusion
Maarten Maathuis [Fri, 27 Jun 2008 16:45:08 +0000 (18:45 +0200)]
Change some obviously wrong things about property blobs, still broken though.
- I do not fully understand these blobs, so i'm leaving it at this for the moment.
Maarten Maathuis [Fri, 27 Jun 2008 14:30:25 +0000 (16:30 +0200)]
[modesetting-101] Actually store properties when being changed.
Maarten Maathuis [Thu, 26 Jun 2008 23:29:30 +0000 (01:29 +0200)]
NV50: A minor change.
Maarten Maathuis [Thu, 26 Jun 2008 23:16:36 +0000 (01:16 +0200)]
NV50: Implement DPMS.
Maarten Maathuis [Thu, 26 Jun 2008 21:21:01 +0000 (23:21 +0200)]
[modesetting-101] tab-cleanup
Maarten Maathuis [Thu, 26 Jun 2008 21:12:04 +0000 (23:12 +0200)]
Revert "modesetting-101: Make dpms property optional + misc cleanup."
This reverts commit
13943fe5823c45759091c1a1f487a4abe377421e.
Maarten Maathuis [Thu, 26 Jun 2008 19:28:29 +0000 (21:28 +0200)]
modesetting-101: Make dpms property optional + misc cleanup.
- intel_crt seems the only one to provide it, so init it there.
Maarten Maathuis [Wed, 25 Jun 2008 13:27:07 +0000 (15:27 +0200)]
NV50: i misunderstood NOUVEAU_MEM_INTERNAL, so remove it
Maarten Maathuis [Wed, 25 Jun 2008 13:16:38 +0000 (15:16 +0200)]
NV50: Some cleanup and fixes.
Ben Skeggs [Wed, 25 Jun 2008 06:45:41 +0000 (16:45 +1000)]
nv50: when destroying a channel make sure it's not still current on PFIFO
We won't get a PFIFO context switch when the same channel ID is recreated if
the hw still thinks the channel is already active, which causes fun issues.
Should allow X to be stopped and started without tearing down the entire
card state in lastclose().
Ben Skeggs [Sun, 22 Jun 2008 15:00:42 +0000 (01:00 +1000)]
nouveau: allocate drm-use vram buffers from end of vram.
This avoids seeing garbage from engine setup etc before X gets around
to pointing the CRTCs at a new scanout buffer. Not actually a noticable
problem before G80 as PRAMIN is forced to the end of VRAM by the hardware
already.
root [Tue, 24 Jun 2008 22:18:29 +0000 (23:18 +0100)]
silence warning
Keith Packard [Tue, 24 Jun 2008 20:39:25 +0000 (13:39 -0700)]
[intel] Get vblank pipe from irq_mask_reg instead of hardware enable reg
With the interrupt enable/disable using only the mask register, it was wrong
to use the enable register to detect which pipes had vblank detection
turned on. Also, as we keep a local copy of the mask register around, and
MSI machines smack the hardware during the interrupt handler, it is more
efficient and more correct to use the local copy.
Keith Packard [Tue, 24 Jun 2008 20:08:04 +0000 (13:08 -0700)]
[intel] Create functions to enable/disable interrupts
This shares common code sequences for managing the interrupt register bits
Maarten Maathuis [Tue, 24 Jun 2008 18:29:08 +0000 (20:29 +0200)]
NV50: minor change
Keith Packard [Tue, 24 Jun 2008 17:03:05 +0000 (10:03 -0700)]
Merge branch 'drm-gem' into drm-gem-965
Keith Packard [Tue, 24 Jun 2008 05:03:33 +0000 (22:03 -0700)]
[intel-gem] Include drm_compat.h to get kmap_atomic_prot_pfn
Keith Packard [Tue, 24 Jun 2008 05:03:06 +0000 (22:03 -0700)]
drm_compat: it's CONFIG_HIGHMEM, not CONFIG_HIMEM
A mis-spelled config option (was it spelled that way in the past?)
eliminated kmap_atomic_prot_pfn from core DRM.
Keith Packard [Mon, 23 Jun 2008 18:21:30 +0000 (11:21 -0700)]
[intel-gem] Use I915_GEM_DOMAIN_GTT in dri_gem_bo_wait_rendering.
I915_GEM_DOMAIN_CPU is very expensive to wait for -- it generally requires
clflushing the frame buffer.
Keith Packard [Mon, 23 Jun 2008 17:16:35 +0000 (10:16 -0700)]
[intel-gem] Recover resources from wedged hardware.
Clean up queues, free objects. On the next entervt, unmark the hardware to
let the user try again (presumably after resetting the chip). Someday we'll
automatically recover...
Keith Packard [Mon, 23 Jun 2008 07:53:53 +0000 (00:53 -0700)]
[intel-gem] pwrite through GTT
Pin/copy_from_user/unpin through the GTT to eliminate clflush costs.
Benchmarks say this helps quite a bit.
Keith Packard [Tue, 24 Jun 2008 16:46:51 +0000 (09:46 -0700)]
Was using irq_enable_reg in the use_mask_reg path
Maarten Maathuis [Tue, 24 Jun 2008 10:38:57 +0000 (12:38 +0200)]
NV50: fix a few misc things
Maarten Maathuis [Tue, 24 Jun 2008 08:16:52 +0000 (10:16 +0200)]
NV50: fix cursor hide/show
Maarten Maathuis [Tue, 24 Jun 2008 07:41:13 +0000 (09:41 +0200)]
NV50: These are actually errors.
Keith Packard [Tue, 24 Jun 2008 05:03:33 +0000 (22:03 -0700)]
[intel-gem] Include drm_compat.h to get kmap_atomic_prot_pfn
Keith Packard [Tue, 24 Jun 2008 05:03:06 +0000 (22:03 -0700)]
drm_compat: it's CONFIG_HIGHMEM, not CONFIG_HIMEM
A mis-spelled config option (was it spelled that way in the past?)
eliminated kmap_atomic_prot_pfn from core DRM.
Maarten Maathuis [Mon, 23 Jun 2008 22:00:02 +0000 (00:00 +0200)]
NV50: fix some misc bugs
Maarten Maathuis [Mon, 23 Jun 2008 20:59:17 +0000 (22:59 +0200)]
[modesetting-101] update mode count after fill_modes.
- This avoids returning with a mode count of 0, thus not allocating space for the 2nd ioctl.
Maarten Maathuis [Mon, 23 Jun 2008 19:15:54 +0000 (21:15 +0200)]
libdrm: check for allocation failure
Maarten Maathuis [Mon, 23 Jun 2008 18:33:32 +0000 (20:33 +0200)]
NV50: Improve set_config and fix some minor bugs.