Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openeuler
raspberrypi-kernel
提交
33f409df
R
raspberrypi-kernel
项目概览
openeuler
/
raspberrypi-kernel
通知
13
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
R
raspberrypi-kernel
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
33f409df
编写于
2月 01, 2011
作者:
B
Ben Skeggs
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
drm/nv50-nvc0: tidy evo init failure paths
Signed-off-by:
N
Ben Skeggs
<
bskeggs@redhat.com
>
上级
961b6e68
变更
1
隐藏空白更改
内联
并排
Showing
1 changed file
with
33 addition
and
42 deletion
+33
-42
drivers/gpu/drm/nouveau/nv50_evo.c
drivers/gpu/drm/nouveau/nv50_evo.c
+33
-42
未找到文件。
drivers/gpu/drm/nouveau/nv50_evo.c
浏览文件 @
33f409df
...
...
@@ -198,6 +198,14 @@ nv50_evo_channel_fini(struct nouveau_channel *evo)
}
}
static
void
nv50_evo_destroy
(
struct
drm_device
*
dev
)
{
struct
nv50_display
*
disp
=
nv50_display
(
dev
);
nv50_evo_channel_del
(
&
disp
->
master
);
}
static
int
nv50_evo_create
(
struct
drm_device
*
dev
)
{
...
...
@@ -223,85 +231,69 @@ nv50_evo_create(struct drm_device *dev)
NVOBJ_FLAG_ZERO_ALLOC
,
&
evo
->
ramin
);
if
(
ret
)
{
NV_ERROR
(
dev
,
"Error allocating EVO channel memory: %d
\n
"
,
ret
);
nv50_evo_channel_del
(
&
disp
->
master
);
return
ret
;
goto
err
;
}
ret
=
drm_mm_init
(
&
evo
->
ramin_heap
,
0
,
32768
);
if
(
ret
)
{
NV_ERROR
(
dev
,
"Error initialising EVO PRAMIN heap: %d
\n
"
,
ret
);
nv50_evo_channel_del
(
&
disp
->
master
);
return
ret
;
goto
err
;
}
ret
=
nouveau_gpuobj_new
(
dev
,
evo
,
4096
,
16
,
0
,
&
ramht
);
if
(
ret
)
{
NV_ERROR
(
dev
,
"Unable to allocate EVO RAMHT: %d
\n
"
,
ret
);
nv50_evo_channel_del
(
&
disp
->
master
);
return
ret
;
goto
err
;
}
ret
=
nouveau_ramht_new
(
dev
,
ramht
,
&
evo
->
ramht
);
nouveau_gpuobj_ref
(
NULL
,
&
ramht
);
if
(
ret
)
{
nv50_evo_channel_del
(
&
disp
->
master
);
return
ret
;
}
if
(
ret
)
goto
err
;
/* create some default objects for the scanout memtypes we support */
if
(
dev_priv
->
card_type
>=
NV_C0
)
{
ret
=
nv50_evo_dmaobj_new
(
evo
,
0x3d
,
NvEvoFB32
,
0xfe
,
0x19
,
0
,
0xffffffff
,
0x00000000
);
if
(
ret
)
{
nv50_evo_channel_del
(
&
disp
->
master
);
return
ret
;
}
if
(
ret
)
goto
err
;
ret
=
nv50_evo_dmaobj_new
(
evo
,
0x3d
,
NvEvoVRAM
,
0
,
0x19
,
0
,
dev_priv
->
vram_size
,
0x00020000
);
if
(
ret
)
{
nv50_evo_channel_del
(
&
disp
->
master
);
return
ret
;
}
if
(
ret
)
goto
err
;
ret
=
nv50_evo_dmaobj_new
(
evo
,
0x3d
,
NvEvoVRAM_LP
,
0
,
0x19
,
0
,
dev_priv
->
vram_size
,
0x00000000
);
if
(
ret
)
{
nv50_evo_channel_del
(
&
disp
->
master
);
return
ret
;
}
if
(
ret
)
goto
err
;
}
else
{
ret
=
nv50_evo_dmaobj_new
(
evo
,
0x3d
,
NvEvoFB16
,
0x70
,
0x19
,
0
,
0xffffffff
,
0x00010000
);
if
(
ret
)
{
nv50_evo_channel_del
(
&
disp
->
master
);
return
ret
;
}
if
(
ret
)
goto
err
;
ret
=
nv50_evo_dmaobj_new
(
evo
,
0x3d
,
NvEvoFB32
,
0x7a
,
0x19
,
0
,
0xffffffff
,
0x00010000
);
if
(
ret
)
{
nv50_evo_channel_del
(
&
disp
->
master
);
return
ret
;
}
if
(
ret
)
goto
err
;
ret
=
nv50_evo_dmaobj_new
(
evo
,
0x3d
,
NvEvoVRAM
,
0
,
0x19
,
0
,
dev_priv
->
vram_size
,
0x00010000
);
if
(
ret
)
{
nv50_evo_channel_del
(
&
disp
->
master
);
return
ret
;
}
if
(
ret
)
goto
err
;
ret
=
nv50_evo_dmaobj_new
(
evo
,
0x3d
,
NvEvoVRAM_LP
,
0
,
0x19
,
0
,
dev_priv
->
vram_size
,
0x00010000
);
if
(
ret
)
{
nv50_evo_channel_del
(
&
disp
->
master
);
return
ret
;
}
if
(
ret
)
goto
err
;
}
return
0
;
err:
nv50_evo_destroy
(
dev
);
return
ret
;
}
int
...
...
@@ -324,8 +316,7 @@ nv50_evo_fini(struct drm_device *dev)
{
struct
nv50_display
*
disp
=
nv50_display
(
dev
);
if
(
disp
->
master
)
{
if
(
disp
->
master
)
nv50_evo_channel_fini
(
disp
->
master
);
nv50_evo_channel_del
(
&
disp
->
master
);
}
nv50_evo_destroy
(
dev
);
}
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录