[PATCH 05/15] drm/radeon: fix ring commit padding

2012-07-12 Thread Christian König
We don't need to pad anything if the number of dwords written to the ring already matches the requirements. Fixes some writting more dword to ring than expected warnings. Signed-off-by: Christian König deathsim...@vodafone.de Reviewed-by: Jerome Glisse jgli...@redhat.com Reviewed-by: Michel

[PATCH 04/15] drm/radeon: add an exclusive lock for GPU reset v2

2012-07-12 Thread Christian König
that no concurrent reset take place. v2: init rw semaphore Signed-off-by: Jerome Glisse jgli...@redhat.com Reviewed-by: Christian König christian.koe...@amd.com --- drivers/gpu/drm/radeon/radeon.h|1 + drivers/gpu/drm/radeon/radeon_cs.c |5 + drivers/gpu/drm/radeon

[PATCH 06/15] drm/radeon: fix fence value access

2012-07-12 Thread Christian König
It is possible that radeon_fence_process is called after writeback is disabled for suspend, leading to an invalid read of register 0x0. This fixes a problem for me where the fence value is temporary incremented by 0x1 on suspend/resume. Signed-off-by: Christian König deathsim

[PATCH 07/15] drm/radeon: fix fence init after resume

2012-07-12 Thread Christian König
Start with last signaled fence number instead of last emitted one. Signed-off-by: Christian König deathsim...@vodafone.de Reviewed-by: Jerome Glisse jgli...@redhat.com --- drivers/gpu/drm/radeon/radeon_fence.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm

[PATCH 08/15] drm/radeon: remove FIXME comment from chipset suspend

2012-07-12 Thread Christian König
For a normal suspend/resume we allready wait for the rings to be empty, and for a suspend/reasume in case of a lockup we REALLY don't want to wait for anything. Signed-off-by: Christian König deathsim...@vodafone.de Reviewed-by: Jerome Glisse jgli...@redhat.com --- drivers/gpu/drm/radeon

[PATCH 09/15] drm/radeon: make cp init on cayman more robust

2012-07-12 Thread Christian König
It's not critical, but the current code isn't 100% correct. Signed-off-by: Christian König deathsim...@vodafone.de Reviewed-by: Jerome Glisse jgli...@redhat.com --- drivers/gpu/drm/radeon/ni.c | 133 ++- 1 file changed, 56 insertions(+), 77 deletions

[PATCH 10/15] drm/radeon: remove ip_pool start/suspend

2012-07-12 Thread Christian König
The IB pool is in gart memory, so it is completely superfluous to unpin / repin it on suspend / resume. Signed-off-by: Christian König deathsim...@vodafone.de --- drivers/gpu/drm/radeon/evergreen.c | 17 ++--- drivers/gpu/drm/radeon/ni.c | 16 ++-- drivers

[PATCH 11/15] drm/radeon: remove r600_blit_suspend

2012-07-12 Thread Christian König
Just reinitialize the shader content on resume instead. Signed-off-by: Christian König deathsim...@vodafone.de --- drivers/gpu/drm/radeon/evergreen.c |1 - drivers/gpu/drm/radeon/evergreen_blit_kms.c | 40 +-- drivers/gpu/drm/radeon/ni.c

[PATCH 13/15] drm/radeon: move radeon_ib_ring_tests out of chipset code

2012-07-12 Thread Christian König
Making it easier to control when it is executed. Signed-off-by: Christian König deathsim...@vodafone.de Reviewed-by: Michel Dänzer michel.daen...@amd.com --- drivers/gpu/drm/radeon/evergreen.c |4 drivers/gpu/drm/radeon/ni.c|4 drivers/gpu/drm/radeon/r100.c

[PATCH 12/15] drm/radeon: remove vm_manager start/suspend

2012-07-12 Thread Christian König
the VM seems to make it even more unstable, creating an unrecoverable lockup in the end. 3. If we want to backup/restore the leftover ring content we must not unbind VMs in between. Signed-off-by: Christian König deathsim...@vodafone.de --- drivers/gpu/drm/radeon/ni.c | 12

[PATCH 14/15] drm/radeon: record what is next valid wptr for each ring v3

2012-07-12 Thread Christian König
as well Signed-off-by: Jerome Glisse jgli...@redhat.com Signed-off-by: Christian König deathsim...@vodafone.de --- drivers/gpu/drm/radeon/evergreen.c |8 +++- drivers/gpu/drm/radeon/ni.c | 11 ++- drivers/gpu/drm/radeon/r600.c| 18 -- drivers/gpu

[PATCH 15/15] drm/radeon: implement ring saving on reset v4

2012-07-12 Thread Christian König
-by: Christian König deathsim...@vodafone.de Reviewed-by: Michel Dänzer michel.daen...@amd.com --- drivers/gpu/drm/radeon/radeon.h|4 ++ drivers/gpu/drm/radeon/radeon_device.c | 48 +++ drivers/gpu/drm/radeon/radeon_ring.c | 82 3 files

Re: [PATCH] drm/radeon: fix bo creation retry path

2012-07-13 Thread Christian König
On 13.07.2012 00:23, j.gli...@gmail.com wrote: From: Jerome Glisse jgli...@redhat.com Retry label was at wrong place in function leading to memory leak. Cc: sta...@vger.kernel.org Signed-off-by: Jerome Glisse jgli...@redhat.com Reviewed-by: Christian König christian.koe...@amd.com

Re: [PATCH 14/15] drm/radeon: record what is next valid wptr for each ring v3

2012-07-13 Thread Christian König
On 12.07.2012 18:36, Alex Deucher wrote: On Thu, Jul 12, 2012 at 12:12 PM, Christian König deathsim...@vodafone.de wrote: Before emitting any indirect buffer, emit the offset of the next valid ring content if any. This allow code that want to resume ring to resume ring right after ib

Re: [PATCH 14/15] drm/radeon: record what is next valid wptr for each ring v3

2012-07-13 Thread Christian König
On 13.07.2012 14:27, Alex Deucher wrote: On Fri, Jul 13, 2012 at 5:09 AM, Christian König deathsim...@vodafone.de wrote: On 12.07.2012 18:36, Alex Deucher wrote: On Thu, Jul 12, 2012 at 12:12 PM, Christian König deathsim...@vodafone.de wrote: Before emitting any indirect buffer, emit

[PATCH 1/3] drm/radeon: return an error if there is nothing to wait for

2012-07-13 Thread Christian König
Otherwise the sa managers out of memory handling doesn't work. Signed-off-by: Christian König deathsim...@vodafone.de --- drivers/gpu/drm/radeon/radeon_fence.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/radeon/radeon_fence.c b/drivers/gpu/drm/radeon

[PATCH 2/3] drm/radeon: let sa manager block for fences to wait for

2012-07-13 Thread Christian König
Otherwise we can encounter out of memory situations under extreme load. Signed-off-by: Christian König deathsim...@vodafone.de --- drivers/gpu/drm/radeon/radeon.h|2 +- drivers/gpu/drm/radeon/radeon_sa.c | 72 +--- 2 files changed, 51 insertions(+), 23

[PATCH 3/3] drm/radeon: fix const IB handling

2012-07-13 Thread Christian König
Const IBs are executed on the CE not the CP, so we can't fence them in the normal way. So submit them directly before the IB instead, just as the documentation says. Signed-off-by: Christian König deathsim...@vodafone.de --- drivers/gpu/drm/radeon/r100.c|2 +- drivers/gpu/drm/radeon

Re: [PATCH 14/15] drm/radeon: record what is next valid wptr for each ring v3

2012-07-17 Thread Christian König
On 17.07.2012 01:13, Alex Deucher wrote: On Fri, Jul 13, 2012 at 9:57 AM, Alex Deucher alexdeuc...@gmail.com wrote: On Fri, Jul 13, 2012 at 9:46 AM, Christian König deathsim...@vodafone.de wrote: On 13.07.2012 14:27, Alex Deucher wrote: On Fri, Jul 13, 2012 at 5:09 AM, Christian König

[git pull] drm/radeon: reset ring saving branch

2012-07-17 Thread Christian König
Hi Dave, I think it is easier if I just send you a pull request of my branch instead of individual patches. So please pull the this branch into -next: git://people.freedesktop.org/~deathsimple/linux next It contains the following changes: Christian König (14): drm/radeon: add

[PATCH 1/3] drm/radeon: return an error if there is nothing to wait for

2012-07-17 Thread Christian König
Otherwise the sa managers out of memory handling doesn't work. Signed-off-by: Christian König deathsim...@vodafone.de --- drivers/gpu/drm/radeon/radeon_fence.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/radeon/radeon_fence.c b/drivers/gpu/drm/radeon

[PATCH 2/3] drm/radeon: let sa manager block for fences to wait for v2

2012-07-17 Thread Christian König
Otherwise we can encounter out of memory situations under extreme load. v2: add documentation for the new function Signed-off-by: Christian König deathsim...@vodafone.de --- drivers/gpu/drm/radeon/radeon.h|2 +- drivers/gpu/drm/radeon/radeon_sa.c | 82

[PATCH 3/3] drm/radeon: fix const IB handling v2

2012-07-17 Thread Christian König
Const IBs are executed on the CE not the CP, so we can't fence them in the normal way. So submit them directly before the IB instead, just as the documentation says. v2: keep the extra documentation Signed-off-by: Christian König deathsim...@vodafone.de --- drivers/gpu/drm/radeon/r100.c

Re: [PATCH 00/10] Radeon documentation updates for drm-next

2012-07-17 Thread Christian König
+++ drivers/gpu/drm/radeon/radeon_kms.c | 126 + drivers/gpu/drm/radeon/radeon_ring.c| 207 - 9 files changed, 1584 insertions(+), 14 deletions(-) For this series: Reviewed-by: Christian König christian.koe...@amd.com

Re: [PATCH 3/3] drm/radeon: fix const IB handling

2012-07-17 Thread Christian König
On 13.07.2012 16:17, Tom Stellard wrote: On Fri, Jul 13, 2012 at 04:08:15PM +0200, Christian König wrote: Const IBs are executed on the CE not the CP, so we can't fence them in the normal way. So submit them directly before the IB instead, just as the documentation says. Signed-off

Re: [PATCH] drm/radeon: update ib_execute for SI

2012-07-17 Thread Christian König
On 16.07.2012 23:14, alexdeuc...@gmail.com wrote: From: Alex Deucher alexander.deuc...@amd.com When submitting a CONST_IB, emit a SWITCH_BUFFER packet before the CONST_IB. This isn't strictly necessary (the driver will work fine without it), but is good practice and allows for more flexible

Re: [git pull] drm/radeon: reset ring saving branch

2012-07-17 Thread Christian König
On 17.07.2012 11:46, Dave Airlie wrote: On Tue, Jul 17, 2012 at 7:39 PM, Christian König deathsim...@vodafone.de wrote: Hi Dave, I think it is easier if I just send you a pull request of my branch instead of individual patches. Thanks for this, I've been getting lost as to what is where, so

Re: [PATCH 3/3] drm/radeon: fix const IB handling

2012-07-17 Thread Christian König
On 17.07.2012 16:25, Jerome Glisse wrote: On Tue, Jul 17, 2012 at 5:50 AM, Christian König deathsim...@vodafone.de wrote: On 13.07.2012 16:17, Tom Stellard wrote: On Fri, Jul 13, 2012 at 04:08:15PM +0200, Christian König wrote: Const IBs are executed on the CE not the CP, so we can't fence

[git pull] drm/radeon: documentation and fixes

2012-07-18 Thread Christian König
/radeon: fix up pll selection on DCE5/6 drm/radeon: fix SS setup for DCPLL Christian König (3): drm/radeon: return an error if there is nothing to wait for drm/radeon: let sa manager block for fences to wait for v2 drm/radeon: fix const IB handling v2 Cheers, Christian

Re: -next merged with Linus tree

2012-07-20 Thread Christian König
On 20.07.2012 07:34, Dave Airlie wrote: Hi, I've just merged Linus tree into drm-next and fixes up the conflicts, some in i915, one in radeon. Can you guys check that they look correct after it? Have to test it a bit more, but at least drivers/gpu/drm/radeon/radeon_gart.c looks valid to me on

Re: [patch] drm/radeon: check for allocation failure in radeon_ring_backup()

2012-07-20 Thread Christian König
kmalloc? Anyway it's: Reviewed-by: Christian König christian.koe...@amd.com diff --git a/drivers/gpu/drm/radeon/radeon_ring.c b/drivers/gpu/drm/radeon/radeon_ring.c index 75cbe46..5a0ef24 100644 --- a/drivers/gpu/drm/radeon/radeon_ring.c +++ b/drivers/gpu/drm/radeon/radeon_ring.c @@ -402,7

Re: -next merged with Linus tree

2012-07-20 Thread Christian König
On 20.07.2012 16:12, Jerome Glisse wrote: On Fri, Jul 20, 2012 at 4:47 AM, Christian König deathsim...@vodafone.de wrote: On 20.07.2012 07:34, Dave Airlie wrote: Hi, I've just merged Linus tree into drm-next and fixes up the conflicts, some in i915, one in radeon. Can you guys check

Re: [PATCH 1/2] radeon: simplify ZS buffer checking on r600

2012-07-30 Thread Christian König
I wanted to work on something similar this week, cause we need some updates for SI on this. So thx, you saved me some work here. And both patches are: Reviewed-by: Christian König christian.koe...@amd.com On 29.07.2012 16:02, Marek Olšák wrote: Setting those flags has no effect anywhere else

Re: [PATCH 2/2] radeon: optimize allocation for depth w/o stencil and stencil w/o depth on EG

2012-07-30 Thread Christian König
On 30.07.2012 16:56, Jerome Glisse wrote: On Sun, Jul 29, 2012 at 1:04 PM, Marek Olšák mar...@gmail.com wrote: If we don't need stencil, don't allocate it. If we need only stencil (like PIPE_FORMAT_S8_UINT), don't allocate depth. v2: actually do it correctly Big NAK We need to allocate

[PATCH 1/2] drm/radeon: fix fence related segfault in CS

2012-07-31 Thread Christian König
Don't return success if scheduling the IB fails, otherwise we end up with an oops in ttm_eu_fence_buffer_objects. Signed-off-by: Christian König deathsim...@vodafone.de Reviewed-by: Alex Deucher alexander.deuc...@amd.com Cc: sta...@vger.kernel.org --- drivers/gpu/drm/radeon/radeon_cs.c |2

[PATCH 2/2] drm/radeon: fix bank tiling parameters on SI

2012-07-31 Thread Christian König
The sixteen bank case wasn't handled here, leading to GPU crashes because of userspace miscalculation. Signed-off-by: Christian König deathsim...@vodafone.de Cc: sta...@vger.kernel.org --- drivers/gpu/drm/radeon/si.c | 16 1 file changed, 12 insertions(+), 4 deletions(-) diff

Re: [PATCH 2/2] drm/radeon: fix bank tiling parameters on SI

2012-07-31 Thread Christian König
On 31.07.2012 16:02, Alex Deucher wrote: On Tue, Jul 31, 2012 at 7:48 AM, Christian König deathsim...@vodafone.de wrote: The sixteen bank case wasn't handled here, leading to GPU crashes because of userspace miscalculation. You mean a GPU hang or a segfault in userspace? IIRC, from the hw

Re: [PATCH 1/2] drm/radeon: fix fence related segfault in CS

2012-07-31 Thread Christian König
On 31.07.2012 16:47, Michel Dänzer wrote: On Die, 2012-07-31 at 13:48 +0200, Christian König wrote: Don't return success if scheduling the IB fails, otherwise we end up with an oops in ttm_eu_fence_buffer_objects. Signed-off-by: Christian König deathsim...@vodafone.de Reviewed-by: Alex Deucher

Re: [PATCH 2/2] drm/radeon: fix bank tiling parameters on SI

2012-07-31 Thread Christian König
On 31.07.2012 16:42, Alex Deucher wrote: On Tue, Jul 31, 2012 at 10:21 AM, Christian König deathsim...@vodafone.de wrote: On 31.07.2012 16:02, Alex Deucher wrote: On Tue, Jul 31, 2012 at 7:48 AM, Christian König deathsim...@vodafone.de wrote: The sixteen bank case wasn't handled here, leading

Re: [PATCH] drm/radeon: fence virtual address and free it once idle v3

2012-08-04 Thread Christian König
then it is: Reviewed-by: Christian König christian.koe...@amd.com In the future I would really like to make the updating of the PTE also async, that should save us allot of problems here. Christian. --- drivers/gpu/drm/radeon/radeon.h|1 + drivers/gpu/drm/radeon/radeon_cs.c

Re: [PATCH] drm/radeon: fence virtual address and free it once idle v3

2012-08-06 Thread Christian König
On 04.08.2012 11:07, Christian König wrote: On 03.08.2012 23:26, j.gli...@gmail.com wrote: From: Jerome Glisse jgli...@redhat.com Virtual address need to be fenced to know when we can safely remove it. This patch also properly clear the pagetable. Previously it was serouisly broken. Kernel

Re: [PATCH] drm/radeon: fence virtual address and free it once idle v3

2012-08-06 Thread Christian König
On 06.08.2012 18:30, Jerome Glisse wrote: On Mon, Aug 6, 2012 at 12:06 PM, Christian König deathsim...@vodafone.de wrote: [SNIP] Additional to that patch we still need a minor fix to mesa (just move freeing the VM range after closing the handle). Going to send that in the next minute

Re: [PATCH v4 0/3] Enhanced EDID quirk functionality

2012-08-12 Thread Christian König
On 12.08.2012 22:07, Ian Pilcher wrote: Another rev. I figured out how to use git reset --hard and --soft to make regenerating the patch series a bit easier. (It helped a ton that all of the later changes are isolated in a single file.) I still feel like I'm probably missing an easier way to

[RFC] make VM handling async

2012-08-13 Thread Christian König
Yeah, I know I'm on vacation, but without coding I die of boringness in less than a week. This patchset is currently based on Jeromes VA fencing patch, but in the end makes it superfluous. It just moves the whole VM handling into the CP ring, removing the need to wait for anything directly in the

[PATCH 01/10] drm/radeon: fence virtual address and free it once idle v4

2012-08-13 Thread Christian König
From: Jerome Glisse jgli...@redhat.com Virtual address need to be fenced to know when we can safely remove it. This patch also properly clear the pagetable. Previously it was serouisly broken. Kernel 3.5/3.4 need a similar patch but adapted for difference in mutex locking. v2: For to update

[PATCH 02/10] drm/radeon: cleanup VM id handling a bit

2012-08-13 Thread Christian König
Store a reference to the VM into the IB structure, that makes calculating the IBs address a bit less complicated. Signed-off-by: Christian König deathsim...@vodafone.de --- drivers/gpu/drm/radeon/ni.c |5 +++-- drivers/gpu/drm/radeon/r100.c|2 +- drivers/gpu/drm/radeon

[PATCH 03/10] drm/radeon: move VM funcs into asic structure

2012-08-13 Thread Christian König
So it looks more like the rest of the driver. Signed-off-by: Christian König deathsim...@vodafone.de --- drivers/gpu/drm/radeon/radeon.h | 35 +--- drivers/gpu/drm/radeon/radeon_asic.c | 50 ++ drivers/gpu/drm/radeon/radeon_gart.c

[PATCH 04/10] drm/radeon: remove vm_unbind

2012-08-13 Thread Christian König
It actually isn't very useful. Signed-off-by: Christian König deathsim...@vodafone.de --- drivers/gpu/drm/radeon/ni.c | 11 --- drivers/gpu/drm/radeon/radeon.h |2 -- drivers/gpu/drm/radeon/radeon_asic.c |3 --- drivers/gpu/drm/radeon/radeon_gart.c |1

[PATCH 05/10] drm/radeon: add sync helper function

2012-08-13 Thread Christian König
Signed-off-by: Christian König deathsim...@vodafone.de --- drivers/gpu/drm/radeon/radeon_cs.c | 20 ++-- 1 file changed, 14 insertions(+), 6 deletions(-) diff --git a/drivers/gpu/drm/radeon/radeon_cs.c b/drivers/gpu/drm/radeon/radeon_cs.c index 0a9d1eb..85a80e4 100644

[PATCH 06/10] drm/radeon: make VM flushs a ring operation

2012-08-13 Thread Christian König
Move flushing the VMs as function into the rings. First step to make VM operations async. Signed-off-by: Christian König deathsim...@vodafone.de --- drivers/gpu/drm/radeon/ni.c | 31 --- drivers/gpu/drm/radeon/radeon.h |6 -- drivers/gpu/drm

[PATCH 07/10] drm/radeon: rework VMID handling

2012-08-13 Thread Christian König
Move binding onto the ring, simplifying handling a bit. Signed-off-by: Christian König deathsim...@vodafone.de --- drivers/gpu/drm/radeon/ni.c| 20 ++--- drivers/gpu/drm/radeon/radeon.h| 30 +++- drivers/gpu/drm/radeon/radeon_asic.c |9 +-- drivers/gpu/drm

[PATCH 08/10] drm/radeon: rework VM page table handling

2012-08-13 Thread Christian König
Removing the need to wait for anything. Still not ideal, since we need to free pt on va remove. Signed-off-by: Christian König deathsim...@vodafone.de --- drivers/gpu/drm/radeon/radeon.h |4 +- drivers/gpu/drm/radeon/radeon_cs.c | 28 + drivers/gpu/drm/radeon/radeon_gart.c

[PATCH 09/10] drm/radeon: Move looping over the PTEs into chip code

2012-08-13 Thread Christian König
Makes it easier to move it into the rings. Signed-off-by: Christian König deathsim...@vodafone.de --- drivers/gpu/drm/radeon/ni.c | 22 +++--- drivers/gpu/drm/radeon/radeon.h | 12 ++-- drivers/gpu/drm/radeon/radeon_asic.c |3 --- drivers/gpu/drm

[PATCH 10/10] drm/radeon: make page table updates async

2012-08-13 Thread Christian König
Currently doing the update with the CP. Signed-off-by: Christian König deathsim...@vodafone.de --- drivers/gpu/drm/radeon/ni.c | 20 ++ drivers/gpu/drm/radeon/nid.h |1 + drivers/gpu/drm/radeon/radeon.h |2 + drivers/gpu/drm/radeon/radeon_asic.c |3

Re: [PATCH 10/10] drm/radeon: make page table updates async

2012-08-13 Thread Christian König
On 13.08.2012 18:19, Jerome Glisse wrote: On Mon, Aug 13, 2012 at 6:26 AM, Christian König deathsim...@vodafone.de wrote: Currently doing the update with the CP. Signed-off-by: Christian König deathsim...@vodafone.de NAK until point below are addressed [SNIP] For this to work properly you

Re: [RFC] make VM handling async

2012-08-13 Thread Christian König
On 13.08.2012 14:53, Sylvain BERTRAND wrote: It's not 100% complete cause page table updates should be made with the DMA ring, but we haven't released documentation for that yet, so I currently use CP memory writes instead. Sad. Any release time hint? (the DMA ring will cleanup a lot of code).

[PATCH 01/11] drm/radeon: fence virtual address and free it once idle v4

2012-08-20 Thread Christian König
pagetable when unbinding bo (don't bailout if bo_va-valid is true). v3: Add kernel 3.5/3.4 comment. v4: Fix compilation warnings. Signed-off-by: Jerome Glisse jgli...@redhat.com Reviewed-by: Christian König christian.koe...@amd.com --- drivers/gpu/drm/radeon/radeon.h|1 + drivers/gpu

make VM handling async v2

2012-08-20 Thread Christian König
Second and hopefully last round for this patchset. v2: Fix suspend/resume, and incorporate Jeromes comments. Cheers, Christian. ___ dri-devel mailing list dri-devel@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/dri-devel

[PATCH 02/11] drm/radeon: cleanup VM id handling a bit

2012-08-20 Thread Christian König
Store a reference to the VM into the IB structure, that makes calculating the IBs address a bit less complicated. Signed-off-by: Christian König deathsim...@vodafone.de Reviewed-by: Jerome Glisse jgli...@redhat.com --- drivers/gpu/drm/radeon/ni.c |5 +++-- drivers/gpu/drm/radeon

[PATCH 03/11] drm/radeon: move VM funcs into asic structure

2012-08-20 Thread Christian König
So it looks more like the rest of the driver. Signed-off-by: Christian König deathsim...@vodafone.de Reviewed-by: Jerome Glisse jgli...@redhat.com --- drivers/gpu/drm/radeon/radeon.h | 35 +--- drivers/gpu/drm/radeon/radeon_asic.c | 50

[PATCH 04/11] drm/radeon: remove vm_unbind

2012-08-20 Thread Christian König
It actually isn't very useful. Signed-off-by: Christian König deathsim...@vodafone.de Reviewed-by: Jerome Glisse jgli...@redhat.com --- drivers/gpu/drm/radeon/ni.c | 11 --- drivers/gpu/drm/radeon/radeon.h |2 -- drivers/gpu/drm/radeon/radeon_asic.c |3

[PATCH 05/11] drm/radeon: add sync helper function

2012-08-20 Thread Christian König
Signed-off-by: Christian König deathsim...@vodafone.de Reviewed-by: Jerome Glisse jgli...@redhat.com --- drivers/gpu/drm/radeon/radeon_cs.c | 20 ++-- 1 file changed, 14 insertions(+), 6 deletions(-) diff --git a/drivers/gpu/drm/radeon/radeon_cs.c b/drivers/gpu/drm/radeon

[PATCH 06/11] drm/radeon: make VM flushs a ring operation

2012-08-20 Thread Christian König
Move flushing the VMs as function into the rings. First step to make VM operations async. Signed-off-by: Christian König deathsim...@vodafone.de Reviewed-by: Jerome Glisse jgli...@redhat.com --- drivers/gpu/drm/radeon/ni.c | 31 --- drivers/gpu/drm/radeon

[PATCH 08/11] drm/radeon: rework VM page table handling

2012-08-20 Thread Christian König
Removing the need to wait for anything. Still not ideal, since we need to free pt on va remove. Signed-off-by: Christian König deathsim...@vodafone.de Reviewed-by: Jerome Glisse jgli...@redhat.com --- drivers/gpu/drm/radeon/radeon.h |4 +- drivers/gpu/drm/radeon/radeon_cs.c | 28

[PATCH 07/11] drm/radeon: rework VMID handling

2012-08-20 Thread Christian König
Move binding onto the ring, simplifying handling a bit. Signed-off-by: Christian König deathsim...@vodafone.de Reviewed-by: Jerome Glisse jgli...@redhat.com --- drivers/gpu/drm/radeon/ni.c| 20 ++--- drivers/gpu/drm/radeon/radeon.h| 30 +++- drivers/gpu/drm/radeon

[PATCH 09/11] drm/radeon: Move looping over the PTEs into chip code

2012-08-20 Thread Christian König
Makes it easier to move it into the rings. Signed-off-by: Christian König deathsim...@vodafone.de Reviewed-by: Jerome Glisse jgli...@redhat.com --- drivers/gpu/drm/radeon/ni.c | 22 +++--- drivers/gpu/drm/radeon/radeon.h | 12 ++-- drivers/gpu/drm/radeon

[PATCH 10/11] drm/radeon: make sure ib bo is properly bound and up to date in vm space

2012-08-20 Thread Christian König
From: Jerome Glisse jgli...@redhat.com Make sure that the ib bo is bound and is page table is up to date in the virtual address space. Signed-off-by: Jerome Glisse jgli...@redhat.com Reviewed-by: Christian König christian.koe...@amd.com --- drivers/gpu/drm/radeon/radeon_cs.c |5 + 1

[PATCH 11/11] drm/radeon: make page table updates async v2

2012-08-20 Thread Christian König
Currently doing the update with the CP. v2: Rebased on Jeromes bugfix. Make validity comparison more human readable. Signed-off-by: Christian König deathsim...@vodafone.de --- drivers/gpu/drm/radeon/ni.c | 20 ++ drivers/gpu/drm/radeon/nid.h |1 + drivers/gpu

[PATCH] drm/radeon: init lockup timeout on ring init

2012-08-20 Thread Christian König
Reset the lockup timeout on ring (re-)initialisation. Otherwise we get error messages like this on gpu resets: [ 1559.949177] radeon :01:00.0: GPU lockup CP stall for more than 1482270msec Signed-off-by: Christian König deathsim...@vodafone.de cc: sta...@kernel.org --- drivers/gpu/drm

Re: make VM handling async v2

2012-08-21 Thread Christian König
On 20.08.2012 20:58, Alex Deucher wrote: On Mon, Aug 20, 2012 at 4:08 AM, Christian König deathsim...@vodafone.de wrote: Second and hopefully last round for this patchset. v2: Fix suspend/resume, and incorporate Jeromes comments. Looks good to me. Can you put up a git branch somewhere? Sure

Re: radeon testing

2012-08-21 Thread Christian König
On 21.08.2012 15:51, Alex Deucher wrote: On Mon, Aug 20, 2012 at 3:30 PM, Luca Tettamanti kronos...@gmail.com wrote: On Mon, Aug 20, 2012 at 10:24:01AM -0400, Alex Deucher wrote: I just tested the rebased acpi_patches branch: ACPI part works fine, but I see a big slow down during radeon driver

[PATCH] drm/radeon: fix double free in radeon_gpu_reset

2012-08-29 Thread Christian König
radeon_ring_restore is freeing the memory for the saved ring data. We need to remember that, otherwise we try to restore the ring data again on the next try. Additional to that it shouldn't try the reset infinitely if we have saved ring data. Signed-off-by: Christian König deathsim...@vodafone.de

Re: [PATCH libdrm 1/3] radeon: Fix layout of linear aligned mipmaps on SI.

2012-09-06 Thread Christian König
On 06.09.2012 12:53, Michel Dänzer wrote: From: Michel Dänzer michel.daen...@amd.com Signed-off-by: Michel Dänzer michel.daen...@amd.com Sounds good to me, but shouldn't we also increase the version number? Anyway: Reviewed-by: Christian König christian.koe...@amd.com --- radeon

[PATCH] drm/radeon: fix VM syncing with multiple rings

2012-09-06 Thread Christian König
When a VM is used on more than one ring we need to sync to the last user. Signed-off-by: Christian König deathsim...@vodafone.de --- drivers/gpu/drm/radeon/radeon_cs.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/radeon/radeon_cs.c b/drivers/gpu/drm

Re: [PATCH libdrm 1/3] radeon: Fix layout of linear aligned mipmaps on SI.

2012-09-06 Thread Christian König
On 06.09.2012 15:01, Michel Dänzer wrote: On Don, 2012-09-06 at 13:46 +0200, Christian König wrote: On 06.09.2012 12:53, Michel Dänzer wrote: From: Michel Dänzer michel.daen...@amd.com Signed-off-by: Michel Dänzer michel.daen...@amd.com Sounds good to me, but shouldn't we also increase

[PATCH] drm/radeon: make 64bit fences more robust

2012-09-10 Thread Christian König
Signed-off-by: Christian König deathsim...@vodafone.de Cc: sta...@vger.kernel.org --- drivers/gpu/drm/radeon/radeon_fence.c |6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm/radeon/radeon_fence.c b/drivers/gpu/drm/radeon/radeon_fence.c index 7b737b9

Re: [PATCH] drm/radeon: make 64bit fences more robust

2012-09-10 Thread Christian König
On 10.09.2012 13:12, Michel Dänzer wrote: On Mon, 2012-09-10 at 11:13 +0200, Christian König wrote: Only increase the higher 32bits if we really detect a wrap around. Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=54129 https://bugs.freedesktop.org/show_bug.cgi?id=54662 Possible fixes

[PATCH 3/8] drm/radeon: move IB pool to 1MB offset

2012-09-11 Thread Christian König
Even GPUs can have a null pointer dereference, so move the IB pool to another offset to catch those. Signed-off-by: Christian König deathsim...@vodafone.de --- drivers/gpu/drm/radeon/radeon.h |1 + drivers/gpu/drm/radeon/radeon_gart.c |2 +- drivers/gpu/drm/radeon/radeon_ring.c

[PATCH 1/8] drm/radeon: fix VA range check

2012-09-11 Thread Christian König
The end offset is exclusive not inclusive. Signed-off-by: Christian König deathsim...@vodafone.de --- drivers/gpu/drm/radeon/radeon_gart.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/radeon/radeon_gart.c b/drivers/gpu/drm/radeon/radeon_gart.c index

[PATCH 4/8] drm/radeon: move and rename radeon_bo_va function

2012-09-11 Thread Christian König
It doesn't really belong into the object functions, also rename it to avoid collisions with struct radeon_bo_va. Signed-off-by: Christian König deathsim...@vodafone.de --- drivers/gpu/drm/radeon/radeon.h|2 ++ drivers/gpu/drm/radeon/radeon_gart.c | 34

[PATCH 2/8] drm/radeon: fix VA overlap check

2012-09-11 Thread Christian König
Signed-off-by: Christian König deathsim...@vodafone.de --- drivers/gpu/drm/radeon/radeon_gart.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/radeon/radeon_gart.c b/drivers/gpu/drm/radeon/radeon_gart.c index 614e31a..5694421 100644 --- a/drivers/gpu/drm

[PATCH 5/8] drm/radeon: let bo_reserve take no_intr instead of no_wait param

2012-09-11 Thread Christian König
The no_wait param isn't used anywhere, and actually isn't very usefull at all. Signed-off-by: Christian König deathsim...@vodafone.de --- drivers/gpu/drm/radeon/radeon_object.c |7 +++ drivers/gpu/drm/radeon/radeon_object.h |2 +- 2 files changed, 4 insertions(+), 5 deletions

[PATCH 6/8] drm/radeon: fix gem_close_object handling

2012-09-11 Thread Christian König
Make the reserve non interruptible. Signed-off-by: Christian König deathsim...@vodafone.de --- drivers/gpu/drm/radeon/radeon_gem.c |7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/radeon/radeon_gem.c b/drivers/gpu/drm/radeon/radeon_gem.c index

[PATCH 7/8] drm/radeon: remove radeon_bo_clear_va

2012-09-11 Thread Christian König
It is unnecessary when we remove the va in drm_close. Signed-off-by: Christian König deathsim...@vodafone.de --- drivers/gpu/drm/radeon/radeon_object.c | 11 --- 1 file changed, 11 deletions(-) diff --git a/drivers/gpu/drm/radeon/radeon_object.c b/drivers/gpu/drm/radeon

[PATCH 8/8] drm/radeon: rework the VM code a bit more

2012-09-11 Thread Christian König
Roughly based on how nouveau is handling it. Instead of adding the bo_va when the address is set add the bo_va when the handle is opened, but set the address to zero until userspace tells us where to place it. This fixes another bunch of problems with glamor. Signed-off-by: Christian König

Re: [PATCH 8/8] drm/radeon: rework the VM code a bit more

2012-09-12 Thread Christian König
On 11.09.2012 18:11, Jerome Glisse wrote: On Tue, Sep 11, 2012 at 10:10 AM, Christian König deathsim...@vodafone.de wrote: Roughly based on how nouveau is handling it. Instead of adding the bo_va when the address is set add the bo_va when the handle is opened, but set the address to zero until

Re: [PATCH 7/8] drm/radeon: remove radeon_bo_clear_va

2012-09-12 Thread Christian König
On 11.09.2012 18:12, Jerome Glisse wrote: On Tue, Sep 11, 2012 at 10:10 AM, Christian König deathsim...@vodafone.de wrote: It is unnecessary when we remove the va in drm_close. Signed-off-by: Christian König deathsim...@vodafone.de NAK there is case for which drm_close is not call like ib

Re: [PATCH 8/8] drm/radeon: rework the VM code a bit more

2012-09-12 Thread Christian König
On 12.09.2012 15:54, Jerome Glisse wrote: On Wed, Sep 12, 2012 at 8:08 AM, Christian König deathsim...@vodafone.de wrote: On 11.09.2012 18:11, Jerome Glisse wrote: On Tue, Sep 11, 2012 at 10:10 AM, Christian König deathsim...@vodafone.de wrote: Roughly based on how nouveau is handling

Re: [PATCH 8/8] drm/radeon: rework the VM code a bit more

2012-09-12 Thread Christian König
On 12.09.2012 15:54, Jerome Glisse wrote: On Wed, Sep 12, 2012 at 8:08 AM, Christian König deathsim...@vodafone.de wrote: On 11.09.2012 18:11, Jerome Glisse wrote: On Tue, Sep 11, 2012 at 10:10 AM, Christian König deathsim...@vodafone.de wrote: Roughly based on how nouveau is handling

[PATCH] drm/radeon: make 64bit fences more robust v3

2012-09-13 Thread Christian König
=54662 https://bugzilla.redhat.com/show_bug.cgi?id=846505 https://bugzilla.redhat.com/show_bug.cgi?id=845639 Needs to be adopted for 3.5, but that shouldn't be to much of a problem. Signed-off-by: Christian König deathsim...@vodafone.de Cc: sta...@vger.kernel.org --- drivers/gpu/drm/radeon

Re: [PATCH] Add 2-level GPUVM pagetables support to radeon driver.

2012-09-13 Thread Christian König
Hi Dmitry, as I already noted in our internal discussion, the first step to hierarchical page table support should be to cleanup the set_page interface. Please see the attached patch, it does exactly this. I suggest that you rebase on it and try to don't touch the chipset specific code in

Re: [PATCH] Add 2-level GPUVM pagetables support to radeon driver.

2012-09-13 Thread Christian König
Dropping David and kernel mailing list for now, they are probably not immediately interested in such specific discussion. On 13.09.2012 18:52, Dmitry Cherkassov wrote: Christian, as I already noted in our internal discussion, the first step to hierarchical page table support should be to

Re: [PATCH] Add 2-level GPUVM pagetables support to radeon driver.

2012-09-14 Thread Christian König
On 13.09.2012 20:42, Jerome Glisse wrote: On Thu, Sep 13, 2012 at 2:37 PM, Alex Deucher alexdeuc...@gmail.com wrote: On Thu, Sep 13, 2012 at 2:17 PM, Jerome Glisse j.gli...@gmail.com wrote: On Thu, Sep 13, 2012 at 10:13 AM, Dmitry Cherkasov dcherkas...@gmail.com wrote: PDE/PTE update code

Re: [PATCH 1/2] drm/radeon: refactor set_page chipset interface v2

2012-09-15 Thread Christian König
Looks good in general, some minor comments below: On 14.09.2012 19:49, Dmitry Cherkasov wrote: From: Christian König deathsim...@vodafone.de Cleanup the interface in preparation for hierarchical page tables. v2: * add incr parameter to set_page for simple scattered PTs uptates * added PDE

Re: [PATCH 2/2] Add 2-level GPUVM pagetables support to radeon driver. v2

2012-09-15 Thread Christian König
On 14.09.2012 19:49, Dmitry Cherkasov wrote: PDE/PTE update code uses CP ring for memory writes. All page table entries are preallocated for now in alloc_pt(). It is made as whole because it's hard to divide it to several patches that compile and doesn't break anything being applied separately.

[PATCH 1/2] drm/radeon: refactor set_page chipset interface v3

2012-09-17 Thread Christian König
changed R600_PTE_VALID to R600_ENTRY_VALID to handle PDE too v4 (ck): fix indention style, rework and fix typos in commit message, add documentation for incr parameter, also use incr parameter for system pages Signed-off-by: Christian König deathsim...@vodafone.de Signed-off

[PATCH 2/2] drm/radeon: add 2-level VM pagetables support v4

2012-09-17 Thread Christian König
Signed-off-by: Christian König deathsim...@vodafone.de --- drivers/gpu/drm/radeon/ni.c |4 +- drivers/gpu/drm/radeon/radeon.h | 12 +- drivers/gpu/drm/radeon/radeon_gart.c | 72 +++--- drivers/gpu/drm/radeon/si.c |4 +- 4 files

Re: [PATCH 2/2] drm/radeon: implement dynamic PTs allocation via SA

2012-09-25 Thread Christian König
The general idea looks good on first glance, but see below for further comments. On 25.09.2012 16:44, Dmitry Cherkasov wrote: make dynamic allocation of page tables on demand in radeon_vm_update_pte Signed-off-by: Dmitry Cherkasov dmitrii.cherka...@amd.com ---

Re: [RFC] drm/radeon: make dynamic allocation of page tables on demand in radeon_vm_update_pte v2

2012-10-05 Thread Christian König
Trying to resolve the remaining bugs today. Expect an v3 of the patch this evening or Monday morning. Cheers, Christian. On 04.10.2012 16:32, Dmitry Cherkasov wrote: v2: setup and alloc number of contiguous PTs if possible Warning: Heaven benchmark /sometimes/ fails with this patch after 10

[PATCH] drm/radeon: allocate page tables on demand v3

2012-10-07 Thread Christian König
...@amd.com Signed-off-by: Christian König deathsim...@vodafone.de --- drivers/gpu/drm/radeon/ni.c |2 +- drivers/gpu/drm/radeon/radeon.h | 11 +- drivers/gpu/drm/radeon/radeon_gart.c | 323 ++ 3 files changed, 263 insertions(+), 73 deletions(-) diff

<    1   2   3   4   5   6   7   8   9   10   >