Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
linux
Commits
960b4381
Commit
960b4381
authored
Jul 04, 2013
by
Ben Skeggs
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
drm/nvc0-/gr: extend one of the magic calculations for >4 GPCs
Signed-off-by:
Ben Skeggs
<
bskeggs@redhat.com
>
parent
0085a605
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
6 deletions
+11
-6
drivers/gpu/drm/nouveau/core/engine/graph/ctxnvc0.c
drivers/gpu/drm/nouveau/core/engine/graph/ctxnvc0.c
+11
-6
No files found.
drivers/gpu/drm/nouveau/core/engine/graph/ctxnvc0.c
View file @
960b4381
...
...
@@ -1014,13 +1014,14 @@ nvc0_grctx_generate_r418bb8(struct nvc0_graph_priv *priv)
void
nvc0_grctx_generate_r406800
(
struct
nvc0_graph_priv
*
priv
)
{
u32
tpc_mask
=
0
,
tpc_set
=
0
;
u8
tpcnr
[
GPC_MAX
],
a
,
b
;
int
gpc
,
tpc
,
i
;
u64
tpc_mask
=
0
,
tpc_set
=
0
;
u8
tpcnr
[
GPC_MAX
];
int
gpc
,
tpc
;
int
i
,
a
,
b
;
memcpy
(
tpcnr
,
priv
->
tpc_nr
,
sizeof
(
priv
->
tpc_nr
));
for
(
gpc
=
0
;
gpc
<
priv
->
gpc_nr
;
gpc
++
)
tpc_mask
|=
((
1
<<
priv
->
tpc_nr
[
gpc
])
-
1
)
<<
(
gpc
*
8
);
tpc_mask
|=
((
1
ULL
<<
priv
->
tpc_nr
[
gpc
])
-
1
)
<<
(
gpc
*
8
);
for
(
i
=
0
,
gpc
=
-
1
,
b
=
-
1
;
i
<
32
;
i
++
)
{
a
=
(
i
*
(
priv
->
tpc_total
-
1
))
/
32
;
...
...
@@ -1034,8 +1035,12 @@ nvc0_grctx_generate_r406800(struct nvc0_graph_priv *priv)
tpc_set
|=
1
<<
((
gpc
*
8
)
+
tpc
);
}
nv_wr32
(
priv
,
0x406800
+
(
i
*
0x20
),
tpc_set
);
nv_wr32
(
priv
,
0x406c00
+
(
i
*
0x20
),
tpc_set
^
tpc_mask
);
nv_wr32
(
priv
,
0x406800
+
(
i
*
0x20
),
lower_32_bits
(
tpc_set
));
nv_wr32
(
priv
,
0x406c00
+
(
i
*
0x20
),
lower_32_bits
(
tpc_set
^
tpc_mask
));
if
(
priv
->
gpc_nr
>
4
)
{
nv_wr32
(
priv
,
0x406804
+
(
i
*
0x20
),
upper_32_bits
(
tpc_set
));
nv_wr32
(
priv
,
0x406c04
+
(
i
*
0x20
),
upper_32_bits
(
tpc_set
^
tpc_mask
));
}
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment