* gma500: Mask out bits not part of the page table base address
@ 2011-07-07 22:06 Patrik Jakobsson
2011-07-07 22:15 ` Alan Cox
0 siblings, 1 reply; 3+ messages in thread
From: Patrik Jakobsson @ 2011-07-07 22:06 UTC (permalink / raw)
To: alan; +Cc: linux-kernel, greg
Otherwise we can't ioremap the gtt and the screen gets garbled.
Signed-off-by: Patrik Jakobsson <patrik.r.jakobsson@gmail.com>
---
diff --git a/drivers/staging/gma500/gtt.c b/drivers/staging/gma500/gtt.c
index 28f2261..78dd01b 100644
--- a/drivers/staging/gma500/gtt.c
+++ b/drivers/staging/gma500/gtt.c
@@ -397,7 +397,7 @@ int psb_gtt_init(struct drm_device *dev, int resume)
/* The root resource we allocate address space from */
dev_priv->gtt_initialized = 1;
- pg->gtt_phys_start = dev_priv->pge_ctl;
+ pg->gtt_phys_start = dev_priv->pge_ctl & PAGE_MASK;
/*
* FIXME: video mmu has hw bug to access 0x0D0000000,
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: gma500: Mask out bits not part of the page table base address
2011-07-07 22:06 gma500: Mask out bits not part of the page table base address Patrik Jakobsson
@ 2011-07-07 22:15 ` Alan Cox
2011-07-07 22:43 ` Patrik Jakobsson
0 siblings, 1 reply; 3+ messages in thread
From: Alan Cox @ 2011-07-07 22:15 UTC (permalink / raw)
To: Patrik Jakobsson; +Cc: linux-kernel, greg
On Fri, 8 Jul 2011 00:06:21 +0200
Patrik Jakobsson <patrik.r.jakobsson@gmail.com> wrote:
> Otherwise we can't ioremap the gtt and the screen gets garbled.
>
> Signed-off-by: Patrik Jakobsson <patrik.r.jakobsson@gmail.com>
> ---
>
> diff --git a/drivers/staging/gma500/gtt.c b/drivers/staging/gma500/gtt.c
> index 28f2261..78dd01b 100644
> --- a/drivers/staging/gma500/gtt.c
> +++ b/drivers/staging/gma500/gtt.c
> @@ -397,7 +397,7 @@ int psb_gtt_init(struct drm_device *dev, int resume)
> /* The root resource we allocate address space from */
> dev_priv->gtt_initialized = 1;
>
> - pg->gtt_phys_start = dev_priv->pge_ctl;
> + pg->gtt_phys_start = dev_priv->pge_ctl & PAGE_MASK;
Umm yes I suppose if its already been enabled that'll be slightly
important
Acked-by: Alan Cox <alan@linux.intel.com>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: gma500: Mask out bits not part of the page table base address
2011-07-07 22:15 ` Alan Cox
@ 2011-07-07 22:43 ` Patrik Jakobsson
0 siblings, 0 replies; 3+ messages in thread
From: Patrik Jakobsson @ 2011-07-07 22:43 UTC (permalink / raw)
To: Alan Cox; +Cc: linux-kernel, greg
> Umm yes I suppose if its already been enabled that'll be slightly
> important
Yes :) and I guess that the size (bits 3:1) of the gtt could theoretically be
something other than 512KB. Is it safe to just look at the pci resource length
or should one perhaps cross-check it against the control register?
Maybe I just worry too much
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2011-07-07 22:43 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-07-07 22:06 gma500: Mask out bits not part of the page table base address Patrik Jakobsson
2011-07-07 22:15 ` Alan Cox
2011-07-07 22:43 ` Patrik Jakobsson
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®