Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
cloud-kernel
提交
fc740f54
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看板
提交
fc740f54
编写于
5月 08, 2018
作者:
B
Ben Skeggs
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
drm/nouveau/gr/gf100-: virtualise sm_id/tpc_nr
Signed-off-by:
N
Ben Skeggs
<
bskeggs@redhat.com
>
上级
ea4a2bb5
变更
20
隐藏空白更改
内联
并排
Showing
20 changed file
with
85 addition
and
67 deletion
+85
-67
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf100.c
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf100.c
+37
-23
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf100.h
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf100.h
+7
-2
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf104.c
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf104.c
+2
-0
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf108.c
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf108.c
+2
-0
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf110.c
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf110.c
+2
-0
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf117.c
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf117.c
+3
-1
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf119.c
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf119.c
+2
-0
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgk104.c
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgk104.c
+3
-1
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgk110.c
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgk110.c
+2
-0
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgk110b.c
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgk110b.c
+2
-0
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgk208.c
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgk208.c
+2
-0
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgk20a.c
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgk20a.c
+3
-1
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgm107.c
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgm107.c
+8
-18
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgm200.c
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgm200.c
+2
-19
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgm20b.c
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgm20b.c
+2
-1
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgp100.c
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgp100.c
+2
-1
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgp102.c
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgp102.c
+1
-0
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgp107.c
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgp107.c
+1
-0
drivers/gpu/drm/nouveau/nvkm/engine/gr/gf100.c
drivers/gpu/drm/nouveau/nvkm/engine/gr/gf100.c
+1
-0
drivers/gpu/drm/nouveau/nvkm/engine/gr/gf100.h
drivers/gpu/drm/nouveau/nvkm/engine/gr/gf100.h
+1
-0
未找到文件。
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf100.c
浏览文件 @
fc740f54
...
...
@@ -1079,28 +1079,6 @@ gf100_grctx_generate_unkn(struct gf100_gr *gr)
{
}
void
gf100_grctx_generate_tpcid
(
struct
gf100_gr
*
gr
)
{
struct
nvkm_device
*
device
=
gr
->
base
.
engine
.
subdev
.
device
;
int
gpc
,
tpc
,
id
;
for
(
tpc
=
0
,
id
=
0
;
tpc
<
4
;
tpc
++
)
{
for
(
gpc
=
0
;
gpc
<
gr
->
gpc_nr
;
gpc
++
)
{
if
(
tpc
<
gr
->
tpc_nr
[
gpc
])
{
nvkm_wr32
(
device
,
TPC_UNIT
(
gpc
,
tpc
,
0x698
),
id
);
nvkm_wr32
(
device
,
TPC_UNIT
(
gpc
,
tpc
,
0x4e8
),
id
);
nvkm_wr32
(
device
,
GPC_UNIT
(
gpc
,
0x0c10
+
tpc
*
4
),
id
);
nvkm_wr32
(
device
,
TPC_UNIT
(
gpc
,
tpc
,
0x088
),
id
);
id
++
;
}
nvkm_wr32
(
device
,
GPC_UNIT
(
gpc
,
0x0c08
),
gr
->
tpc_nr
[
gpc
]);
nvkm_wr32
(
device
,
GPC_UNIT
(
gpc
,
0x0c8c
),
gr
->
tpc_nr
[
gpc
]);
}
}
}
void
gf100_grctx_generate_r406028
(
struct
gf100_gr
*
gr
)
{
...
...
@@ -1230,6 +1208,40 @@ gf100_grctx_generate_r406800(struct gf100_gr *gr)
}
}
void
gf100_grctx_generate_tpc_nr
(
struct
gf100_gr
*
gr
,
int
gpc
)
{
struct
nvkm_device
*
device
=
gr
->
base
.
engine
.
subdev
.
device
;
nvkm_wr32
(
device
,
GPC_UNIT
(
gpc
,
0x0c08
),
gr
->
tpc_nr
[
gpc
]);
nvkm_wr32
(
device
,
GPC_UNIT
(
gpc
,
0x0c8c
),
gr
->
tpc_nr
[
gpc
]);
}
void
gf100_grctx_generate_sm_id
(
struct
gf100_gr
*
gr
,
int
gpc
,
int
tpc
,
int
sm
)
{
struct
nvkm_device
*
device
=
gr
->
base
.
engine
.
subdev
.
device
;
nvkm_wr32
(
device
,
TPC_UNIT
(
gpc
,
tpc
,
0x698
),
sm
);
nvkm_wr32
(
device
,
TPC_UNIT
(
gpc
,
tpc
,
0x4e8
),
sm
);
nvkm_wr32
(
device
,
GPC_UNIT
(
gpc
,
0x0c10
+
tpc
*
4
),
sm
);
nvkm_wr32
(
device
,
TPC_UNIT
(
gpc
,
tpc
,
0x088
),
sm
);
}
void
gf100_grctx_generate_floorsweep
(
struct
gf100_gr
*
gr
)
{
const
struct
gf100_grctx_func
*
func
=
gr
->
func
->
grctx
;
int
tpc
,
gpc
,
sm
;
for
(
tpc
=
0
,
sm
=
0
;
tpc
<
gr
->
tpc_max
;
tpc
++
)
{
for
(
gpc
=
0
;
gpc
<
gr
->
gpc_nr
;
gpc
++
)
{
if
(
tpc
<
gr
->
tpc_nr
[
gpc
])
func
->
sm_id
(
gr
,
gpc
,
tpc
,
sm
++
);
if
(
func
->
tpc_nr
)
func
->
tpc_nr
(
gr
,
gpc
);
}
}
}
void
gf100_grctx_generate_main
(
struct
gf100_gr
*
gr
,
struct
gf100_grctx
*
info
)
{
...
...
@@ -1258,7 +1270,7 @@ gf100_grctx_generate_main(struct gf100_gr *gr, struct gf100_grctx *info)
grctx
->
patch_ltc
(
info
);
grctx
->
unkn
(
gr
);
gf100_grctx_generate_
tpcid
(
gr
);
gf100_grctx_generate_
floorsweep
(
gr
);
gf100_grctx_generate_r406028
(
gr
);
gf100_grctx_generate_r4060a8
(
gr
);
gf100_grctx_generate_r418bb8
(
gr
);
...
...
@@ -1410,4 +1422,6 @@ gf100_grctx = {
.
attrib
=
gf100_grctx_generate_attrib
,
.
attrib_nr_max
=
0x324
,
.
attrib_nr
=
0x218
,
.
sm_id
=
gf100_grctx_generate_sm_id
,
.
tpc_nr
=
gf100_grctx_generate_tpc_nr
,
};
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf100.h
浏览文件 @
fc740f54
...
...
@@ -50,6 +50,9 @@ struct gf100_grctx_func {
u32
alpha_nr
;
/* other patch buffer stuff */
void
(
*
patch_ltc
)(
struct
gf100_grctx
*
);
/* floorsweeping */
void
(
*
sm_id
)(
struct
gf100_gr
*
,
int
gpc
,
int
tpc
,
int
sm
);
void
(
*
tpc_nr
)(
struct
gf100_gr
*
,
int
gpc
);
};
extern
const
struct
gf100_grctx_func
gf100_grctx
;
...
...
@@ -59,11 +62,13 @@ void gf100_grctx_generate_bundle(struct gf100_grctx *);
void
gf100_grctx_generate_pagepool
(
struct
gf100_grctx
*
);
void
gf100_grctx_generate_attrib
(
struct
gf100_grctx
*
);
void
gf100_grctx_generate_unkn
(
struct
gf100_gr
*
);
void
gf100_grctx_generate_
tpcid
(
struct
gf100_gr
*
);
void
gf100_grctx_generate_
floorsweep
(
struct
gf100_gr
*
);
void
gf100_grctx_generate_r406028
(
struct
gf100_gr
*
);
void
gf100_grctx_generate_r4060a8
(
struct
gf100_gr
*
);
void
gf100_grctx_generate_r418bb8
(
struct
gf100_gr
*
);
void
gf100_grctx_generate_r406800
(
struct
gf100_gr
*
);
void
gf100_grctx_generate_sm_id
(
struct
gf100_gr
*
,
int
,
int
,
int
);
void
gf100_grctx_generate_tpc_nr
(
struct
gf100_gr
*
,
int
);
extern
const
struct
gf100_grctx_func
gf108_grctx
;
void
gf108_grctx_generate_attrib
(
struct
gf100_grctx
*
);
...
...
@@ -89,6 +94,7 @@ void gk104_grctx_generate_r418bb8(struct gf100_gr *);
void
gm107_grctx_generate_bundle
(
struct
gf100_grctx
*
);
void
gm107_grctx_generate_pagepool
(
struct
gf100_grctx
*
);
void
gm107_grctx_generate_attrib
(
struct
gf100_grctx
*
);
void
gm107_grctx_generate_sm_id
(
struct
gf100_gr
*
,
int
,
int
,
int
);
extern
const
struct
gf100_grctx_func
gk110_grctx
;
extern
const
struct
gf100_grctx_func
gk110b_grctx
;
...
...
@@ -100,7 +106,6 @@ void gm107_grctx_generate_pagepool(struct gf100_grctx *);
void
gm107_grctx_generate_attrib
(
struct
gf100_grctx
*
);
extern
const
struct
gf100_grctx_func
gm200_grctx
;
void
gm200_grctx_generate_tpcid
(
struct
gf100_gr
*
);
void
gm200_grctx_generate_405b60
(
struct
gf100_gr
*
);
extern
const
struct
gf100_grctx_func
gm20b_grctx
;
...
...
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf104.c
浏览文件 @
fc740f54
...
...
@@ -96,4 +96,6 @@ gf104_grctx = {
.
attrib
=
gf100_grctx_generate_attrib
,
.
attrib_nr_max
=
0x324
,
.
attrib_nr
=
0x218
,
.
sm_id
=
gf100_grctx_generate_sm_id
,
.
tpc_nr
=
gf100_grctx_generate_tpc_nr
,
};
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf108.c
浏览文件 @
fc740f54
...
...
@@ -794,4 +794,6 @@ gf108_grctx = {
.
attrib_nr
=
0x218
,
.
alpha_nr_max
=
0x324
,
.
alpha_nr
=
0x218
,
.
sm_id
=
gf100_grctx_generate_sm_id
,
.
tpc_nr
=
gf100_grctx_generate_tpc_nr
,
};
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf110.c
浏览文件 @
fc740f54
...
...
@@ -347,4 +347,6 @@ gf110_grctx = {
.
attrib
=
gf100_grctx_generate_attrib
,
.
attrib_nr_max
=
0x324
,
.
attrib_nr
=
0x218
,
.
sm_id
=
gf100_grctx_generate_sm_id
,
.
tpc_nr
=
gf100_grctx_generate_tpc_nr
,
};
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf117.c
浏览文件 @
fc740f54
...
...
@@ -240,7 +240,7 @@ gf117_grctx_generate_main(struct gf100_gr *gr, struct gf100_grctx *info)
grctx
->
attrib
(
info
);
grctx
->
unkn
(
gr
);
gf100_grctx_generate_
tpcid
(
gr
);
gf100_grctx_generate_
floorsweep
(
gr
);
gf100_grctx_generate_r406028
(
gr
);
gf100_grctx_generate_r4060a8
(
gr
);
gk104_grctx_generate_r418bb8
(
gr
);
...
...
@@ -275,4 +275,6 @@ gf117_grctx = {
.
attrib_nr
=
0x218
,
.
alpha_nr_max
=
0x7ff
,
.
alpha_nr
=
0x324
,
.
sm_id
=
gf100_grctx_generate_sm_id
,
.
tpc_nr
=
gf100_grctx_generate_tpc_nr
,
};
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf119.c
浏览文件 @
fc740f54
...
...
@@ -517,4 +517,6 @@ gf119_grctx = {
.
attrib_nr
=
0x218
,
.
alpha_nr_max
=
0x324
,
.
alpha_nr
=
0x218
,
.
sm_id
=
gf100_grctx_generate_sm_id
,
.
tpc_nr
=
gf100_grctx_generate_tpc_nr
,
};
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgk104.c
浏览文件 @
fc740f54
...
...
@@ -974,7 +974,7 @@ gk104_grctx_generate_main(struct gf100_gr *gr, struct gf100_grctx *info)
grctx
->
attrib
(
info
);
grctx
->
unkn
(
gr
);
gf100_grctx_generate_
tpcid
(
gr
);
gf100_grctx_generate_
floorsweep
(
gr
);
gf100_grctx_generate_r406028
(
gr
);
gk104_grctx_generate_r418bb8
(
gr
);
gf100_grctx_generate_r406800
(
gr
);
...
...
@@ -1017,4 +1017,6 @@ gk104_grctx = {
.
alpha_nr_max
=
0x7ff
,
.
alpha_nr
=
0x648
,
.
patch_ltc
=
gk104_grctx_generate_patch_ltc
,
.
sm_id
=
gf100_grctx_generate_sm_id
,
.
tpc_nr
=
gf100_grctx_generate_tpc_nr
,
};
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgk110.c
浏览文件 @
fc740f54
...
...
@@ -831,4 +831,6 @@ gk110_grctx = {
.
alpha_nr_max
=
0x7ff
,
.
alpha_nr
=
0x648
,
.
patch_ltc
=
gk104_grctx_generate_patch_ltc
,
.
sm_id
=
gf100_grctx_generate_sm_id
,
.
tpc_nr
=
gf100_grctx_generate_tpc_nr
,
};
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgk110b.c
浏览文件 @
fc740f54
...
...
@@ -92,4 +92,6 @@ gk110b_grctx = {
.
alpha_nr_max
=
0x7ff
,
.
alpha_nr
=
0x648
,
.
patch_ltc
=
gk104_grctx_generate_patch_ltc
,
.
sm_id
=
gf100_grctx_generate_sm_id
,
.
tpc_nr
=
gf100_grctx_generate_tpc_nr
,
};
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgk208.c
浏览文件 @
fc740f54
...
...
@@ -553,4 +553,6 @@ gk208_grctx = {
.
alpha_nr_max
=
0x7ff
,
.
alpha_nr
=
0x648
,
.
patch_ltc
=
gk104_grctx_generate_patch_ltc
,
.
sm_id
=
gf100_grctx_generate_sm_id
,
.
tpc_nr
=
gf100_grctx_generate_tpc_nr
,
};
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgk20a.c
浏览文件 @
fc740f54
...
...
@@ -42,7 +42,7 @@ gk20a_grctx_generate_main(struct gf100_gr *gr, struct gf100_grctx *info)
grctx
->
unkn
(
gr
);
gf100_grctx_generate_
tpcid
(
gr
);
gf100_grctx_generate_
floorsweep
(
gr
);
gf100_grctx_generate_r406028
(
gr
);
gk104_grctx_generate_r418bb8
(
gr
);
gf100_grctx_generate_r406800
(
gr
);
...
...
@@ -82,4 +82,6 @@ gk20a_grctx = {
.
attrib_nr
=
0x240
,
.
alpha_nr_max
=
0x648
+
(
0x648
/
2
),
.
alpha_nr
=
0x648
,
.
sm_id
=
gf100_grctx_generate_sm_id
,
.
tpc_nr
=
gf100_grctx_generate_tpc_nr
,
};
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgm107.c
浏览文件 @
fc740f54
...
...
@@ -930,25 +930,13 @@ gm107_grctx_generate_attrib(struct gf100_grctx *info)
}
}
static
void
gm107_grctx_generate_
tpcid
(
struct
gf100_gr
*
gr
)
void
gm107_grctx_generate_
sm_id
(
struct
gf100_gr
*
gr
,
int
gpc
,
int
tpc
,
int
sm
)
{
struct
nvkm_device
*
device
=
gr
->
base
.
engine
.
subdev
.
device
;
int
gpc
,
tpc
,
id
;
for
(
tpc
=
0
,
id
=
0
;
tpc
<
4
;
tpc
++
)
{
for
(
gpc
=
0
;
gpc
<
gr
->
gpc_nr
;
gpc
++
)
{
if
(
tpc
<
gr
->
tpc_nr
[
gpc
])
{
nvkm_wr32
(
device
,
TPC_UNIT
(
gpc
,
tpc
,
0x698
),
id
);
nvkm_wr32
(
device
,
GPC_UNIT
(
gpc
,
0x0c10
+
tpc
*
4
),
id
);
nvkm_wr32
(
device
,
TPC_UNIT
(
gpc
,
tpc
,
0x088
),
id
);
id
++
;
}
nvkm_wr32
(
device
,
GPC_UNIT
(
gpc
,
0x0c08
),
gr
->
tpc_nr
[
gpc
]);
nvkm_wr32
(
device
,
GPC_UNIT
(
gpc
,
0x0c8c
),
gr
->
tpc_nr
[
gpc
]);
}
}
nvkm_wr32
(
device
,
TPC_UNIT
(
gpc
,
tpc
,
0x698
),
sm
);
nvkm_wr32
(
device
,
GPC_UNIT
(
gpc
,
0x0c10
+
tpc
*
4
),
sm
);
nvkm_wr32
(
device
,
TPC_UNIT
(
gpc
,
tpc
,
0x088
),
sm
);
}
static
void
...
...
@@ -972,7 +960,7 @@ gm107_grctx_generate_main(struct gf100_gr *gr, struct gf100_grctx *info)
grctx
->
attrib
(
info
);
grctx
->
unkn
(
gr
);
g
m107_grctx_generate_tpcid
(
gr
);
g
f100_grctx_generate_floorsweep
(
gr
);
gf100_grctx_generate_r406028
(
gr
);
gk104_grctx_generate_r418bb8
(
gr
);
gf100_grctx_generate_r406800
(
gr
);
...
...
@@ -1016,4 +1004,6 @@ gm107_grctx = {
.
attrib_nr
=
0xaa0
,
.
alpha_nr_max
=
0x1800
,
.
alpha_nr
=
0x1000
,
.
sm_id
=
gm107_grctx_generate_sm_id
,
.
tpc_nr
=
gf100_grctx_generate_tpc_nr
,
};
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgm200.c
浏览文件 @
fc740f54
...
...
@@ -27,24 +27,6 @@
* PGRAPH context implementation
******************************************************************************/
void
gm200_grctx_generate_tpcid
(
struct
gf100_gr
*
gr
)
{
struct
nvkm_device
*
device
=
gr
->
base
.
engine
.
subdev
.
device
;
int
gpc
,
tpc
,
id
;
for
(
tpc
=
0
,
id
=
0
;
tpc
<
TPC_MAX_PER_GPC
;
tpc
++
)
{
for
(
gpc
=
0
;
gpc
<
gr
->
gpc_nr
;
gpc
++
)
{
if
(
tpc
<
gr
->
tpc_nr
[
gpc
])
{
nvkm_wr32
(
device
,
TPC_UNIT
(
gpc
,
tpc
,
0x698
),
id
);
nvkm_wr32
(
device
,
GPC_UNIT
(
gpc
,
0x0c10
+
tpc
*
4
),
id
);
nvkm_wr32
(
device
,
TPC_UNIT
(
gpc
,
tpc
,
0x088
),
id
);
id
++
;
}
}
}
}
void
gm200_grctx_generate_405b60
(
struct
gf100_gr
*
gr
)
{
...
...
@@ -94,7 +76,7 @@ gm200_grctx_generate_main(struct gf100_gr *gr, struct gf100_grctx *info)
grctx
->
attrib
(
info
);
grctx
->
unkn
(
gr
);
g
m200_grctx_generate_tpcid
(
gr
);
g
f100_grctx_generate_floorsweep
(
gr
);
gf100_grctx_generate_r406028
(
gr
);
gk104_grctx_generate_r418bb8
(
gr
);
...
...
@@ -133,4 +115,5 @@ gm200_grctx = {
.
attrib_nr
=
0x400
,
.
alpha_nr_max
=
0x1800
,
.
alpha_nr
=
0x1000
,
.
sm_id
=
gm107_grctx_generate_sm_id
,
};
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgm20b.c
浏览文件 @
fc740f54
...
...
@@ -53,7 +53,7 @@ gm20b_grctx_generate_main(struct gf100_gr *gr, struct gf100_grctx *info)
grctx
->
unkn
(
gr
);
g
m200_grctx_generate_tpcid
(
gr
);
g
f100_grctx_generate_floorsweep
(
gr
);
gm20b_grctx_generate_r406028
(
gr
);
gk104_grctx_generate_r418bb8
(
gr
);
...
...
@@ -98,4 +98,5 @@ gm20b_grctx = {
.
attrib_nr
=
0x400
,
.
alpha_nr_max
=
0xc00
,
.
alpha_nr
=
0x800
,
.
sm_id
=
gm107_grctx_generate_sm_id
,
};
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgp100.c
浏览文件 @
fc740f54
...
...
@@ -138,7 +138,7 @@ gp100_grctx_generate_main(struct gf100_gr *gr, struct gf100_grctx *info)
grctx
->
attrib
(
info
);
grctx
->
unkn
(
gr
);
g
m200_grctx_generate_tpcid
(
gr
);
g
f100_grctx_generate_floorsweep
(
gr
);
gf100_grctx_generate_r406028
(
gr
);
gk104_grctx_generate_r418bb8
(
gr
);
...
...
@@ -174,4 +174,5 @@ gp100_grctx = {
.
attrib_nr
=
0x440
,
.
alpha_nr_max
=
0xc00
,
.
alpha_nr
=
0x800
,
.
sm_id
=
gm107_grctx_generate_sm_id
,
};
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgp102.c
浏览文件 @
fc740f54
...
...
@@ -94,4 +94,5 @@ gp102_grctx = {
.
attrib_nr
=
0x320
,
.
alpha_nr_max
=
0xc00
,
.
alpha_nr
=
0x800
,
.
sm_id
=
gm107_grctx_generate_sm_id
,
};
drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgp107.c
浏览文件 @
fc740f54
...
...
@@ -44,4 +44,5 @@ gp107_grctx = {
.
attrib_nr
=
0x540
,
.
alpha_nr_max
=
0xc00
,
.
alpha_nr
=
0x800
,
.
sm_id
=
gm107_grctx_generate_sm_id
,
};
drivers/gpu/drm/nouveau/nvkm/engine/gr/gf100.c
浏览文件 @
fc740f54
...
...
@@ -1675,6 +1675,7 @@ gf100_gr_oneinit(struct nvkm_gr *base)
gr
->
gpc_nr
=
nvkm_rd32
(
device
,
0x409604
)
&
0x0000001f
;
for
(
i
=
0
;
i
<
gr
->
gpc_nr
;
i
++
)
{
gr
->
tpc_nr
[
i
]
=
nvkm_rd32
(
device
,
GPC_UNIT
(
i
,
0x2608
));
gr
->
tpc_max
=
max
(
gr
->
tpc_max
,
gr
->
tpc_nr
[
i
]);
gr
->
tpc_total
+=
gr
->
tpc_nr
[
i
];
gr
->
ppc_nr
[
i
]
=
gr
->
func
->
ppc_nr
;
for
(
j
=
0
;
j
<
gr
->
ppc_nr
[
i
];
j
++
)
{
...
...
drivers/gpu/drm/nouveau/nvkm/engine/gr/gf100.h
浏览文件 @
fc740f54
...
...
@@ -99,6 +99,7 @@ struct gf100_gr {
u8
rop_nr
;
u8
gpc_nr
;
u8
tpc_nr
[
GPC_MAX
];
u8
tpc_max
;
u8
tpc_total
;
u8
ppc_nr
[
GPC_MAX
];
u8
ppc_mask
[
GPC_MAX
];
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录