Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
R
R128
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Package Registry
Model registry
Operate
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Ermine
R128
Commits
6f5cee5b
Commit
6f5cee5b
authored
10 years ago
by
Ben Skeggs
Browse files
Options
Downloads
Patches
Plain Diff
drm/nouveau/core: rename parent to handle, use parent for nouveau_parent
Signed-off-by:
Ben Skeggs
<
bskeggs@redhat.com
>
parent
587f7a5b
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
drivers/gpu/drm/nouveau/core/core/ioctl.c
+12
-10
12 additions, 10 deletions
drivers/gpu/drm/nouveau/core/core/ioctl.c
with
12 additions
and
10 deletions
drivers/gpu/drm/nouveau/core/core/ioctl.c
+
12
−
10
View file @
6f5cee5b
...
...
@@ -85,17 +85,17 @@ nvkm_ioctl_sclass(struct nouveau_handle *handle, void *data, u32 size)
}
static
int
nvkm_ioctl_new
(
struct
nouveau_handle
*
parent
,
void
*
data
,
u32
size
)
nvkm_ioctl_new
(
struct
nouveau_handle
*
handle
,
void
*
data
,
u32
size
)
{
union
{
struct
nvif_ioctl_new_v0
v0
;
}
*
args
=
data
;
struct
nouveau_client
*
client
=
nouveau_client
(
parent
->
object
);
struct
nouveau_client
*
client
=
nouveau_client
(
handle
->
object
);
struct
nouveau_object
*
engctx
=
NULL
;
struct
nouveau_object
*
object
=
NULL
;
struct
nouveau_parent
*
parent
;
struct
nouveau_object
*
engine
;
struct
nouveau_oclass
*
oclass
;
struct
nouveau_handle
*
handle
;
u32
_handle
,
_oclass
;
int
ret
;
...
...
@@ -111,16 +111,18 @@ nvkm_ioctl_new(struct nouveau_handle *parent, void *data, u32 size)
args
->
v0
.
version
,
_handle
,
_oclass
,
args
->
v0
.
route
,
args
->
v0
.
token
);
if
(
!
nv_iclass
(
parent
->
object
,
NV_PARENT_CLASS
))
{
nv_debug
(
parent
->
object
,
"cannot have children (ctor)
\n
"
);
if
(
!
nv_iclass
(
handle
->
object
,
NV_PARENT_CLASS
))
{
nv_debug
(
handle
->
object
,
"cannot have children (ctor)
\n
"
);
ret
=
-
ENODEV
;
goto
fail_class
;
}
parent
=
nv_parent
(
handle
->
object
);
/* check that parent supports the requested subclass */
ret
=
nouveau_parent_sclass
(
parent
->
object
,
_oclass
,
&
engine
,
&
oclass
);
ret
=
nouveau_parent_sclass
(
&
parent
->
object
,
_oclass
,
&
engine
,
&
oclass
);
if
(
ret
)
{
nv_debug
(
parent
->
object
,
"illegal class 0x%04x
\n
"
,
_oclass
);
nv_debug
(
parent
,
"illegal class 0x%04x
\n
"
,
_oclass
);
goto
fail_class
;
}
...
...
@@ -138,13 +140,13 @@ nvkm_ioctl_new(struct nouveau_handle *parent, void *data, u32 size)
* between the parent and its children (eg. PGRAPH context)
*/
if
(
engine
&&
nv_engine
(
engine
)
->
cclass
)
{
ret
=
nouveau_object_ctor
(
parent
->
object
,
engine
,
ret
=
nouveau_object_ctor
(
&
parent
->
object
,
engine
,
nv_engine
(
engine
)
->
cclass
,
data
,
size
,
&
engctx
);
if
(
ret
)
goto
fail_engctx
;
}
else
{
nouveau_object_ref
(
parent
->
object
,
&
engctx
);
nouveau_object_ref
(
&
parent
->
object
,
&
engctx
);
}
/* finally, create new object and bind it to its handle */
...
...
@@ -157,7 +159,7 @@ nvkm_ioctl_new(struct nouveau_handle *parent, void *data, u32 size)
if
(
ret
)
goto
fail_init
;
ret
=
nouveau_handle_create
(
parent
->
object
,
parent
->
name
,
ret
=
nouveau_handle_create
(
&
parent
->
object
,
handle
->
name
,
_handle
,
object
,
&
handle
);
if
(
ret
)
goto
fail_handle
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment