linux-fbdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* can't access video memory?
@ 2005-09-09 15:18 Zack Smith
  2005-09-10  5:46 ` Antonino A. Daplas
  0 siblings, 1 reply; 4+ messages in thread
From: Zack Smith @ 2005-09-09 15:18 UTC (permalink / raw)
  To: linux-fbdev-devel

Hi all,

As an experiment I tried accessing a part of (shared) video memory
on my system that is not being used for display data, and this caused the
kernel to crash. I have 6 megs of space and the display is using only half,
but accessing above the 3 meg mark causes the problem. Accessing
the lower 3 megs works fine.

Does anyone know what might cause this?

Thanks,
Zack Smith



-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA
Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: can't access video memory?
  2005-09-09 15:18 Zack Smith
@ 2005-09-10  5:46 ` Antonino A. Daplas
  0 siblings, 0 replies; 4+ messages in thread
From: Antonino A. Daplas @ 2005-09-10  5:46 UTC (permalink / raw)
  To: linux-fbdev-devel; +Cc: Zack Smith

Zack Smith wrote:
> Hi all,
> 
> As an experiment I tried accessing a part of (shared) video memory
> on my system that is not being used for display data, and this caused the
> kernel to crash. I have 6 megs of space and the display is using only half,
> but accessing above the 3 meg mark causes the problem. Accessing
> the lower 3 megs works fine.
> 
> Does anyone know what might cause this?

Depends on the driver.  It's possible that the driver did not ioremap
the entire graphics aperture (ie ioremapped only the first 3 megs).  Or
the driver set info->fix.smem_len to only 3 MB instead of 6.

Some drivers are now differentiating between remapped size vs actual
physical size (radeonfb).  info->screen_size, if not zero, tells the
amount of the remapped size while info->fix.smem_len, the actual physical
size.

Tony


-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA
Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: can't access video memory?
       [not found] <091020051443.548.4322F10400014A8E000002242207020653079A0D00@comcast.net>
@ 2005-09-10 15:01 ` Jon Smirl
  2005-09-10 20:32 ` Antonino A. Daplas
  1 sibling, 0 replies; 4+ messages in thread
From: Jon Smirl @ 2005-09-10 15:01 UTC (permalink / raw)
  To: linux-fbdev-devel, fbui

On 9/10/05, fbui@comcast.net <fbui@comcast.net> wrote:
> > Zack Smith wrote: 
> > > Does anyone know what might cause this? 

On x86 the kernel is limited to 1GB of virtual address space. So
physical memory plus mapped video needs to total less than 1GB for
best performance.

Systems with 1GB of RAM or more want to minimize mapped VRAM. Anything
that is mapped over the minimum pushes kernel data structures out of
normal access and into highmem access which is significantly slower.
For example mapping a 512MB video card on a 1GB system knocks about
10% off from your system performance since it pushes 512MB of RAM into
highmem access mode.

The drivers aren't smart enough to look for less than 1GB of physical
memory and expand their mapped areas.

None of this applies from user space. There are no problems with
mapping the full card.

-- 
Jon Smirl
jonsmirl@gmail.com


-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA
Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: can't access video memory?
       [not found] <091020051443.548.4322F10400014A8E000002242207020653079A0D00@comcast.net>
  2005-09-10 15:01 ` can't access video memory? Jon Smirl
@ 2005-09-10 20:32 ` Antonino A. Daplas
  1 sibling, 0 replies; 4+ messages in thread
From: Antonino A. Daplas @ 2005-09-10 20:32 UTC (permalink / raw)
  To: linux-fbdev-devel; +Cc: Zack Smith

fbui@comcast.net wrote:
> This is for the vesa driver in 2.6.9. Searching the kernel mailing list
> archive I found mention of this bug with a patch to fix it.
> 
> Thus:
>   http://www.ussg.iu.edu/hypermail/linux/kernel/0410.0/0099.html
> 

This patch is already applied to recent 2.6 kernels.

Tony


-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA
Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2005-09-10 20:33 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <091020051443.548.4322F10400014A8E000002242207020653079A0D00@comcast.net>
2005-09-10 15:01 ` can't access video memory? Jon Smirl
2005-09-10 20:32 ` Antonino A. Daplas
2005-09-09 15:18 Zack Smith
2005-09-10  5:46 ` Antonino A. Daplas

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).