Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
cloud-kernel
提交
f83145ec
cloud-kernel
项目概览
openanolis
/
cloud-kernel
1 年多 前同步成功
通知
160
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看板
提交
f83145ec
编写于
4月 24, 2013
作者:
B
Ben Skeggs
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
drm/nv50-/bar: use self as parent for subobjects
Signed-off-by:
N
Ben Skeggs
<
bskeggs@redhat.com
>
上级
b5795c77
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
21 addition
and
15 deletion
+21
-15
drivers/gpu/drm/nouveau/core/subdev/bar/nv50.c
drivers/gpu/drm/nouveau/core/subdev/bar/nv50.c
+12
-10
drivers/gpu/drm/nouveau/core/subdev/bar/nvc0.c
drivers/gpu/drm/nouveau/core/subdev/bar/nvc0.c
+9
-5
未找到文件。
drivers/gpu/drm/nouveau/core/subdev/bar/nv50.c
浏览文件 @
f83145ec
...
...
@@ -122,18 +122,20 @@ nv50_bar_ctor(struct nouveau_object *parent, struct nouveau_object *engine,
if
(
ret
)
return
ret
;
ret
=
nouveau_gpuobj_new
(
parent
,
NULL
,
0x20000
,
0
,
NVOBJ_FLAG_HEAP
,
&
priv
->
mem
);
ret
=
nouveau_gpuobj_new
(
nv_object
(
priv
),
NULL
,
0x20000
,
0
,
NVOBJ_FLAG_HEAP
,
&
priv
->
mem
);
heap
=
nv_object
(
priv
->
mem
);
if
(
ret
)
return
ret
;
ret
=
nouveau_gpuobj_new
(
parent
,
heap
,
(
device
->
chipset
==
0x50
)
?
0x1400
:
0x0200
,
0
,
0
,
&
priv
->
pad
);
ret
=
nouveau_gpuobj_new
(
nv_object
(
priv
),
heap
,
(
device
->
chipset
==
0x50
)
?
0x1400
:
0x0200
,
0
,
0
,
&
priv
->
pad
);
if
(
ret
)
return
ret
;
ret
=
nouveau_gpuobj_new
(
parent
,
heap
,
0x4000
,
0
,
0
,
&
priv
->
pgd
);
ret
=
nouveau_gpuobj_new
(
nv_object
(
priv
),
heap
,
0x4000
,
0
,
0
,
&
priv
->
pgd
);
if
(
ret
)
return
ret
;
...
...
@@ -145,9 +147,9 @@ nv50_bar_ctor(struct nouveau_object *parent, struct nouveau_object *engine,
if
(
ret
)
return
ret
;
ret
=
nouveau_gpuobj_new
(
parent
,
heap
,
((
limit
--
-
start
)
>>
12
)
*
8
,
0x1000
,
NVOBJ_FLAG_ZERO_ALLOC
,
&
vm
->
pgt
[
0
].
obj
[
0
]);
ret
=
nouveau_gpuobj_new
(
nv_object
(
priv
),
heap
,
((
limit
--
-
start
)
>>
12
)
*
8
,
0x1000
,
NVOBJ_FLAG_ZERO_ALLOC
,
&
vm
->
pgt
[
0
].
obj
[
0
]);
vm
->
pgt
[
0
].
refcount
[
0
]
=
1
;
if
(
ret
)
return
ret
;
...
...
@@ -157,7 +159,7 @@ nv50_bar_ctor(struct nouveau_object *parent, struct nouveau_object *engine,
if
(
ret
)
return
ret
;
ret
=
nouveau_gpuobj_new
(
parent
,
heap
,
24
,
16
,
0
,
&
priv
->
bar3
);
ret
=
nouveau_gpuobj_new
(
nv_object
(
priv
)
,
heap
,
24
,
16
,
0
,
&
priv
->
bar3
);
if
(
ret
)
return
ret
;
...
...
@@ -182,7 +184,7 @@ nv50_bar_ctor(struct nouveau_object *parent, struct nouveau_object *engine,
if
(
ret
)
return
ret
;
ret
=
nouveau_gpuobj_new
(
parent
,
heap
,
24
,
16
,
0
,
&
priv
->
bar1
);
ret
=
nouveau_gpuobj_new
(
nv_object
(
priv
)
,
heap
,
24
,
16
,
0
,
&
priv
->
bar1
);
if
(
ret
)
return
ret
;
...
...
drivers/gpu/drm/nouveau/core/subdev/bar/nvc0.c
浏览文件 @
f83145ec
...
...
@@ -101,12 +101,14 @@ nvc0_bar_ctor(struct nouveau_object *parent, struct nouveau_object *engine,
return
ret
;
/* BAR3 */
ret
=
nouveau_gpuobj_new
(
parent
,
NULL
,
0x1000
,
0
,
0
,
&
priv
->
bar
[
0
].
mem
);
ret
=
nouveau_gpuobj_new
(
nv_object
(
priv
),
NULL
,
0x1000
,
0
,
0
,
&
priv
->
bar
[
0
].
mem
);
mem
=
priv
->
bar
[
0
].
mem
;
if
(
ret
)
return
ret
;
ret
=
nouveau_gpuobj_new
(
parent
,
NULL
,
0x8000
,
0
,
0
,
&
priv
->
bar
[
0
].
pgd
);
ret
=
nouveau_gpuobj_new
(
nv_object
(
priv
),
NULL
,
0x8000
,
0
,
0
,
&
priv
->
bar
[
0
].
pgd
);
if
(
ret
)
return
ret
;
...
...
@@ -114,7 +116,7 @@ nvc0_bar_ctor(struct nouveau_object *parent, struct nouveau_object *engine,
if
(
ret
)
return
ret
;
ret
=
nouveau_gpuobj_new
(
parent
,
NULL
,
ret
=
nouveau_gpuobj_new
(
nv_object
(
priv
)
,
NULL
,
(
pci_resource_len
(
pdev
,
3
)
>>
12
)
*
8
,
0x1000
,
NVOBJ_FLAG_ZERO_ALLOC
,
&
vm
->
pgt
[
0
].
obj
[
0
]);
...
...
@@ -133,12 +135,14 @@ nvc0_bar_ctor(struct nouveau_object *parent, struct nouveau_object *engine,
nv_wo32
(
mem
,
0x020c
,
upper_32_bits
(
pci_resource_len
(
pdev
,
3
)
-
1
));
/* BAR1 */
ret
=
nouveau_gpuobj_new
(
parent
,
NULL
,
0x1000
,
0
,
0
,
&
priv
->
bar
[
1
].
mem
);
ret
=
nouveau_gpuobj_new
(
nv_object
(
priv
),
NULL
,
0x1000
,
0
,
0
,
&
priv
->
bar
[
1
].
mem
);
mem
=
priv
->
bar
[
1
].
mem
;
if
(
ret
)
return
ret
;
ret
=
nouveau_gpuobj_new
(
parent
,
NULL
,
0x8000
,
0
,
0
,
&
priv
->
bar
[
1
].
pgd
);
ret
=
nouveau_gpuobj_new
(
nv_object
(
priv
),
NULL
,
0x8000
,
0
,
0
,
&
priv
->
bar
[
1
].
pgd
);
if
(
ret
)
return
ret
;
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录