lkml.org 
[lkml]   [2006]   [Oct]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH 2.6.19-rc1 update4] drivers: add LCD support
From
Andrew,

Andrew Morton wrote:
> On Thu, 26 Oct 2006 17:48:58 +0000
> Miguel Ojeda Sandonis <maxextreme@gmail.com> wrote:
>
[snip]
>
>> +struct page *cfag12864bfb_vma_nopage(struct vm_area_struct *vma,
>> + unsigned long address, int *type)
>
> This function can have static scope.
>
>> +{
>> + struct page *page;
>> + down(&cfag12864bfb_sem);
>> +
>> + page = virt_to_page(cfag12864b_buffer);
>> + get_page(page);
>> +
>> + if(type)
>> + *type = VM_FAULT_MINOR;
>> +
>> + up(&cfag12864bfb_sem);
>> + return page;
>> +}
>

Any idea why LDD3 states:

An interesting limitation of remap_pfn_range is that it gives
access only to reserved pages and physical addresses above the
top of physical memory.

Is that true we can't do:

buf = (char *)__get_free_page(...);
pfn = PFN_DOWN(virt_to_phys(buf));
remap_pfn_range(vma, vma->vm_start, pfn, PAGE_SIZE, vma->vm_page_prot);

Thanks
Franck
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2006-10-30 10:37    [W:0.088 / U:0.920 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site