Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
linux-davinci-2.6.23
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
linux
linux-davinci-2.6.23
Commits
99da6d86
Commit
99da6d86
authored
Mar 19, 2007
by
Thomas Hellstrom
Committed by
Dave Airlie
Mar 19, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
drm: allow for more generic drm ioctls
Signed-off-by:
Dave Airlie
<
airlied@linux.ie
>
parent
6244270e
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
4 deletions
+9
-4
drivers/char/drm/drm.h
drivers/char/drm/drm.h
+3
-1
drivers/char/drm/drm_drv.c
drivers/char/drm/drm_drv.c
+6
-3
No files found.
drivers/char/drm/drm.h
View file @
99da6d86
...
...
@@ -654,11 +654,13 @@ typedef struct drm_set_version {
/**
* Device specific ioctls should only be in their respective headers
* The device specific ioctl range is from 0x40 to 0x79.
* The device specific ioctl range is from 0x40 to 0x99.
* Generic IOCTLS restart at 0xA0.
*
* \sa drmCommandNone(), drmCommandRead(), drmCommandWrite(), and
* drmCommandReadWrite().
*/
#define DRM_COMMAND_BASE 0x40
#define DRM_COMMAND_END 0xA0
#endif
drivers/char/drm/drm_drv.c
View file @
99da6d86
...
...
@@ -496,11 +496,14 @@ int drm_ioctl(struct inode *inode, struct file *filp,
(
long
)
old_encode_dev
(
priv
->
head
->
device
),
priv
->
authenticated
);
if
(
nr
<
DRIVER_IOCTL_COUNT
)
ioctl
=
&
drm_ioctls
[
nr
];
else
if
((
nr
>=
DRM_COMMAND_BASE
)
if
((
nr
>=
DRIVER_IOCTL_COUNT
)
&&
((
nr
<
DRM_COMMAND_BASE
)
||
(
nr
>=
DRM_COMMAND_END
)))
goto
err_i1
;
if
((
nr
>=
DRM_COMMAND_BASE
)
&&
(
nr
<
DRM_COMMAND_END
)
&&
(
nr
<
DRM_COMMAND_BASE
+
dev
->
driver
->
num_ioctls
))
ioctl
=
&
dev
->
driver
->
ioctls
[
nr
-
DRM_COMMAND_BASE
];
else
if
((
nr
>=
DRM_COMMAND_END
)
||
(
nr
<
DRM_COMMAND_BASE
))
ioctl
=
&
drm_ioctls
[
nr
];
else
goto
err_i1
;
...
...
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