[PATCH V2 12/16] drm/radeon: Make radeon card usable for Loongson.

2012-06-19 Thread j.glisse
On Tue, Jun 19, 2012 at 09:19:55AM +0200, Lucas Stach wrote: > Hello Huacai, > > Am Dienstag, den 19.06.2012, 14:50 +0800 schrieb Huacai Chen: > > 1, Use 32-bit DMA as a workaround (Loongson has a hardware bug that it > >doesn't support DMA address above 4GB). > > This is a bug of your platfo

[PATCH V2 12/16] drm/radeon: Make radeon card usable for Loongson.

2012-06-19 Thread j.glisse
On Tue, Jun 19, 2012 at 02:50:20PM +0800, Huacai Chen wrote: > 1, Use 32-bit DMA as a workaround (Loongson has a hardware bug that it >doesn't support DMA address above 4GB). > 2, Read vga bios offered by system firmware. > 3, Handle io prot correctly for MIPS. > 4, Don't use swiotlb on Loongso

Re: [PATCH V2 12/16] drm/radeon: Make radeon card usable for Loongson.

2012-06-19 Thread j.glisse
On Tue, Jun 19, 2012 at 09:19:55AM +0200, Lucas Stach wrote: > Hello Huacai, > > Am Dienstag, den 19.06.2012, 14:50 +0800 schrieb Huacai Chen: > > 1, Use 32-bit DMA as a workaround (Loongson has a hardware bug that it > >doesn't support DMA address above 4GB). > > This is a bug of your platfo

Re: [PATCH V2 12/16] drm/radeon: Make radeon card usable for Loongson.

2012-06-19 Thread j.glisse
On Tue, Jun 19, 2012 at 02:50:20PM +0800, Huacai Chen wrote: > 1, Use 32-bit DMA as a workaround (Loongson has a hardware bug that it >doesn't support DMA address above 4GB). > 2, Read vga bios offered by system firmware. > 3, Handle io prot correctly for MIPS. > 4, Don't use swiotlb on Loongso

[PATCH 06/10] drm/radeon: fix & improve ih ring handling

2012-05-24 Thread j.glisse
On Thu, May 24, 2012 at 09:49:10AM +0200, Christian K?nig wrote: > From: Christian Koenig > > The spinlock was actually there to protect the > rptr, but rptr was read outside of the locked area. > > Also we don't really need a spinlock here, an > atomic should to quite fine since we only need to

[PATCH 05/10] drm/radeon: remove some unneeded structure members

2012-05-24 Thread j.glisse
On Thu, May 24, 2012 at 09:49:09AM +0200, Christian K?nig wrote: > From: Christian Koenig > > Signed-off-by: Christian Koenig Reviewed-by: Jerome Glisse > --- > drivers/gpu/drm/radeon/radeon.h |2 -- > 1 file changed, 2 deletions(-) > > diff --git a/drivers/gpu/drm/radeon/radeon.h b/dri

[PATCH 04/10] drm/radeon: replace vmram_mutex with mclk_lock v2

2012-05-24 Thread j.glisse
On Thu, May 24, 2012 at 09:49:08AM +0200, Christian K?nig wrote: > It is a rw_semaphore now and only write locked > while changing the clock. Also the lock is renamed > to better reflect what it is protecting. > > v2: Keep the ttm_vm_ops on IGPs > > Signed-off-by: Christian K?nig Reviewed-by: J

[PATCH 03/10] drm/radeon: rework ring syncing code

2012-05-24 Thread j.glisse
On Thu, May 24, 2012 at 09:49:07AM +0200, Christian K?nig wrote: > Move inter ring syncing with semaphores into the > existing ring allocations, with that we need to > lock the ring mutex only once. > > Signed-off-by: Christian K?nig Reviewed-by: Jerome Glisse > --- > drivers/gpu/drm/radeon/e

[PATCH 02/10] drm/radeon: add infrastructure for advanced ring synchronization

2012-05-24 Thread j.glisse
On Thu, May 24, 2012 at 09:49:06AM +0200, Christian K?nig wrote: > Signed-off-by: Christian K?nig Need a small improvement see below, otherwise Reviewed-by: Jerome Glisse > --- > drivers/gpu/drm/radeon/radeon.h | 23 ++- > drivers/gpu/drm/radeon/radeon_fence.c | 73 > ++

[PATCH 01/10] drm/radeon: remove radeon_fence_create

2012-05-24 Thread j.glisse
On Thu, May 24, 2012 at 09:49:05AM +0200, Christian K?nig wrote: > It is completely unnecessary to create fences > before they are emitted, so remove it and a bunch > of checks if fences are emitted or not. > > Signed-off-by: Christian K?nig Reviewed-by: Jerome Glisse > --- > drivers/gpu/drm/

[PATCH 07/10] drm/radeon: apply Murphy's law to the kms irq code

2012-05-24 Thread j.glisse
On Thu, May 24, 2012 at 11:35:15AM -0400, Alex Deucher wrote: > On Thu, May 24, 2012 at 3:49 AM, Christian K?nig > wrote: > > From: Christian Koenig > > > > 1. It is really dangerous to have more than one > > ? spinlock protecting the same information. > > > > 2. radeon_irq_set sometimes wasn't c

Re: [PATCH 06/10] drm/radeon: fix & improve ih ring handling

2012-05-24 Thread j.glisse
On Thu, May 24, 2012 at 09:49:10AM +0200, Christian König wrote: > From: Christian Koenig > > The spinlock was actually there to protect the > rptr, but rptr was read outside of the locked area. > > Also we don't really need a spinlock here, an > atomic should to quite fine since we only need to

Re: [PATCH 05/10] drm/radeon: remove some unneeded structure members

2012-05-24 Thread j.glisse
On Thu, May 24, 2012 at 09:49:09AM +0200, Christian König wrote: > From: Christian Koenig > > Signed-off-by: Christian Koenig Reviewed-by: Jerome Glisse > --- > drivers/gpu/drm/radeon/radeon.h |2 -- > 1 file changed, 2 deletions(-) > > diff --git a/drivers/gpu/drm/radeon/radeon.h b/dri

Re: [PATCH 04/10] drm/radeon: replace vmram_mutex with mclk_lock v2

2012-05-24 Thread j.glisse
On Thu, May 24, 2012 at 09:49:08AM +0200, Christian König wrote: > It is a rw_semaphore now and only write locked > while changing the clock. Also the lock is renamed > to better reflect what it is protecting. > > v2: Keep the ttm_vm_ops on IGPs > > Signed-off-by: Christian König Reviewed-by: J

Re: [PATCH 03/10] drm/radeon: rework ring syncing code

2012-05-24 Thread j.glisse
On Thu, May 24, 2012 at 09:49:07AM +0200, Christian König wrote: > Move inter ring syncing with semaphores into the > existing ring allocations, with that we need to > lock the ring mutex only once. > > Signed-off-by: Christian König Reviewed-by: Jerome Glisse > --- > drivers/gpu/drm/radeon/e

Re: [PATCH 02/10] drm/radeon: add infrastructure for advanced ring synchronization

2012-05-24 Thread j.glisse
On Thu, May 24, 2012 at 09:49:06AM +0200, Christian König wrote: > Signed-off-by: Christian König Need a small improvement see below, otherwise Reviewed-by: Jerome Glisse > --- > drivers/gpu/drm/radeon/radeon.h | 23 ++- > drivers/gpu/drm/radeon/radeon_fence.c | 73 > ++

Re: [PATCH 01/10] drm/radeon: remove radeon_fence_create

2012-05-24 Thread j.glisse
On Thu, May 24, 2012 at 09:49:05AM +0200, Christian König wrote: > It is completely unnecessary to create fences > before they are emitted, so remove it and a bunch > of checks if fences are emitted or not. > > Signed-off-by: Christian König Reviewed-by: Jerome Glisse > --- > drivers/gpu/drm/

Re: [PATCH 07/10] drm/radeon: apply Murphy's law to the kms irq code

2012-05-24 Thread j.glisse
On Thu, May 24, 2012 at 11:35:15AM -0400, Alex Deucher wrote: > On Thu, May 24, 2012 at 3:49 AM, Christian König > wrote: > > From: Christian Koenig > > > > 1. It is really dangerous to have more than one > >   spinlock protecting the same information. > > > > 2. radeon_irq_set sometimes wasn't c