Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
cloud-kernel
提交
79bf3a13
cloud-kernel
项目概览
openanolis
/
cloud-kernel
大约 1 年 前同步成功
通知
153
Star
36
Fork
7
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
10
列表
看板
标记
里程碑
合并请求
2
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
cloud-kernel
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
10
Issue
10
列表
看板
标记
里程碑
合并请求
2
合并请求
2
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
79bf3a13
编写于
1月 20, 2010
作者:
M
Michal Simek
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
microblaze: PCI early support for noMMU system
Signed-off-by:
N
Michal Simek
<
monstr@monstr.eu
>
上级
1be53e08
变更
4
隐藏空白更改
内联
并排
Showing
4 changed file
with
18 addition
and
6 deletion
+18
-6
arch/microblaze/include/asm/pgalloc.h
arch/microblaze/include/asm/pgalloc.h
+1
-1
arch/microblaze/include/asm/pgtable.h
arch/microblaze/include/asm/pgtable.h
+6
-0
arch/microblaze/mm/init.c
arch/microblaze/mm/init.c
+9
-5
arch/microblaze/pci/pci-common.c
arch/microblaze/pci/pci-common.c
+2
-0
未找到文件。
arch/microblaze/include/asm/pgalloc.h
浏览文件 @
79bf3a13
...
...
@@ -19,6 +19,7 @@
#include <asm/io.h>
#include <asm/page.h>
#include <asm/cache.h>
#include <asm/pgtable.h>
#define PGDIR_ORDER 0
...
...
@@ -111,7 +112,6 @@ static inline pte_t *pte_alloc_one_kernel(struct mm_struct *mm,
unsigned
long
address
)
{
pte_t
*
pte
;
extern
int
mem_init_done
;
extern
void
*
early_get_page
(
void
);
if
(
mem_init_done
)
{
pte
=
(
pte_t
*
)
__get_free_page
(
GFP_KERNEL
|
...
...
arch/microblaze/include/asm/pgtable.h
浏览文件 @
79bf3a13
...
...
@@ -16,6 +16,10 @@
#define io_remap_pfn_range(vma, vaddr, pfn, size, prot) \
remap_pfn_range(vma, vaddr, pfn, size, prot)
#ifndef __ASSEMBLY__
extern
int
mem_init_done
;
#endif
#ifndef CONFIG_MMU
#define pgd_present(pgd) (1)
/* pages are always present on non MMU */
...
...
@@ -51,6 +55,8 @@ static inline int pte_file(pte_t pte) { return 0; }
#define arch_enter_lazy_cpu_mode() do {} while (0)
#define pgprot_noncached_wc(prot) prot
#else
/* CONFIG_MMU */
#include <asm-generic/4level-fixup.h>
...
...
arch/microblaze/mm/init.c
浏览文件 @
79bf3a13
...
...
@@ -23,6 +23,9 @@
#include <asm/sections.h>
#include <asm/tlb.h>
/* Use for MMU and noMMU because of PCI generic code */
int
mem_init_done
;
#ifndef CONFIG_MMU
unsigned
int
__page_offset
;
EXPORT_SYMBOL
(
__page_offset
);
...
...
@@ -30,7 +33,6 @@ EXPORT_SYMBOL(__page_offset);
#else
DEFINE_PER_CPU
(
struct
mmu_gather
,
mmu_gathers
);
int
mem_init_done
;
static
int
init_bootmem_done
;
#endif
/* CONFIG_MMU */
...
...
@@ -202,9 +204,7 @@ void __init mem_init(void)
printk
(
KERN_INFO
"Memory: %luk/%luk available
\n
"
,
nr_free_pages
()
<<
(
PAGE_SHIFT
-
10
),
num_physpages
<<
(
PAGE_SHIFT
-
10
));
#ifdef CONFIG_MMU
mem_init_done
=
1
;
#endif
}
#ifndef CONFIG_MMU
...
...
@@ -216,6 +216,10 @@ int ___range_ok(unsigned long addr, unsigned long size)
}
EXPORT_SYMBOL
(
___range_ok
);
int
page_is_ram
(
unsigned
long
pfn
)
{
return
__range_ok
(
pfn
,
0
);
}
#else
int
page_is_ram
(
unsigned
long
pfn
)
{
...
...
@@ -344,6 +348,8 @@ void __init *early_get_page(void)
return
p
;
}
#endif
/* CONFIG_MMU */
void
*
__init_refok
alloc_maybe_bootmem
(
size_t
size
,
gfp_t
mask
)
{
if
(
mem_init_done
)
...
...
@@ -365,5 +371,3 @@ void * __init_refok zalloc_maybe_bootmem(size_t size, gfp_t mask)
}
return
p
;
}
#endif
/* CONFIG_MMU */
arch/microblaze/pci/pci-common.c
浏览文件 @
79bf3a13
...
...
@@ -561,11 +561,13 @@ int pci_mmap_legacy_page_range(struct pci_bus *bus,
* memory, effectively behaving just like /dev/zero
*/
if
((
offset
+
size
)
>
hose
->
isa_mem_size
)
{
#ifdef CONFIG_MMU
printk
(
KERN_DEBUG
"Process %s (pid:%d) mapped non-existing PCI"
"legacy memory for 0%04x:%02x
\n
"
,
current
->
comm
,
current
->
pid
,
pci_domain_nr
(
bus
),
bus
->
number
);
#endif
if
(
vma
->
vm_flags
&
VM_SHARED
)
return
shmem_zero_setup
(
vma
);
return
0
;
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录