Commit graph

358 commits

Author SHA1 Message Date
Dave Airlie
280083d4a2 use krh's idr mods to remove lists from idr code 2007-06-10 15:40:21 +10:00
Dave Airlie
4294dcc050 complete PCIE backend for ttm
ttm test runs with it at least, needs to do more testing on it
2007-06-05 12:26:06 +10:00
Dave Airlie
234a906200 WIP cleanup 2007-06-05 10:47:42 +10:00
Dave Airlie
77b9d9d16b cleanup pcigart ttm for new backend layout 2007-06-05 10:35:41 +10:00
Dave Airlie
07345af838 Merge branch 'origin' into radeon-ttm
Conflicts:

	shared-core/radeon_drv.h
2007-06-05 10:09:11 +10:00
root
a4cddc6596 Revert "drm: add new drm_wait_on function to replace macro"
This reverts commit 6e860d08d0.

As I said not a good plan - this macro will have to stay for now,
trying to do the vbl code with the inline was a bit messy - may need specialised
drm wait on functions
2007-06-03 18:12:28 +10:00
Dave Airlie
056c2f249a drm: move context handling code to use linux idr 2007-05-27 08:44:38 +10:00
Dave Airlie
f64674743a drm: convert drawable handling to use Linux idr
This cleans this code up a lot and uses the generic Linux idr which is
designed for this.

Signed-off-by: Dave Airlie <airlied@linux.ie>
2007-05-27 07:26:52 +10:00
Dave Airlie
7b48f0022a drm: cleanup use of Linux list handling macros
This makes the drms use of the list handling macros a lot cleaner
and more along the lines of how they should be used.
2007-05-26 04:26:24 +10:00
Alan Hourihane
315cf14af8 Merge branch 'master' of git+ssh://git.freedesktop.org/git/mesa/drm into modesetting-101
Conflicts:

	shared-core/i915_dma.c
2007-05-18 13:48:56 +01:00
Jesse Barnes
b7bf317f42 Merge branch 'modesetting-101' of git+ssh://git.freedesktop.org/git/mesa/drm into origin/modesetting-101
Conflicts:

	linux-core/drm_crtc.c
	linux-core/drm_fb.c

Lots of changes to merge with alanh's latest stuff:
  o fix use of fb->pitch now that it has the right value
  o add new helper for finding the CRTC given an FB
  o fix new fb_probe/fb_remove functions to take a CRTC
  o fixup callers of new FB routines
  o port drm_fb changes to intel_fb
  o check for errors after creating fb buffer object
  o go back to using cfb_imageblit since the accel stubs aren't ready
2007-05-17 10:35:07 -07:00
Jesse Barnes
a18b4befb9 Fix FB pitch value (we had it wrong and were working around it in a few
places).
Add new FB hooks to the drm driver structure and make i915 use them for an
Intel specific FB driver.  This will allow acceleration and better handling
of the command stream.
2007-05-17 09:00:06 -07:00
Dave Airlie
6e860d08d0 drm: add new drm_wait_on function to replace macro 2007-04-28 15:07:43 +10:00
Dave Airlie
9f9c19065c remove DRM_GETSAREA and replace with drm_getsarea function 2007-04-28 15:07:43 +10:00
Dave Airlie
b589b846e7 Merge branch 'origin' into modesetting-101 2007-04-26 15:56:21 +10:00
Thomas Hellstrom
2df2c70e20 Simplify the ttm backend interface and the agp ttm backend. 2007-04-18 16:33:28 +02:00
Dave Airlie
79aa1d5474 another large overhaul of interactions with userspace...
We need to keep a list of user created fbs to nuke on master exit.
We also need to use the bo properly.
2007-04-17 18:16:38 +10:00
Alan Hourihane
a85440c8a6 Remove extraneous drm_crtc.h include 2007-04-12 15:11:38 +01:00
Alan Hourihane
9420ab4b41 Merge remote branch 'origin/modesetting-101' into modesetting-101 2007-04-12 15:10:08 +01:00
Dave Airlie
ed0ebd9d3d make crtc_config be named mode_config
X.org calls this crtc_config but this is a bad name and will confuse ppl later
(and me now :-)
2007-04-10 18:56:02 +10:00
Dave Airlie
a70f8e0ab2 radeon: add support for reverse engineered xpress200m
The IGPGART setup code was traced using mmio-trace on fglrx by myself
and Phillip Ezolt <phillipezolt@gmail.com> on dri-devel.

This code doesn't let the 3D driver work properly as the card has no
vertex shader support.

Thanks to Matthew Garrett + Ubuntu for providing me some hardware to do this
work on.
2007-04-09 21:52:59 +10:00
Jesse Barnes
a35ba455b2 make drmP.h include drm_crtc.h for CRTC related stuff.
fixup drm_crtc.c so it matches VGA and other outputs properly.
make drm_crtc.c less verbose.
add function declarations in drm_crtc.h for other files.
2007-04-07 19:22:39 -07:00
Dave Airlie
52f9028c84 Initial import of modesetting for intel driver in DRM 2007-04-05 11:21:06 +10:00
Dave Airlie
29ac7b1fe3 radeon: add setup for PCIE GART ttm 2007-04-03 21:20:00 +10:00
Dave Airlie
e835820e23 add initial PCIE GART framework for TTM 2007-04-03 19:04:48 +10:00
Dave Airlie
2d7ecb8422 more tab/space conversion 2007-03-19 08:29:07 +11:00
Dave Airlie
2463b03cb4 whitespace cleanup pending a kernel merge 2007-03-19 08:23:43 +11:00
Dave Airlie
c9178c3d01 ati: make pcigart code able to handle variable size PCI GART aperture
This code doesn't enable a variable aperture it just modifies the codebase
to allow me fix it up later
2007-03-04 18:16:29 +11:00
Jay Estabrook
6a51da7325 Fix Alpha domain/bus issue 2007-02-27 08:56:20 +00:00
Thomas Hellstrom
a78f70faad Merge branch 'ttm-vram-0-1-branch' 2007-02-14 15:33:40 +01:00
Thomas Hellstrom
1345076c8f Rename drm_ttm.h to drm_objects.h
Fix up some header incompatibilities in drm_fence.c caused by the previous
commit.
2007-02-14 14:10:10 +01:00
Thomas Hellstrom
8ffc1844b0 Move fence- and buffer-object related header stuff to drm_ttm.h 2007-02-14 14:05:40 +01:00
Thomas Hellstrom
5c9a7b0f94 Remove an intel-specific hack and replace it with a fence driver callback. 2007-02-14 13:31:35 +01:00
Thomas Hellstrom
04760563b8 Set the drm bus map type for each buffer object memory type. 2007-02-14 12:39:02 +01:00
Thomas Hellstrom
e1460426b8 Bugzilla Bug #9457
Add refcounting of user waiters to the DRM hardware lock, so that we can use the
DRM_LOCK_CONT flag more conservatively.

Also add a kernel waiter refcount that if nonzero transfers the lock for the kernel context,
when it is released. This is useful when waiting for idle and can be used
for very simple fence object driver implementations for the new memory manager.

It also resolves the AIGLX startup deadlock for the sis and the via drivers.
i810, i830 still require that the hardware lock is really taken so the deadlock remains
for those two. I'm not sure about ffb. Anyone familiar with that code?
2007-02-13 20:47:30 +01:00
Thomas Hellstrom
9efdae317c More bugfixes.
Fixed memory, pinned buffers and unmappable memory now seems
fully functional.
2007-02-13 20:05:32 +01:00
Thomas Hellstrom
f02f83ee08 Cleanup and fix support for pinned buffers. 2007-02-12 17:47:57 +01:00
Thomas Hellstrom
b2bcbf874b Add an accelerated buffer copy cleanup helper.
Export helper functions and make some important buffer-object functions non-static.
Add an i915 accelerated blit buffer move for pci memory buffers.
2007-02-08 21:28:33 +01:00
Thomas Hellstrom
bf8f46d4c6 Fix mm_block leak.
Some other minor fixes.
2007-02-08 18:59:02 +01:00
Thomas Hellstrom
e4b2da4406 A minor function interface change and some memcpy bugfixing.
Hooray!! it sort of works with a fixed AGP area as faked VRAM.
2007-02-08 16:21:38 +01:00
Thomas Hellstrom
1257907fa9 Simplify external ttm page allocation.
Implement a memcpy fallback for copying between buffers.
2007-02-08 13:29:08 +01:00
Thomas Hellstrom
c1fbd8a566 Checkpoint commit.
Flag handling and memory type selection cleanup.
glxgears won't start.
2007-02-07 17:25:13 +01:00
Thomas Hellstrom
af24465b2e Fix a stray unlock_kernel() in drm_vm.c
Add a file for memory move helpers, drm_bo_move.c
Implement generic memory move.
Cached, no_move and unmapped memory temporarily broken.
2007-02-07 12:52:23 +01:00
Thomas Hellstrom
71b9e876f9 Simplify pci map vs no pci map choice. 2007-02-06 16:59:45 +01:00
Thomas Hellstrom
40ce53dfde Implement a drm_mem_reg_t substructure in the buffer object type. 2007-02-06 15:56:43 +01:00
Thomas Hellstrom
609e3b0375 Implement a policy for selecting memory types. 2007-02-06 14:20:33 +01:00
Thomas Hellstrom
63f2abd721 Make also later kernels work with buffer object vm
and clean up some function names.
2007-02-02 19:49:11 +01:00
Thomas Hellstrom
c269d560e4 Make vm handle buffer objects instead of ttm objects.
Remove ttm objects.
Make vm aware of PCI memory type buffer objects.
(Only works for pre 2.6.16 kernels for now).
2007-02-02 14:47:44 +01:00
Thomas Hellstrom
dd733dea38 Fix missing ttm_open_vma call from previous commit.
Honour the ttm backend cant-use-aperture flag.
2007-02-01 13:19:05 +01:00
Thomas Hellstrom
9677c5ecc6 Prepare for removal of the ttm_object type. 2007-02-01 10:53:55 +01:00