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
9aecbada
Commit
9aecbada
authored
Apr 25, 2013
by
Ben Skeggs
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
drm/nouveau/device: have engine object initialised before creation
Signed-off-by:
Ben Skeggs
<
bskeggs@redhat.com
>
parent
dded35de
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
12 additions
and
5 deletions
+12
-5
drivers/gpu/drm/nouveau/core/core/client.c
drivers/gpu/drm/nouveau/core/core/client.c
+3
-2
drivers/gpu/drm/nouveau/core/core/parent.c
drivers/gpu/drm/nouveau/core/core/parent.c
+7
-1
drivers/gpu/drm/nouveau/core/engine/device/base.c
drivers/gpu/drm/nouveau/core/engine/device/base.c
+2
-1
drivers/gpu/drm/nouveau/core/include/engine/device.h
drivers/gpu/drm/nouveau/core/include/engine/device.h
+0
-1
No files found.
drivers/gpu/drm/nouveau/core/core/client.c
View file @
9aecbada
...
...
@@ -58,8 +58,9 @@ nouveau_client_create_(const char *name, u64 devname, const char *cfg,
return
-
ENODEV
;
ret
=
nouveau_namedb_create_
(
NULL
,
NULL
,
&
nouveau_client_oclass
,
NV_CLIENT_CLASS
,
nouveau_device_sclass
,
0
,
length
,
pobject
);
NV_CLIENT_CLASS
,
NULL
,
(
1ULL
<<
NVDEV_ENGINE_DEVICE
),
length
,
pobject
);
client
=
*
pobject
;
if
(
ret
)
return
ret
;
...
...
drivers/gpu/drm/nouveau/core/core/parent.c
View file @
9aecbada
...
...
@@ -24,6 +24,7 @@
#include <core/object.h>
#include <core/parent.h>
#include <core/client.h>
int
nouveau_parent_sclass
(
struct
nouveau_object
*
parent
,
u16
handle
,
...
...
@@ -50,7 +51,12 @@ nouveau_parent_sclass(struct nouveau_object *parent, u16 handle,
while
(
mask
)
{
int
i
=
ffsll
(
mask
)
-
1
;
if
((
engine
=
nouveau_engine
(
parent
,
i
)))
{
if
(
nv_iclass
(
parent
,
NV_CLIENT_CLASS
))
engine
=
nv_engine
(
nv_client
(
parent
)
->
device
);
else
engine
=
nouveau_engine
(
parent
,
i
);
if
(
engine
)
{
oclass
=
engine
->
sclass
;
while
(
oclass
->
ofuncs
)
{
if
((
oclass
->
handle
&
0xffff
)
==
handle
)
{
...
...
drivers/gpu/drm/nouveau/core/engine/device/base.c
View file @
9aecbada
...
...
@@ -413,7 +413,7 @@ nouveau_devobj_ofuncs = {
/******************************************************************************
* nouveau_device: engine functions
*****************************************************************************/
struct
nouveau_oclass
st
atic
st
ruct
nouveau_oclass
nouveau_device_sclass
[]
=
{
{
0x0080
,
&
nouveau_devobj_ofuncs
},
{}
...
...
@@ -470,6 +470,7 @@ nouveau_device_create_(struct pci_dev *pdev, u64 name, const char *sname,
device
->
name
=
sname
;
nv_subdev
(
device
)
->
debug
=
nouveau_dbgopt
(
device
->
dbgopt
,
"DEVICE"
);
nv_engine
(
device
)
->
sclass
=
nouveau_device_sclass
;
list_add
(
&
device
->
head
,
&
nv_devices
);
done:
mutex_unlock
(
&
nv_devices_mutex
);
...
...
drivers/gpu/drm/nouveau/core/include/engine/device.h
View file @
9aecbada
...
...
@@ -18,7 +18,6 @@ int nv50_identify(struct nouveau_device *);
int
nvc0_identify
(
struct
nouveau_device
*
);
int
nve0_identify
(
struct
nouveau_device
*
);
extern
struct
nouveau_oclass
nouveau_device_sclass
[];
struct
nouveau_device
*
nouveau_device_find
(
u64
name
);
#endif
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