Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
linux-davinci
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
Commits
a860820d
Commit
a860820d
authored
May 06, 2009
by
David S. Miller
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'linux-2.6.30.y' of
git://git.kernel.org/pub/scm/linux/kernel/git/inaky/wimax
parents
457ca7bb
94c7f2d4
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
21 additions
and
7 deletions
+21
-7
net/wimax/op-msg.c
net/wimax/op-msg.c
+6
-5
net/wimax/stack.c
net/wimax/stack.c
+15
-2
No files found.
net/wimax/op-msg.c
View file @
a860820d
...
...
@@ -149,7 +149,8 @@ struct sk_buff *wimax_msg_alloc(struct wimax_dev *wimax_dev,
}
result
=
nla_put
(
skb
,
WIMAX_GNL_MSG_DATA
,
size
,
msg
);
if
(
result
<
0
)
{
dev_err
(
dev
,
"no memory to add payload in attribute
\n
"
);
dev_err
(
dev
,
"no memory to add payload (msg %p size %zu) in "
"attribute: %d
\n
"
,
msg
,
size
,
result
);
goto
error_nla_put
;
}
genlmsg_end
(
skb
,
genl_msg
);
...
...
@@ -299,10 +300,10 @@ int wimax_msg(struct wimax_dev *wimax_dev, const char *pipe_name,
struct
sk_buff
*
skb
;
skb
=
wimax_msg_alloc
(
wimax_dev
,
pipe_name
,
buf
,
size
,
gfp_flags
);
if
(
skb
==
NULL
)
goto
error_msg_new
;
if
(
IS_ERR
(
skb
))
result
=
PTR_ERR
(
skb
);
else
result
=
wimax_msg_send
(
wimax_dev
,
skb
);
error_msg_new:
return
result
;
}
EXPORT_SYMBOL_GPL
(
wimax_msg
);
...
...
net/wimax/stack.c
View file @
a860820d
...
...
@@ -338,7 +338,20 @@ out:
*/
void
wimax_state_change
(
struct
wimax_dev
*
wimax_dev
,
enum
wimax_st
new_state
)
{
/*
* A driver cannot take the wimax_dev out of the
* __WIMAX_ST_NULL state unless by calling wimax_dev_add(). If
* the wimax_dev's state is still NULL, we ignore any request
* to change its state because it means it hasn't been yet
* registered.
*
* There is no need to complain about it, as routines that
* call this might be shared from different code paths that
* are called before or after wimax_dev_add() has done its
* job.
*/
mutex_lock
(
&
wimax_dev
->
mutex
);
if
(
wimax_dev
->
state
>
__WIMAX_ST_NULL
)
__wimax_state_change
(
wimax_dev
,
new_state
);
mutex_unlock
(
&
wimax_dev
->
mutex
);
return
;
...
...
@@ -376,7 +389,7 @@ EXPORT_SYMBOL_GPL(wimax_state_get);
void
wimax_dev_init
(
struct
wimax_dev
*
wimax_dev
)
{
INIT_LIST_HEAD
(
&
wimax_dev
->
id_table_node
);
__wimax_state_set
(
wimax_dev
,
WIMAX_ST_UNINITIALIZED
);
__wimax_state_set
(
wimax_dev
,
__WIMAX_ST_NULL
);
mutex_init
(
&
wimax_dev
->
mutex
);
mutex_init
(
&
wimax_dev
->
mutex_reset
);
}
...
...
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