uclinux-2008R1-RC8(bf561)到VDSP5的移植(56): __grab_cache_page
来源:互联网 发布:863计划 知乎 编辑:程序博客网 时间:2024/05/29 15:35
快乐虾
http://blog.csdn.net/lights_joy/
lights@hb165.com
本文适用于
ADI bf561 DSP
优视BF561EVB开发板
uclinux-2008r1-rc8 (移植到vdsp5)
Visual DSP++ 5.0
欢迎转载,但请保留作者信息
在mm/filemap.c中有一个__grab_cache_page函数,此函数同样引起VDSP编译器错误:
../../mm/filemap.c
At end of source: : internal error: Uncaught exception Assertion failed raised
at ../../../bril/optimiser/dominators.c:910 (in pass
cleanup_scalar_stores_nonopt during compilation of
___grab_cache_page). Please submit a bug report with this message,
the command line used, type of machine and the output of the
compiler when you add -ED -v to the command line. Please also send
us the pre-processed file that is generated by the -ED option (the
file generated is named <original_filename>.i)
1 catastrophic error detected in the compilation of "../../mm/filemap.c".
Compilation aborted.
cc3089: fatal error: Compilation failed
看看这个函数的代码:
/*
* If the page was newly created, increment its refcount and add it to the
* caller's lru-buffering pagevec. This function is specifically for
* generic_file_write().
*/
static inline struct page *
__grab_cache_page(struct address_space *mapping, unsigned long index,
struct page **cached_page, struct pagevec *lru_pvec)
{
int err;
struct page *page;
repeat:
page = find_lock_page(mapping, index);
if (!page) {
if (!*cached_page) {
*cached_page = page_cache_alloc(mapping);
if (!*cached_page)
return NULL;
}
err = add_to_page_cache(*cached_page, mapping,
index, GFP_KERNEL);
if (err == -EEXIST)
goto repeat;
if (err == 0) {
page = *cached_page;
page_cache_get(page);
if (!pagevec_add(lru_pvec, page))
__pagevec_lru_add(lru_pvec);
*cached_page = NULL;
}
}
return page;
}
有了上次的经验,可以肯定问题发生在
*cached_page = page_cache_alloc(mapping);
将之修改为:
*cached_page = __alloc_pages(mapping_gfp_mask(mapping), 0,
NODE_DATA(0)->node_zonelists + gfp_zone(mapping_gfp_mask(mapping)));
搞定!
- uclinux-2008R1-RC8(bf561)到VDSP5的移植(56): __grab_cache_page
- uclinux-2008R1-RC8(bf561)到VDSP5的移植(13):未命名union的问题
- uclinux-2008R1-RC8(bf561)到VDSP5的移植(41):PLL造成的困扰
- uclinux-2008R1-RC8(bf561)到VDSP5的移植(42):__bad_size的问题
- uclinux-2008R1-RC8(bf561)到VDSP5的移植(43):__builtin_return_address的问题
- uclinux-2008R1-RC8(bf561)到VDSP5的移植(44):kmalloc和kzalloc的问题
- uclinux-2008R1-RC8(bf561)到VDSP5的移植(47): d_alloc引出的问题
- uclinux-2008R1-RC8(bf561)到VDSP5的移植(48): __cmpxchg的问题
- uclinux-2008R1-RC8(bf561)到VDSP5的移植(49):kernel_thread_helper的问题
- uclinux-2008R1-RC8(bf561)到VDSP5的移植(50):jiffies_64的定义问题
- uclinux-2008R1-RC8(bf561)到VDSP5的移植(52):cache.s的问题
- uclinux-2008R1-RC8(bf561)到VDSP5的移植(53):reboot.c的问题
- uclinux-2008R1-RC8(bf561)到VDSP5的移植(54): initramfs的问题
- uclinux-2008R1-RC8(bf561)到VDSP5的移植(55): filemap.c的问题
- uclinux-2008R1-RC8(bf561)到VDSP5的移植(1):前言
- uclinux-2008R1-RC8(bf561)到VDSP5的移植(2):代码注释
- uclinux-2008R1-RC8(bf561)到VDSP5的移植(3):Head.s
- uclinux-2008R1-RC8(bf561)到VDSP5的移植(5):CONFIG_BANK_x
- RHEL5关于大内存的问题
- Weekly poll - player class
- 输入三个数(int,float型),求其最大值
- 异步 DSP 核心设计:更低功耗,更高性能
- Using Powerpoints to your benefit.
- uclinux-2008R1-RC8(bf561)到VDSP5的移植(56): __grab_cache_page
- 基于MPEG-4和RTP的网络视频监控系统研究
- 利用Myeclipse快速开发struts应用程序
- Permanent Generation space
- 微软vs2005 180天试用版升正式版【转】
- Age of Conan Powerpoints system
- struts标签使用举例--logic篇
- 我的开发之路
- Gaute Godager says