summaryrefslogtreecommitdiff
path: root/src/radeon_kms.c
AgeCommit message (Collapse)Author
2010-06-21Convert x(c)alloc/xfree to m/calloc/free.Michel Dänzer
Fixes deprecation warnings with xserver master and should also work with older xservers.
2010-06-21radeon: fix support for 1.9 server master.Dave Airlie
This moves pixmap and mode set into CSR where its allowed. Should work fine on old servers also. Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-06-11radeon: fixup last fix, use CURSOR_WIDTH not RADEON_CURSOR_WIDTH.Dave Airlie
2010-06-11radeon: set proper stride for cursor in tiling flags.Dave Airlie
definitely incorrect, but hope it doesn't break anything. Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-06-08radeon: fix rn50 cloning with kmsAlex Deucher
Since they only have one crtc sometimes the xserver doesn't assign a crtc to one of the outputs even though both outputs have common modes which results in only one monitor being enabled. Assign a crtc in preinit so that both outputs light up. Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
2010-06-08xv: fix Xv on M6/RV100 under KMS.Dave Airlie
pRADEONEnt->HasCRTC2 wasn't setup under KMS. Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-06-03evergreen: explicitly disable accel on evergreenAlex Deucher
Previously we relied on the drm not having accel enabled to make sure evergreen used shadowfb, now we when we enable accel in the drm, we need to make sure the ddx doesn't try and use it until it's implemented. Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
2010-05-18r3xx-r5xx: enable color tiling by default on KMSMarek Olšák
Signed-off-by: Marek Olšák <maraeo@gmail.com>
2010-05-10kms: add support for the MSC swap & sync APIJerome Glisse
This patch is mostly a port over of Intel ddx code for MSC support. It needs a radeon KMS module with version 2.4 which has the query for hw crtc id. Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org> Signed-off-by: Jerome Glisse <jglisse@redhat.com>
2010-04-16kms: add uevent support.Dave Airlie
When we get a hotplug event from the kernel we should notify the client side to reconfigure displays. based on work by ajax in intel driver. Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-03-18radeon: avoid using DRI1 init path on DRI2 driver.Dave Airlie
I was playing with multi-seat and found this code, fixed it up to be sane and more DRI2 like. Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-02-26Use/define RADEON_GPU_PAGE_SIZE instead of sprinkling 4096 everywhere.Matt Turner
Also, define RADEON_BUFFER_ALIGN in terms of it, and replace some RADEON_ALIGN(x, RADEON_BUFFER_ALIGN) with RADEON_ALIGN(x, RADEON_GPU_PAGE_SIZE) since this is really what was intended. CC: Jerome Glisse <jglisse@redhat.com> CC: Alex Deucher <alexdeucher@gmail.com> CC: Dave Airlie <airlied@redhat.com> Signed-off-by: Matt Turner <mattst88@gmail.com>
2010-02-25clean up kms zaphod handlingJames Le Cuirot
Taken from James patch on bug 24523 agd5f: adapt to the current code
2010-02-23zaphod: hopefully fix kms + zaphodDave Airlie
2010-02-17radeon: add ZaphodHeads optionAlex Deucher
Allows users that want to use zaphod mode to select which xrandr outputs are assigned to which head. E.g., Option "ZaphodHeads" "LVDS,VGA-0" will assign LVDS to the first zaphod driver instance and VGA-0 to the second instance.
2010-01-25KMS: fix no accel optionAlex Deucher
NO_ACCEL wasn't handled correctly with KMS. fixes fdo bug 26198
2010-01-25radeon/kms: only enable EXA pixmaps under kms if we support render accelDave Airlie
I've seen RN50s with 64MB of RAM that are slow as molasses, this should fix them. RH bug 556400 Signed-off-by: Dave Airlie <airlied@redhat.com>
2009-12-01r600: fix multi-operation in single batch support.Dave Airlie
This ports the mesa DMA buffer handling with the 3 lists, Signed-off-by: Dave Airlie <airlied@redhat.com>
2009-11-27r600/accel: cleanup and merge a lot of the accel functionsDave Airlie
All of the drawing ops were the exact same modulo the vtx size, this along with the vertex buffer wrapping code could all be consolidated into a smaller set of functions. This also adds 2 VBO which we switch between, and merges a #define to enable the multiple operations in one CS under KMS mode. Multi-operation still isn't working though. Signed-off-by: Dave Airlie <airlied@redhat.com>
2009-11-25radeon/exa: change option to determine exa pixmap usage.Dave Airlie
This moves to a boolean instead of using VRAM sizing. as per Michel's suggestions on list. Signed-off-by: Dave Airlie <airlied@redhat.com>
2009-11-25kms: flush cs on close screen.Dave Airlie
this is needed for server recycle. Signed-off-by: Dave Airlie <airlied@redhat.com>
2009-11-25r600: refactor code to help future acceleration speedups.Dave Airlie
This changes the vertex buffer index to be an offset, and records the start of the vb for each operation and uses that to set the operations up. This still flushes after each operation to make sure we have no regressions in non-kms/kms cases. Signed-off-by: Dave Airlie <airlied@redhat.com>
2009-11-24radeon/kms: drop special r600 indirect flushDave Airlie
This just merges it with the main kms cs flush
2009-11-23radeon: fix warning in printfDave Airlie
2009-11-23radeon: avoid using hw pixmaps when we have little VRAM.Dave Airlie
This patch returns NULL for pixmap creation when we are using mixed pixmaps and the pixmap has a size. The size check is necessary for the front buffer. We add a flag to force pixmap creation for certain pixmaps that need to be hw, like the DRI2 and Xv ones. Idea from Michel and workarounds from Ben Skeggs. v2: add Option "EXALowVRAM" to allow configuring this, value in MBs. Signed-off-by: Dave Airlie <airlied@redhat.com>
2009-11-20kms: recalculate the flush limits after screen resize.Dave Airlie
When we resize the front buffer we need to reduce the flush limits appropriately. Signed-off-by: Dave Airlie <airlied@redhat.com>
2009-10-24Disable color tiling on r600/r700Luca Tettamanti
Not supported yet.
2009-10-09Revert "kms: setup colormap and gamma correctly."Dave Airlie
This reverts commit 60d9685abddccec17c1a9a5ec48cbe9c92543e0f. which breaks colormap on 1.6 X server Conflicts: src/drmmode_display.c
2009-10-05kms: assume accel is working is info ioctl return -EINVALJerome Glisse
-EINVAL should only happen if the info ioctl doesn't support the get accel query. This patch assume that on such case accel is working.
2009-10-05kms: setup colormap and gamma correctly.Dave Airlie
We need to program the gamma at modeset. no need to use old cmap interface at all.
2009-10-03Fix KMS on big endian machines.Michel Dänzer
Requires at least xserver 1.7 to work properly. Also make sure the front buffer is and stays tiled if colour tiling is enabled.
2009-10-03KMS: Don't hide HW cursor when it's updated.Michel Dänzer
Inspired by the intel driver; might avoid/reduce HW cursor flicker in some cases.
2009-10-03Fix some compiler warnings.Michel Dänzer
2009-09-30radeon/kms: fallback to shadowfb if kernel report acceleration is offJerome Glisse
This will fallback to shadowfb is GPU accel failed somewhere during KMS kernel init.
2009-09-19kms: disable dgaAlex Deucher
Can be dangerous with kms: http://lists.freedesktop.org/archives/xorg-devel/2009-September/002113.html
2009-09-19kms: init dga using xf86DiDGAInitAlex Deucher
fixes cursor problems in games like UT2004 and Penumbra Overture see fdo bug 24034
2009-08-25r6xx/r7xx EXA: WIPAlex Deucher
2009-08-25radeon: Fix X recycling with KMSJerome Glisse
On X recycling CloseScreen drop master so grab it again in InitScreen and avoid to reallocate buffer & various others cs/bo utilities on X recycling.
2009-08-19radeon/kms: add initial colortiling support (disabled by default).Dave Airlie
This requires an X server from git with createpixmap2 support fixed up in it. On 1.6 and previous it won't do any tiling, if you are running git server please upgrade to latest git. Option "AllowColorTiling" "true" to enable and do some testing
2009-08-07Properly let radeon_cs_flush_indirect() re-emit 2D state if necessary.Michel Dänzer
Also remove a superfluous assignment.
2009-07-23radeon: fix KMS shadowfb for r6xx and newer hw.Jerome Glisse
We need to map front buffer and also to avoid EXA initialization when falling back to shadowfb on newer r6xx/r7xx when KMS is enabled.
2009-07-18Also drop DRM master in KMS CloseScreen.Michel Dänzer
The LeaveVT hook isn't always called when the server dies, e.g. when quitting from the GDM greeter. This may cause existing servers to fall over if the dying server process still exists when they try to re-acquire master and set a mode. Also use drmSet/DropMaster() rather than ioctl() directly.
2009-07-06radeon: move state changes into flush functionDave Airlie
2009-07-06radeon: taken from kms-support + CS fixes commit.Dave Airlie
re-emit 2D state and reset 3D state emit on flush
2009-07-06radeon: port to new space checking in libdrm interfaceDave Airlie
This uses a new libdrm interface which shares code with mesa. It also fixes the bo to flush when full instead of never flushing. It survives gtkperf -a here which the driver didn't before now
2009-07-02kms: drop DGADave Airlie
2009-07-02kms: no need to reference fifo slotsDave Airlie
2009-07-02radeon: add KMS support (still disabled)Dave Airlie
This adds DRI2 + KMS + driver pixmaps support to the driver. I've decided to just do a completely separate KMS driver file instead of hacking the crap out of radeon_driver.c. So now I do the KMS check in radeon_probe.c time and set the DDX pointed up to a completely different set at this stage. This avoids a lot of if (kms) type crap in the code at the expense of making sure we make changes to both files if necessary. This code is still disabled in configure.ac as I broke EXA composite rendering somehow in KMS mode