Commit Graph

2965 Commits

Author SHA1 Message Date
Eric Anholt 7b7c724da9 Remove remaining fbOffset setting.
In the long long ago, fbOffset was used for DGA.  The server now has
only one reference to fbOffset, a leftover setting of it in fbdevhw.
We can safely ignore it now, which is good since we weren't updating
it in other places where the front buffer offset could change.
2010-03-04 11:25:14 -08:00
Eric Anholt 15026d64d3 Remove a piece of fbOffset cruft from non-DRM support. 2010-03-04 11:25:14 -08:00
Eric Anholt e8e6152892 Remove i830_allocate_2d_memory() now that it only called one function. 2010-03-04 11:25:14 -08:00
Eric Anholt e37b562083 Init CRTC cursors with CRTC setup instead of i830_memory. 2010-03-04 11:25:12 -08:00
Eric Anholt a36bdaba61 Remove intel_sync() at teardown time.
The kernel's still running after we're gone.  This didn't matter.
2010-03-04 10:13:34 -08:00
Eric Anholt 4ada6d7a85 Remove 3D state clobber on EnterVT, and always clobber at batch start.
We know that it's clobbered at each batchbuffer, anyway.  And even if
this server isn't running DRI2, it can still be clobbered at batch
start in the KMS world.
2010-03-04 10:13:34 -08:00
Eric Anholt d92d42303e Remove pre-2.6.29 error message handling since we require KMS. 2010-03-04 10:13:34 -08:00
Eric Anholt faecd155c4 Move batch and 965 render state setup/teardown to screen init/close.
Whether we're VT switched or not shouldn't impact rendering.
2010-03-04 10:13:34 -08:00
Carl Worth 74e2b69a31 i915_hwmc: Remove dead code.
Daniel recently identified this code as unneeded (with an #if 0).
Here we take the next step and remove it entirely.
2010-03-04 09:51:03 -08:00
Carl Worth 1cc35a8ba4 uxa: Fix type mismatch to avoid compiler warning.
The code was using uint32_t where an XID (currently an unsigned long)
was specified in the prototype. Use XID to avoid both the warning and
any potential problem.
2010-03-04 09:46:33 -08:00
Carl Worth 1d6537ec57 i830_video: Remove unused variable.
Certainly just a little leftover from the recent rewrites.
2010-03-04 09:39:28 -08:00
Daniel Vetter 57c0043b9a Xv: fixup relocation in i965_video.c
The previous code made no sense, (multiplying an offset by 4 is
meaningless). It could have onlt worked with the offset being
fortuitously 0.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Carl Worth <cworth@cworth.org>
2010-03-04 09:38:38 -08:00
Daniel Vetter e606be463f i830_memory: rip out the remainings of the old allocator
Yeah!

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Carl Worth <cworth@cworth.org>
2010-03-04 09:38:38 -08:00
Daniel Vetter 371be65fb7 XvMC: kill the pinned batchbuffer in the ddx code
It's been unused for quite a while.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Carl Worth <cworth@cworth.org>
2010-03-04 09:38:38 -08:00
Daniel Vetter d5a20c81ab i915 XvMC: kill pinned surface buffer in the ddx code
Like with the per context stuff, also drop the now artificial limit
on surfaces. Again, with that gone, a lot of code can be deleted.

Reviewed-by: Carl Worth <cworth@cworth.org>
2010-03-04 09:38:38 -08:00
Daniel Vetter e6eb257ad3 i915 XvMC: kill pinned per-context buffers in the ddx code
There's now not a reason anymore to limit the number of active contexts.
So kill this accounting, too.

With that all gone, per-context state in the ddx is nil, so rip out
all associated code.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Carl Worth <cworth@cworth.org>
2010-03-04 09:38:38 -08:00
Daniel Vetter 47ae1181f6 i915 XvMC: don't stall the cpu anymore
Proper bo management ensures that the cpu doesn't step on buffers
used by the gpu. Drop the now unnecessary synchronization.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Carl Worth <cworth@cworth.org>
2010-03-04 09:38:38 -08:00
Daniel Vetter 9bba123c5f i915 XvMC: drop superflous MI_FLUSH
Cache coherency is now fully under the control of gem.

For lack of hw documentation, I had to find out the correct cache
placements by trial and error:

Backward and forward surfaces: I915_GEM_DOMAIN_RENDER
Correlation data:              I915_GEM_DOMAIN_SAMPLER

Changing any of them leads to visual corruptions, so I think these
are the correct ones.

Reviewed-by: Carl Worth <cworth@cworth.org>
2010-03-04 09:38:38 -08:00
Daniel Vetter b11623f20e i915 XvMC: switch surfaces to drm_intel_bo
Now the last user of the fixed buffers provided by the ddx is gone!

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Carl Worth <cworth@cworth.org>
2010-03-04 09:38:38 -08:00
Daniel Vetter b7f79bfd40 i915 XvMC: switch corrdata buffer to drm_intel_bo
It works!

v2: Correlation data needs to be in the render cache!

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Carl Worth <cworth@cworth.org>
2010-03-04 09:38:37 -08:00
Daniel Vetter 62846d88d4 i915 XvMC: switch msb to drm_intel_bo
Like for the static indirect state buffer.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Carl Worth <cworth@cworth.org>
2010-03-04 09:38:37 -08:00
Daniel Vetter d27955c697 i915 XvMC: switch sis to drm_intel_bo
I've decided to allocate a new buffer for every render command, to
prevent stalling for the gpu. libdrm bo reuse should take care of
not wasting memory in case the buffer is not busy.

Also always emit the full state, it's not worth it to complicate
the code over a few stores to wc memory.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Carl Worth <cworth@cworth.org>
2010-03-04 09:38:37 -08:00
Daniel Vetter 3203c66fbf i915 XvMC: switch load_indirect_render_emit to batchbuffer macros
Like with one_time_state_emit, this preps for relocatable bo's.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Carl Worth <cworth@cworth.org>
2010-03-04 09:38:37 -08:00
Daniel Vetter d30decae6a i915 XvMC: switch psc to drm_intel_bo
Like with the sampler state buffer.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Carl Worth <cworth@cworth.org>
2010-03-04 09:38:37 -08:00
Daniel Vetter b543c355f4 i915 XvMC: switch psp to drm_intel_bo
Like with the sampler state buffer.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Carl Worth <cworth@cworth.org>
2010-03-04 09:38:37 -08:00
Daniel Vetter 18c364084c i915 XvMC: switch ssb to drm_intel_bo
This also starts to kill the last remnants of the support for
physical addresses for the indirect state buffers. With gem this
would need kernel support (in the form of a new reloc type in
execbuf2).

This does not change the ABI between ddx and client libIntelXvMC.
I've decided to do this in one swoop when all the buffer rework is
done.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Carl Worth <cworth@cworth.org>
2010-03-04 09:38:37 -08:00
Daniel Vetter fc9e44f019 i915 XvMC: kill last_flip and last_render
Seems to be a remnant from i810 XvMC support. last_flip is always 0,
so serves no real purpose anymore. Kill it and the associated code.

With last_flip gone, last_render also lost its purpose. Kill it, too.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Carl Worth <cworth@cworth.org>
2010-03-04 09:38:37 -08:00
Daniel Vetter 04aa38a639 i915 XvMC: switch one_time_state_emit to batchbuffer macros
This is in preparation for real relocatable drm_bo's instead
of memory at a fixed address. By switching to the batchbuffer
macros (like i965 xvmc) we can use the nice OUT_RELOC macro.

Also align the code more with coding-style elsewhere, i.e. bitops
instead of bitfield structures. The bitfield structures are
quite a mess to work with the batchbuffer macros, so they were
getting in the way, anyway.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Carl Worth <cworth@cworth.org>
2010-03-04 09:38:37 -08:00
Daniel Vetter 24d787335a XvMC: kill dead code in i915_xvmc.c
WIP code that hasn't changed for over two years is unlikely to
suddenly start progressing. Drop it. After all, git can easily
resurect it in cases it's needed.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Carl Worth <cworth@cworth.org>
2010-03-04 09:38:37 -08:00
Daniel Vetter 13266b152a XvMC: kill i830_memory in 965 class xvmc
Yes, this breaks binary compat of the struct passed around between
X ddx and the client libXvMC. But we always ship both, so they should
not get out of sync.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Carl Worth <cworth@cworth.org>
2010-03-04 09:38:37 -08:00
Daniel Vetter d39d822cf8 i830_memory: hide as much of the old memory allocator as possible
The only user left of this stuff is the xvmc support.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Eric Anholt <eric@anholt.net>
2010-03-04 09:38:37 -08:00
Daniel Vetter 65267d4bfb i830_memory: switch frontbuffer to drm_intel_bo
Yet another user of i830_memory gone for good.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Eric Anholt <eric@anholt.net>
2010-03-04 09:38:37 -08:00
Daniel Vetter 06f147dc04 i830_memory: switch cursors to drm_intel_bo
Minus one user of i830_memory, some more to go.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Eric Anholt <eric@anholt.net>
2010-03-04 09:38:37 -08:00
Daniel Vetter 23d12e3b08 i830_memory: kill field "pitch"
Totally unused.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Eric Anholt <eric@anholt.net>
2010-03-04 09:38:37 -08:00
Daniel Vetter 2fb8feeb56 i830_memory: rip out field "size"
Use the one in the drm bo instead.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Eric Anholt <eric@anholt.net>
2010-03-04 09:38:37 -08:00
Daniel Vetter 4d4d763b3d i830_memory: kill field "tiling_mode"
Totally unused.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Eric Anholt <eric@anholt.net>
2010-03-04 09:38:37 -08:00
Daniel Vetter d0800d0987 i830_memory: no memory allocations without a bo!
Kill the corresponding !bo path in i830_free_memory.

Also kill another remnant of the pre-kms era in the same file, while I
was looking at the code.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Eric Anholt <eric@anholt.net>
2010-03-04 09:38:37 -08:00
Daniel Vetter 086c0e25ca i830_memory: rename i830_bind_all_memory to reflect code reality
It doesn't bind anything anymore, but does a few random things.
Give it a hopefully vague enough name to cover all cases ;)

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Eric Anholt <eric@anholt.net>
2010-03-04 09:38:37 -08:00
Daniel Vetter 2a989aa057 i830_memory: rip out the old video memory allocator
Besides the debug stuff the went away in the previous patch,
this stuff was totally unused ...

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Eric Anholt <eric@anholt.net>
2010-03-04 09:38:37 -08:00
Daniel Vetter bf83b9a102 i830_memory: kill i830_desribe_allocations
Totally useless debug function from the pre-gem era. No point
to occasionally spam Xorg.log with a bogus "No memory allocations"
message.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Eric Anholt <eric@anholt.net>
2010-03-04 09:38:37 -08:00
Daniel Vetter ff8a1e1cf7 i830_memory: rip out field "offset"
Use the one in the drm bo instead.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Eric Anholt <eric@anholt.net>
2010-03-04 09:38:37 -08:00
Daniel Vetter e18ffceb14 i830_memory: rip out field "end"
It's a left-over from the non-gem era and no longer used at all.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Eric Anholt <eric@anholt.net>
2010-03-04 09:38:37 -08:00
Daniel Vetter 5018fd3097 libIntelXvMC: kill ums leftovers
On i965 class hw, kernel_exec_fencing was 1 always, anyway. And on
i945, this patch kills a memory leak (dunno how, but it does).

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2010-03-04 09:38:17 -08:00
Daniel Vetter cb06aa32d4 Xv: fixup XvMC on i915
I've accidentally broken i915 xvmc due to alignment constrains that
break my assumption that Y-pitch == UV-pitch*2. Fix this up by consistenly
using dstPitch2 for the Y-pitch. This also unifies the dst pitch
computation slightly, now that the i915 xvmc special case is gone.

Bugzilla: http://bugs.freedesktop.org/show_bug.cgi?id=25949

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>

(Minor edit to support compilation without INTEL_XVMC defined by
Carl Worth <cworth@cworth.org>)
2010-03-04 09:38:11 -08:00
Daniel Vetter 80f2a1f3b5 Xv: fixup YUV plane offset for xvmc case
In my previous cleanup I've inadvertedly dropped the offset adjustment
code for the xvmc passthrough case. Fix this up.

Also reimplement that ugly hack I've accidently killed to keep i915 class
xvmc a tad bit longer on life support.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Tested-by: xunx.fang@intel.com
2010-03-04 09:36:21 -08:00
Carl Worth a0ee9c3d9c Update version number to 2.10.901
In order to make a new snapshot.
2010-02-26 17:05:45 -08:00
Carl Worth 63b8e890a1 NEWS: Add notes for the 2.10.901 snapshot.
From skimming the git lot since 2.10.0.
2010-02-26 17:05:06 -08:00
Carl Worth d540930312 Remove dead code: fill_detailed_lvds_block
All callers of this function were recently removed, so it can join
them in the bit bucket.
2010-02-26 16:13:25 -08:00
Adam Jackson 7d0e6ff4da kms: Fix LVDS mode list construction.
Rather than mangle the EDID block and hope the server does the right
thing, just build a sensible mode list up front.  Do this for LVDS where
there is no EDID or where it does not claim to be continuous-frequency
(since in the latter case, the server will add reasonable modes for us).

Signed-off-by: Adam Jackson <ajax@redhat.com>
2010-02-26 16:10:34 -08:00
Carl Worth 1730af4437 NEWS: Fix typo (we just released 2.10 *not* 1.10)
Sigh. Every version number that must be typed manually will eventually
be typed incorrectly at some release. (I think that's Owne Taylor's
Law)
2010-02-25 17:24:13 -08:00