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
7bd9db83
Commit
7bd9db83
authored
May 20, 2010
by
Takashi Iwai
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'topic/nomm' into for-linus
parents
3374cd1a
55c63bd2
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
22 additions
and
8 deletions
+22
-8
sound/core/pcm_native.c
sound/core/pcm_native.c
+22
-8
No files found.
sound/core/pcm_native.c
View file @
7bd9db83
...
...
@@ -3440,14 +3440,28 @@ static int snd_pcm_hw_params_old_user(struct snd_pcm_substream *substream,
#endif
/* CONFIG_SND_SUPPORT_OLD_API */
#ifndef CONFIG_MMU
unsigned
long
dummy_get_unmapped_area
(
struct
file
*
file
,
unsigned
long
addr
,
unsigned
long
len
,
unsigned
long
pgoff
,
unsigned
long
flags
)
{
return
0
;
static
unsigned
long
snd_pcm_get_unmapped_area
(
struct
file
*
file
,
unsigned
long
addr
,
unsigned
long
len
,
unsigned
long
pgoff
,
unsigned
long
flags
)
{
struct
snd_pcm_file
*
pcm_file
=
file
->
private_data
;
struct
snd_pcm_substream
*
substream
=
pcm_file
->
substream
;
struct
snd_pcm_runtime
*
runtime
=
substream
->
runtime
;
unsigned
long
offset
=
pgoff
<<
PAGE_SHIFT
;
switch
(
offset
)
{
case
SNDRV_PCM_MMAP_OFFSET_STATUS
:
return
(
unsigned
long
)
runtime
->
status
;
case
SNDRV_PCM_MMAP_OFFSET_CONTROL
:
return
(
unsigned
long
)
runtime
->
control
;
default:
return
(
unsigned
long
)
runtime
->
dma_area
+
offset
;
}
}
#else
# define
dummy
_get_unmapped_area NULL
# define
snd_pcm
_get_unmapped_area NULL
#endif
/*
...
...
@@ -3467,7 +3481,7 @@ const struct file_operations snd_pcm_f_ops[2] = {
.
compat_ioctl
=
snd_pcm_ioctl_compat
,
.
mmap
=
snd_pcm_mmap
,
.
fasync
=
snd_pcm_fasync
,
.
get_unmapped_area
=
dummy
_get_unmapped_area
,
.
get_unmapped_area
=
snd_pcm
_get_unmapped_area
,
},
{
.
owner
=
THIS_MODULE
,
...
...
@@ -3481,6 +3495,6 @@ const struct file_operations snd_pcm_f_ops[2] = {
.
compat_ioctl
=
snd_pcm_ioctl_compat
,
.
mmap
=
snd_pcm_mmap
,
.
fasync
=
snd_pcm_fasync
,
.
get_unmapped_area
=
dummy
_get_unmapped_area
,
.
get_unmapped_area
=
snd_pcm
_get_unmapped_area
,
}
};
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