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
d4fd3bc1
Commit
d4fd3bc1
authored
Jun 09, 2009
by
David S. Miller
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
xfrm: Use frag list abstraction interfaces.
Signed-off-by:
David S. Miller
<
davem@davemloft.net
>
parent
1b003be3
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
19 additions
and
22 deletions
+19
-22
net/xfrm/xfrm_algo.c
net/xfrm/xfrm_algo.c
+19
-22
No files found.
net/xfrm/xfrm_algo.c
View file @
d4fd3bc1
...
@@ -696,8 +696,9 @@ int skb_icv_walk(const struct sk_buff *skb, struct hash_desc *desc,
...
@@ -696,8 +696,9 @@ int skb_icv_walk(const struct sk_buff *skb, struct hash_desc *desc,
{
{
int
start
=
skb_headlen
(
skb
);
int
start
=
skb_headlen
(
skb
);
int
i
,
copy
=
start
-
offset
;
int
i
,
copy
=
start
-
offset
;
int
er
r
;
struct
sk_buff
*
frag_ite
r
;
struct
scatterlist
sg
;
struct
scatterlist
sg
;
int
err
;
/* Checksum header. */
/* Checksum header. */
if
(
copy
>
0
)
{
if
(
copy
>
0
)
{
...
@@ -742,28 +743,24 @@ int skb_icv_walk(const struct sk_buff *skb, struct hash_desc *desc,
...
@@ -742,28 +743,24 @@ int skb_icv_walk(const struct sk_buff *skb, struct hash_desc *desc,
start
=
end
;
start
=
end
;
}
}
if
(
skb_shinfo
(
skb
)
->
frag_list
)
{
skb_walk_frags
(
skb
,
frag_iter
)
{
struct
sk_buff
*
list
=
skb_shinfo
(
skb
)
->
frag_list
;
int
end
;
for
(;
list
;
list
=
list
->
next
)
{
WARN_ON
(
start
>
offset
+
len
);
int
end
;
end
=
start
+
frag_iter
->
len
;
WARN_ON
(
start
>
offset
+
len
);
if
((
copy
=
end
-
offset
)
>
0
)
{
if
(
copy
>
len
)
end
=
start
+
list
->
len
;
copy
=
len
;
if
((
copy
=
end
-
offset
)
>
0
)
{
err
=
skb_icv_walk
(
frag_iter
,
desc
,
offset
-
start
,
if
(
copy
>
len
)
copy
,
icv_update
);
copy
=
len
;
if
(
unlikely
(
err
))
err
=
skb_icv_walk
(
list
,
desc
,
offset
-
start
,
return
err
;
copy
,
icv_update
);
if
((
len
-=
copy
)
==
0
)
if
(
unlikely
(
err
))
return
0
;
return
err
;
offset
+=
copy
;
if
((
len
-=
copy
)
==
0
)
return
0
;
offset
+=
copy
;
}
start
=
end
;
}
}
start
=
end
;
}
}
BUG_ON
(
len
);
BUG_ON
(
len
);
return
0
;
return
0
;
...
...
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