I am developing a fbmem driver for an SA-1100 based board and am stuck in
the fb_mmap
function. The video memory on the SA-1100 cannot be page aligned due to an
LCD driver
requirement that the palette be page aligned. The video memory must be
contiguously
located at the end of the palette area (512 bytes).
The fb_mmap function is being called with vma->offset=0 and the vma->start
and vma->end
corresponding to the video memory size (640x480). The vma->start parameter
passed
into the function is page aligned; presumably by the kernel in the mmap
system call.
Since the video memory is not page aligned, I cannot call remap_page_range
to map it
into the page aligned vma->start address. In the fbmem function, I have
tried using
remap_page_range to map in the surrounding aligned page and modifying
vma->start
to point to a non-aligned address before returning. However, the kernel
(2.0.35) still
returns the original vma->start address to the mmap system caller. Thus, the
application does not get the updated value.
How can I accomplish the fb_mmap function for this fbmem driver?
Thanks,
Eric
Eric Thomas (E-mail).vcf