Alan Hourihane
b6dc381fab
Merge branch 'master' of git+ssh://git.freedesktop.org/git/mesa/drm into modesetting-101
...
Conflicts:
shared-core/i915_dma.c
shared-core/i915_drv.h
shared-core/i915_irq.c
2008-03-12 10:18:33 +00:00
Thomas Hellstrom
8a18d123f5
Avoid large kmallocs.
2008-03-12 09:49:27 +01:00
Dave Airlie
e00dea812d
Merge branch 'master' of ../../drm into modesetting-101
...
Conflicts:
linux-core/drmP.h
linux-core/drm_drv.c
linux-core/drm_proc.c
linux-core/drm_stub.c
linux-core/drm_sysfs.c
2008-03-06 05:26:23 +10:00
Dave Airlie
12574590cd
drm: reorganise minor number handling using code from modesetting branch
...
Rip out the whole head thing and replace it with an idr and drm_minor
structure.
2008-03-06 05:21:50 +10:00
Xiang, Haihao
638353103d
i915: Evict if relocatee buffer is CACHED_MAPPED before
...
writting relocations, otherwise the GPU probably sees some
inconsistent data. Fix fd.o bug#14656
2008-03-05 15:09:17 +08:00
Dave Airlie
43891ff2d0
Merge remote branch 'origin/master' into modesetting-101
...
Conflicts:
linux-core/drm_compat.c
2008-03-05 10:37:02 +10:00
Alan Hourihane
9c5ba9f5d1
Add FENCE registers to MMIO list
2008-03-02 21:48:40 +00:00
Dave Airlie
01dcc47d89
drm: add modesetting as a driver feature.
...
This change adds a driver feature that for i915 is controlled by a module
parameter. You now need to do insmod i915.ko modeset=1 to enable it the
modesetting paths.
It also fixes up lots of X paths. I can run my new DDX driver on this code
with and without modesetting enabled
2008-02-28 16:24:17 +10:00
Thomas Hellstrom
fd595fa4dc
Reinstate buffer idle before applying relocations.
2008-02-27 21:44:40 +01:00
Thomas Hellstrom
72983ff301
Don't wait for buffer idle before applying relocations.
2008-02-27 19:46:28 +01:00
Alan Hourihane
1e66322633
Merge branch 'master' of git+ssh://git.freedesktop.org/git/mesa/drm into modesetting-101
...
Conflicts:
shared-core/i915_dma.c
2008-02-26 15:42:41 +00:00
Thomas Hellstrom
e87cec1968
[i915] Relocation fixes.
2008-02-26 10:47:05 +01:00
Dave Airlie
b92e343dc4
i915: fix typos
2008-02-26 16:20:27 +10:00
Dave Airlie
35d1b13b4a
i915_mmio: add overlay regs
2008-02-26 16:13:06 +10:00
Thomas Hellstrom
56bb29cf37
Make the execbuffer code reasonably safe against errors.
...
In particular -EAGAINs, which should be common during Xserver operation.
Also handle the fence creation failure case.
2008-02-26 00:05:26 +01:00
Kristian Høgsberg
b7086e6ae5
Fix one last occurance of struct _drm_i915_batchbuffer.
...
Thanks to Todd Merrill for pointing it out.
2008-02-22 11:22:52 -05:00
Alan Hourihane
8caf6e9571
Fix up conflicts for DRI2 (untested)
2008-02-19 15:17:24 +00:00
Alan Hourihane
f24ed2ad6c
Merge branch 'master' of git+ssh://git.freedesktop.org/git/mesa/drm into modesetting-101
...
Conflicts:
linux-core/i915_fence.c
linux-core/via_fence.c
shared-core/i915_dma.c
shared-core/i915_drv.h
shared-core/i915_irq.c
2008-02-18 22:35:46 +00:00
Dave Airlie
8bf8cd63bb
missing bits
2008-02-14 07:37:34 +10:00
Kristian Høgsberg
373dbcf8b2
i915: Add a dri2 init path that gets the lock from the dri2 sarea.
2008-02-13 13:34:02 -05:00
Kristian Høgsberg
db3f03ae35
i915: Only look up dev_priv->mmio_map if it's not already set up
2008-02-13 13:34:02 -05:00
Kristian Høgsberg
ee15459483
i915: Add I915_PARAM_CHIPSET_ID param to get chipset ID.
2008-02-13 13:34:02 -05:00
Kristian Høgsberg
4feb0638f1
i915: Make sarea_priv setup optional.
2008-02-13 13:34:02 -05:00
Thomas Hellstrom
76748efae2
i915: Re-report breadcrumbs on poll to the fence manager,
...
since a breadcrumb may actually turn up before a corresponding fence object
has been placed on the fence ring.
2008-02-05 10:36:49 +01:00
Thomas Hellstrom
47ee6237fe
i915: Avoid calling drm_fence_flush_old excessively.
2008-01-30 22:14:02 +01:00
Thomas Hellstrom
f1edb7ad91
Simplify the fencing code and differentiate between flushes and
...
waiting types.
Add a "command_stream_barrier" method to the bo driver.
2008-01-30 22:06:02 +01:00
Dave Airlie
fa7b779c91
don't reinit ring if already initialised
2008-01-25 16:32:09 +10:00
Dave Airlie
e7a41d7f5b
Merge remote branch 'origin/master' into modesetting-101
...
Conflicts:
linux-core/drm_bo.c
linux-core/drm_drv.c
shared-core/drm.h
shared-core/i915_dma.c
shared-core/i915_drv.h
shared-core/i915_irq.c
shared-core/radeon_irq.c
2008-01-25 15:27:53 +10:00
Dave Airlie
5b99306452
i915: fix missing header when copying data from userspace
2008-01-24 15:18:09 +10:00
Dave Airlie
34b71eb451
i915 make relocs use copy from user
...
Switch relocs to using copy from user and remove index and pass buffer
handles in instead.
2008-01-24 14:37:40 +10:00
Thomas Hellstrom
88c511e49d
Properly propagate the user-space fence flags.
...
This avoids a sync flush when user-space has already programmed
and MI_FLUSH in the batchbuffer.
2008-01-15 10:03:41 +01:00
Dave Airlie
10937cf20b
drm: move drm_head to drm_minor and fix up users
2008-01-04 16:12:24 +11:00
Márton Németh
9ab620d661
drm: cleanup DRM_DEBUG() parameters
...
As DRM_DEBUG macro already prints out the __FUNCTION__ string (see
drivers/char/drm/drmP.h), it is not worth doing this again. At some
other places the ending "\n" was added.
airlied:- I cleaned up a few that this patch missed also
2008-01-03 16:56:04 +10:00
Keith Packard
5f23519b14
Document drm_bo_handle_validate. Match drm_bo_do_validate parameter order.
...
Document parameters and usage for drm_bo_handle_validate. Change parameter
order to match drm_bo_do_validate (fence_class has been moved to after
flags, hint and mask values). Existing users of this function have been
changed, but out-of-tree users must be modified separately.
2007-12-15 12:10:42 -08:00
Alan Hourihane
f62a300547
Merge branch 'master' of git+ssh://git.freedesktop.org/git/mesa/drm into modesetting-101
2007-12-13 10:41:23 +00:00
Keith Packard
7dcaf0cdbb
Make relocation validate client computed values when debugging
2007-12-11 20:23:00 -08:00
Keith Packard
4ec8f58d04
i915: wait for buffer idle before writing relocations
...
When writing a relocation entry, make sure the target buffer is idle,
otherwise the GPU may see inconsistent data.
2007-12-11 20:23:00 -08:00
Keith Packard
57b9a54eb6
Allow relocation to be skipped when buffers don't move.
...
One of the costs of superioctl has been the need to perform relocations
inside the kernel. The cost of mapping the buffers to the CPU and writing
data is fairly high, especially if those buffers have been mapped and read
by the GPU.
If we assume that buffers don't move around very often, we can have the
client compute the relocations itself using the previous GPU address. When
that object doesn't move, the kernel can skip computing and writing the
updated data.
Here's a patch which adds a new field to struct drm_bo_info_req called
'presumed_offset', and a new DRM_BO_HINT_PRESUMED_OFFSET that is set when
this field has been filled in by the client.
There are two separate optimizations performed when the presumed_offset is
correct:
1. i915_exec_reloc checks to see if all previous buffer offsets were guessed
correctly. If so, there's no need for it to look at *any* of the
relocations for a buffer. When this happens, it skips the whole
relocation process, simply returning success.
2. i915_apply_reloc checks to see if the target buffer offset was guessed
correctly. If so, it skips mapping the relocatee, computing the
relocation and writing the value. If no relocations are needed, the
relocatee should never be mapped to the CPU, and so the kernel shouldn't
need to wait for any fences to pass.
2007-12-11 20:23:00 -08:00
Dave Airlie
8d2da20233
Merge branch 'master' of ssh://git.freedesktop.org/git/mesa/drm into modesetting-101
...
Conflicts:
linux-core/drm_drv.c
shared-core/drm.h
shared-core/i915_dma.c
2007-12-11 16:58:00 +10:00
Kristian Høgsberg
e38749ebe5
Remove references to the sarea_priv perf_boxes field.
...
This field isn't touched or read by any other code in the stack so it's
time to retire these last few references.
2007-12-05 14:43:22 -05:00
Robert Noland
b2f8368b57
Clarify order of operations
2007-12-01 14:44:30 -05:00
Robert Noland
453a295c82
DRM_DEBUG already prints the function name.
2007-12-01 14:44:29 -05:00
Robert Noland
d6295cc9ff
drm: Add _DRM_DRIVER map flag.
...
This flag indicates that the driver is responsible for the map.
2007-12-01 02:40:13 -05:00
Jiri Slaby
309b2c4c05
Beside the emitted warning, the added cast (u64 -> unsigned) strips out
...
part of address on 64 bit. Cast to unsigned long instead.
Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
2007-11-29 09:55:38 +10:00
Dave Airlie
dc338921f9
drm: more cleanups
2007-11-29 09:38:21 +10:00
Dave Airlie
e9fa8fe734
i965: oops force mi batchbuffer start
2007-11-28 22:46:06 +10:00
Dave Airlie
a20587e395
Merge branch 'origin' into modesetting-101
...
Conflicts:
linux-core/drmP.h
shared-core/i915_dma.c
shared-core/i915_drm.h
shared-core/radeon_drv.h
2007-11-22 17:17:06 +11:00
Dave Airlie
5dc5c36e62
drm: major whitespace/coding style realignment with kernel
2007-11-22 16:10:36 +10:00
Eric Anholt
3fc3fc082a
Fix capitalization of __linux__ define.
2007-11-19 08:41:23 -08:00
Robert Noland
a74181ddb2
Bug #13233 : Fix build on FreeBSD.
2007-11-18 22:42:40 -08:00