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
bc3cfd18
Commit
bc3cfd18
authored
Jan 15, 2020
by
Ben Skeggs
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
drm/nouveau/flcn: specify EMEM address from subdev
Signed-off-by:
Ben Skeggs
<
bskeggs@redhat.com
>
parent
ca3190e3
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
9 additions
and
8 deletions
+9
-8
drivers/gpu/drm/nouveau/include/nvkm/engine/falcon.h
drivers/gpu/drm/nouveau/include/nvkm/engine/falcon.h
+1
-1
drivers/gpu/drm/nouveau/nvkm/engine/sec2/gp102.c
drivers/gpu/drm/nouveau/nvkm/engine/sec2/gp102.c
+1
-0
drivers/gpu/drm/nouveau/nvkm/engine/sec2/tu102.c
drivers/gpu/drm/nouveau/nvkm/engine/sec2/tu102.c
+1
-0
drivers/gpu/drm/nouveau/nvkm/falcon/base.c
drivers/gpu/drm/nouveau/nvkm/falcon/base.c
+0
-1
drivers/gpu/drm/nouveau/nvkm/falcon/v1.c
drivers/gpu/drm/nouveau/nvkm/falcon/v1.c
+6
-6
No files found.
drivers/gpu/drm/nouveau/include/nvkm/engine/falcon.h
View file @
bc3cfd18
...
...
@@ -30,7 +30,6 @@ struct nvkm_falcon {
u8
version
;
u8
secret
;
bool
debug
;
bool
has_emem
;
struct
nvkm_memory
*
core
;
bool
external
;
...
...
@@ -84,6 +83,7 @@ struct nvkm_falcon_func {
void
(
*
load_imem
)(
struct
nvkm_falcon
*
,
void
*
,
u32
,
u32
,
u16
,
u8
,
bool
);
void
(
*
load_dmem
)(
struct
nvkm_falcon
*
,
void
*
,
u32
,
u32
,
u8
);
void
(
*
read_dmem
)(
struct
nvkm_falcon
*
,
u32
,
u32
,
u8
,
void
*
);
u32
emem_addr
;
void
(
*
bind_context
)(
struct
nvkm_falcon
*
,
struct
nvkm_memory
*
);
int
(
*
wait_for_halt
)(
struct
nvkm_falcon
*
,
u32
);
int
(
*
clear_interrupt
)(
struct
nvkm_falcon
*
,
u32
);
...
...
drivers/gpu/drm/nouveau/nvkm/engine/sec2/gp102.c
View file @
bc3cfd18
...
...
@@ -92,6 +92,7 @@ gp102_sec2_flcn = {
.
load_imem
=
nvkm_falcon_v1_load_imem
,
.
load_dmem
=
nvkm_falcon_v1_load_dmem
,
.
read_dmem
=
nvkm_falcon_v1_read_dmem
,
.
emem_addr
=
0x01000000
,
.
bind_context
=
gp102_sec2_flcn_bind_context
,
.
wait_for_halt
=
nvkm_falcon_v1_wait_for_halt
,
.
clear_interrupt
=
nvkm_falcon_v1_clear_interrupt
,
...
...
drivers/gpu/drm/nouveau/nvkm/engine/sec2/tu102.c
View file @
bc3cfd18
...
...
@@ -27,6 +27,7 @@ tu102_sec2_flcn = {
.
load_imem
=
nvkm_falcon_v1_load_imem
,
.
load_dmem
=
nvkm_falcon_v1_load_dmem
,
.
read_dmem
=
nvkm_falcon_v1_read_dmem
,
.
emem_addr
=
0x01000000
,
.
bind_context
=
gp102_sec2_flcn_bind_context
,
.
wait_for_halt
=
nvkm_falcon_v1_wait_for_halt
,
.
clear_interrupt
=
nvkm_falcon_v1_clear_interrupt
,
...
...
drivers/gpu/drm/nouveau/nvkm/falcon/base.c
View file @
bc3cfd18
...
...
@@ -170,7 +170,6 @@ nvkm_falcon_oneinit(struct nvkm_falcon *falcon)
break
;
case
NVKM_ENGINE_SEC2
:
debug_reg
=
0x408
;
falcon
->
has_emem
=
true
;
break
;
case
NVKM_SUBDEV_GSP
:
debug_reg
=
0x0
;
/*XXX*/
...
...
drivers/gpu/drm/nouveau/nvkm/falcon/v1.c
View file @
bc3cfd18
...
...
@@ -89,18 +89,17 @@ nvkm_falcon_v1_load_emem(struct nvkm_falcon *falcon, void *data, u32 start,
}
}
static
const
u32
EMEM_START_ADDR
=
0x1000000
;
void
nvkm_falcon_v1_load_dmem
(
struct
nvkm_falcon
*
falcon
,
void
*
data
,
u32
start
,
u32
size
,
u8
port
)
{
const
struct
nvkm_falcon_func
*
func
=
falcon
->
func
;
u8
rem
=
size
%
4
;
int
i
;
if
(
start
>=
EMEM_START_ADDR
&&
falcon
->
has_emem
)
if
(
func
->
emem_addr
&&
start
>=
func
->
emem_addr
)
return
nvkm_falcon_v1_load_emem
(
falcon
,
data
,
start
-
EMEM_START_ADDR
,
size
,
start
-
func
->
emem_addr
,
size
,
port
);
size
-=
rem
;
...
...
@@ -152,11 +151,12 @@ void
nvkm_falcon_v1_read_dmem
(
struct
nvkm_falcon
*
falcon
,
u32
start
,
u32
size
,
u8
port
,
void
*
data
)
{
const
struct
nvkm_falcon_func
*
func
=
falcon
->
func
;
u8
rem
=
size
%
4
;
int
i
;
if
(
start
>=
EMEM_START_ADDR
&&
falcon
->
has_emem
)
return
nvkm_falcon_v1_read_emem
(
falcon
,
start
-
EMEM_START_ADDR
,
if
(
func
->
emem_addr
&&
start
>=
func
->
emem_addr
)
return
nvkm_falcon_v1_read_emem
(
falcon
,
start
-
func
->
emem_addr
,
size
,
port
,
data
);
size
-=
rem
;
...
...
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