Commit Graph

2664 Commits

Author SHA1 Message Date
Xiang, Haihao 7dc95b4f1d XvMC: pin XvMC buffers under KMS.
Under KMS, the buffer allocated by i830_allocate_memory
isn't pinned anymore. However currently 915 XvMC needs
static offsets.

Fixes bug #22872
2009-07-24 10:39:05 +08:00
Eric Anholt 12c5aeca7a 8xx render: Add limited support for a8 dests.
This improves aa10text performance from 74k to 569k on my 855 laptop.
This also causes my 865 to hang on aa10text like it does on rgb10text,
thanks to actually hitting render accel.
2009-07-22 09:58:17 -07:00
Eric Anholt 6b7728491c Only align DRI2 tiled pixmaps to the DRI2 tiled pixmap alignment requirement.
This should save significant amounts of memory for glyph and other small
pixmap storage.

Bug #21387
2009-07-22 09:16:00 -07:00
Eric Anholt 22f7cbc32b uxa: Tell the driver when we're just going to immediately map the pixmap.
This lets the driver allocate a nice idle buffer object instead of a
busy one, reducing runtime of firefox-20090601 on my G45 from 50.7 (+/- .41%)
to 48.4 (+/- 1.1%).
2009-07-22 09:16:00 -07:00
Eric Anholt 5ef3db45e0 uxa: Skip fill of temporary alpha picture that just gets copied over.
This was needed when we were doing the mask computations in this pixmap,
but now they're done in a temporary and then uploaded later.

This reduces runtime of firefox-20090601 from 52.6 (+/- .96%) to 50.7
(+/- .41%) seconds on my G45.
2009-07-22 09:15:59 -07:00
Keith Packard 6f3fc6b20f drmmode_output_get_modes: Replace existing EDID property blob with new one
This synchronizes the X EDID data with the kernel EDID data each time the
kernel data may have changed. Otherwise, X ends up stuck with the first EDID
data it sees, failing to accomodate to different monitors.

Signed-off-by: Keith Packard <keithp@keithp.com>
2009-07-21 12:38:28 -07:00
Carl Worth 840a787a19 Merge branch '2.8' 2009-07-20 23:00:06 -07:00
Carl Worth 5d50a949b3 Increment version number to 2.8.0 for release. 2009-07-20 22:59:37 -07:00
Carl Worth b12220bd81 NEWS: Add notes for 2.8.0 release
Many thanks to Gordon for his notes from http://intellinuxgraphics.org/2009Q2.html
2009-07-20 22:59:02 -07:00
Peter Hutterer 0a4c4c5fe8 Update to xextproto 7.1 support.
DPMS header was split into dpms.h (client) and dpmsconst.h (server). Drivers
need to include dpmsconst.h if xextproto 7.1 is available.

SHM is now shm.h instead of shmstr. Requires definition of ShmFuncs that's
not exported by the server.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2009-07-18 12:10:18 +10:00
Owain Ainsworth 57c7cbade9 accessing a pixmap if prepare_access fails is verboten.
Don't do it, treat this the same as every other prepare access call in uxa.

Reviewed-by: Keith Packard <keithp@keithp.com>
Signed-off-by: Owain Ainsworth <zerooa@googlemail.com>
2009-07-17 11:28:29 -07:00
Eric Anholt bb30073842 Really fix i915 render. Fail at commit --amend. 2009-07-16 12:56:07 -07:00
Eric Anholt 8dd7ccf37e Fix 915-class Render after the 8xx-class Render fix.
The two shared i830_composite.c, so giving i830 atomic batch support
triggered anger about starting i830's atomic area while in i915's atomic
area.  Instead, split the emit-a-primitive stuff from the state emission.
2009-07-16 11:48:33 -07:00
Eric Anholt a1e6abb5ca Use batch_start_atomic to fix batchbuffer wrapping problems with 8xx render.
Bug #22483.
2009-07-15 15:11:21 -07:00
Keith Packard e386e7b14b Reset framebuffer offset when rebinding aperture (22760).
scrn->fbOffset may be changed when binding objects to the aperture during
server initialization or VT enter. This was accidentally removed when the
NoAlloc option was eliminated.

Signed-off-by: Keith Packard <keithp@keithp.com>
2009-07-15 09:47:40 -07:00
Barry Scott b74bf3f9a6 Fix XV scan line calculation when rotated. 2009-07-13 16:38:34 -07:00
Carl Worth 82905c7c0b Increment version to 2.7.99.902 2009-07-13 05:29:49 -07:00
Carl Worth 925bc6cbd4 RELEASING: Fix typo in instructions 2009-07-13 05:27:40 -07:00
Carl Worth 67c0afc7b7 NEWS: Add notes for 2.7.99.902 2009-07-13 05:27:06 -07:00
Keith Packard 34c674dd45 Remove vestiges of NoAccel options from i830_driver.c
The enum and OptionInfoRec weren't removed in the initial patch

Signed-off-by: Keith Packard <keithp@keithp.com>
2009-07-11 22:53:42 -07:00
Keith Packard 33d6e7a235 intel.man: Mark NoAccel option as i810/i815 only
The NoAccel option is not valid for other chips.

Signed-off-by: Keith Packard <keithp@keithp.com>
2009-07-11 22:53:11 -07:00
Keith Packard ed8a9a94e1 i830_uxa_prepare_access: Flush and wait for idle for non-bo pixmaps
Without kernel support and explicit knowledge about where in the ring the
last rendering operation for a specific pixmap was, we must synchronize with
any outstanding rendering before accessing a pixmap which does not have a
buffer object.

Signed-off-by: Keith Packard <keithp@keithp.com>
2009-07-10 18:26:59 -07:00
Keith Packard cb19ac207b KMS: Keep screen pixmap devPrivate.ptr NULL during init and resize
The frame buffer only has a valid address between prepare_access and
finish_access calls, so remove all other attempts to compute an address from
the driver.

Signed-off-by: Keith Packard <keithp@keithp.com>
2009-07-10 18:26:59 -07:00
Keith Packard 704b88dd50 i830_bind_memory: Under UMS: Bind GEM bos with dri_bo_pin, else through the GART
We only need to get static offsets for objects when not running KMS,
otherwise the kernel will manage those as needed for us.

Binding objects is done in one of two ways. For GEM buffer objects, we use
dri_bo_pin. For GART allocated memory, we bind that to the GART.
2009-07-10 18:26:59 -07:00
Keith Packard 7b273732f7 Allocate GTT space for GEM only under UMS
GEM requires GTT space to map objects. Under KMS, the kernel driver has
already provided all available GTT space to GEM, so the X server need not do
anything.

Signed-off-by: Keith Packard <keithp@keithp.com>
2009-07-10 18:26:59 -07:00
Keith Packard 56bfee8705 Always set screen pixmap data pointer at init and resize times
For non-DRM environments, the screen pixmap will be GART allocated memory
and not a libdrm buffer object and so uxa will only use devPrivate.ptr to
find the associated memory. Make sure devPrivate.ptr is set each time the
framebuffer is allocated so that uxa will be able to draw to it.

Signed-off-by: Keith Packard <keithp@keithp.com>
2009-07-10 18:26:59 -07:00
Keith Packard 98087a0b96 Make xorg.conf DRI option work under KMS. Fix name of I830AccelMethodInit
KMS mode does not call I830AccelMethodInit as that does the user
modesetting initialization (yes, it was misnamed), but that means that the DRI option
was ignored. Create a new i830_check_dri_option function to do the option
detection, then remove that from I830AccelMethodInit, which is renamed
i830_user_modesetting_init to reflect what it actually does.

Signed-off-by: Keith Packard <keithp@keithp.com>
2009-07-10 18:26:59 -07:00
Keith Packard d655a3ff42 Remove NoAccel support
This removes yet another 'debugging' option that hasn't seen real use in a
long time, and wasn't supported under KMS in any case.

Signed-off-by: Keith Packard <keithp@keithp.com>
2009-07-10 18:26:58 -07:00
Eric Anholt 4e4b947f0b Remove bad comment about 3DSTATE_DRAWING_RECTANGLE size. 2009-07-09 15:52:16 -07:00
Eric Anholt 9155cfca75 Fix lols in trying to figure out whether this is a 64-bit build.
Noticed by:	Michel Dänzer <michel@daenzer.net>
2009-07-09 14:16:07 -07:00
Eric Anholt 40e7c95052 Refuse to allocate giant BOs on 32-bit systems.
The overcommit of address space combined with these buffers hitting SW
fallbacks all the time means that we're probably better off telling the
application "no" instead of likely silently failing later.

Bug #22601.
2009-07-08 08:57:33 -07:00
Eric Anholt 6337cd23e6 Initialize the other argument to drmSetInterfaceVersion.
The kernel ignores it if dd_major is -1, anyway.
2009-07-08 08:57:33 -07:00
ling.ma@intel.com 216d939858 enable sdvo lvds scaling function
Currently we implemented basic sdvo lvds function,
But except for sdvo lvds fixed mode, we can not switch
to other modes, otherwise display get black. The patch
intends to work for all modes whose HDisplay and VDisplay
are lower than fixed mode.

Signed-off-by: Ma Ling <ling.ma@intel.com>
2009-07-08 09:22:40 +08:00
Simon Farnsworth 0402f4f331 Raise XV limit to 2048x2048 to match hardware limits.
The bigrequests limit isn't present in current X servers (tested using
textured video on a 965 with both image and window at 2048x2048 on a
1920x1200 display, and image at 2048x2048, window at 1024x1024).

Remove the artificial limit, enabling full-screen HD video when
rotated.
2009-07-07 15:55:48 -07:00
Keith Packard a663578323 non-DRI FB resize failed to assign the screen pixmap devPrivate.ptr (22328)
When not using DRI, the screen pixmap is not in a bo, and so the usual
enable/disable access functions don't adjust the pixmap devPrivate field,
leaving it to the frame buffer allocation code to assign this correctly.

During mode setting and fb resizing, FB access is disabled, and the
screen pixmap devPrivate is stashed away by xf86EnableDisableFBAccess,
to be restored when FB access is turned back on. This means that we have to
set the pixmap devPrivate.ptr (in case xf86EnableDisableFBAccess doesn't
do this), along with storing the address in the scrn->pixmapPrivate field.

Signed-off-by: Keith Packard <keithp@keithp.com>
Reviewed-by: Jesse Barnes <jbarnes@virtuousgeek.org>
2009-07-07 14:22:50 -07:00
Chris Wilson c889b34e43 Check for a valid I830Ptr before closing master.
After failing to become DRM master, the X server dies attempting to close
the master fd during free:

(EE) intel(0): [drm] failed to set drm interface version.
(EE) intel(0): Failed to become DRM master.
(EE) intel(0): failed to get resources: Bad file descriptor
(EE) intel(0): Kernel modesetting setup failed

Backtrace:
0: X(xorg_backtrace+0x3b) [0x8133a3b]
1: X(xf86SigHandler+0x55) [0x80c7945]
2: [0xb805d400]
3: /usr/lib/xorg/modules/drivers//intel_drv.so [0xb7b4bfcc]
4: X(xf86DeleteScreen+0x6b) [0x80d465b]
5: X(InitOutput+0x548) [0x80b0158]
6: X(main+0x1cb) [0x807220b]
7: /lib/tls/i686/cmov/libc.so.6(__libc_start_main+0xe5) [0xb7d107a5]
8: X [0x8071881]
Saw signal 11.  Server aborting.
 ddxSigGiveUp: Closing log
 ddxSigGiveUp: re-raising 11
Segmentation fault

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2009-07-07 18:17:57 +01:00
Keith Packard 705042f497 Handle DRI2INFOREC version 3
This DRI2 version does not support the old CreateBuffers/DestroyBuffers
interface anymore.

Signed-off-by: Keith Packard <keithp@keithp.com>
2009-07-06 13:50:34 -07:00
Keith Packard 2ebc7d32e4 Update to multi-API DRI2 interface
The DRI2 interface was changed to support both old and new drivers in an
API/ABI compatible fashion. This change syncs the intel driver with the new
version of the DRI2 API.

Signed-off-by: Keith Packard <keithp@keithp.com>
2009-07-06 13:50:34 -07:00
Rémi Cardona f6f79eb629 remove unused shader program
This file is not even referenced by any Makefile.am

Acked-by: Zhenyu Wang <zhenyuw@linux.intel.com>
2009-07-06 11:01:31 +02:00
Zhenyu Wang 7e722ada53 Disable FBC on IGDNG
Don't make FBC count for memory allocation.

Signed-off-by: Zhenyu Wang <zhenyuw@linux.intel.com>
2009-07-06 16:25:13 +08:00
Barry Scott 7422714192 Fix segv for clipped movie window
When playing a movie that is clipped on its left and right edges the Xorg
server will SEGV sometimes. This is because the intel driver ignores the
clipping info when it copies the planes out of the XV data.

The check for the optimised copy was wrong to ignore the width required.
Which leads to too much data being copied by the memcpy. It the source buffer
happens to end exactly on a page boundary the server will SEGV.

As we reviewed the code we checked the calculation of src1, src2 and src3.
The patch includes additional comments to make it clear what the elements of
the calculation are.

This bug exists in git head and we also see it in 2.4.1.

Barry

Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
2009-07-02 13:36:56 -07:00
Jesse Barnes c1755599db Clear the bo on the rotate scratch pixmap
Since the scratch pixmap header will be re-used after allocation, we
need to clear its bo attachment when we stop using it, otherwise a later
user will use a bogus bo.

Reviewed-by: Keith Packard <keithp@keithp.com>
Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
2009-07-02 13:08:15 -07:00
Daniel Vetter 324b468620 Xv i830_display_video splitup: extract i830_update_scaling_factors
Just moved the code, no other changes.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2009-07-02 11:10:55 -07:00
Daniel Vetter c2410addbf Xv i830_display_video splitup: extract i830_update_polyphase_coeffs
To slightly clean up the implementation of i830_update_polyphase_coeffs,
introduce the two small helper functions i830_limit_coeff and
i830_store coeffs_in_overlay_regs.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
2009-07-02 09:39:58 -07:00
Daniel Vetter 795c11c49c Xv i830_display_video splitup: extract i830_update_dst_box_to_crtc_coords
Just moved the code ouf of line.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2009-07-02 09:24:19 -07:00
Daniel Vetter 4100abdf5d Xv: kill !textured condition
This is in the overlay path and therefore always true.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2009-07-01 15:38:54 -07:00
Daniel Vetter b0df0fe91e Xv overlay: implement GAMMA5 errata
- also ensure that the most significant byte is zero
- while I was looking at the code, add the Overlay suffix to
SetPortAttribute like in the textured case.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2009-07-01 15:38:54 -07:00
Daniel Vetter 5ef4d3cde1 Xv: kill unneeded indirection
overlay and textured video have the exact same QueryImageAttributes
function.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2009-07-01 15:38:54 -07:00
Eric Anholt 1e4784bf26 uxa: Fix segfault on source-only picture usage with FallbackDebug.
Bug #22107.
2009-06-30 19:54:23 -07:00
Zhenyu Wang 7e79fc8aa9 Fix 945GM VT switch in UMS
Bug #19578. We should set private intel_crtc state according
to current, as fail to do so pipe A needs active won't be taken
care of. Also make sure pipe swap operation always set during
VT switch.

Signed-off-by: Zhenyu Wang <zhenyuw@linux.intel.com>
2009-07-01 10:17:01 +08:00