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
018a60ac
Commit
018a60ac
authored
Mar 23, 2003
by
Hideaki Yoshifuji
Committed by
David S. Miller
Mar 23, 2003
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[IPSEC]: Make get_acqseq() xfrm_state.c:xfrm_get_acqseq().
parent
4759dd67
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
15 additions
and
15 deletions
+15
-15
include/net/xfrm.h
include/net/xfrm.h
+1
-0
net/ipv4/xfrm_state.c
net/ipv4/xfrm_state.c
+12
-1
net/ipv4/xfrm_user.c
net/ipv4/xfrm_user.c
+1
-14
net/netsyms.c
net/netsyms.c
+1
-0
No files found.
include/net/xfrm.h
View file @
018a60ac
...
@@ -744,6 +744,7 @@ int xfrm_policy_insert(int dir, struct xfrm_policy *policy, int excl);
...
@@ -744,6 +744,7 @@ int xfrm_policy_insert(int dir, struct xfrm_policy *policy, int excl);
struct
xfrm_policy
*
xfrm_policy_delete
(
int
dir
,
struct
xfrm_selector
*
sel
);
struct
xfrm_policy
*
xfrm_policy_delete
(
int
dir
,
struct
xfrm_selector
*
sel
);
struct
xfrm_policy
*
xfrm_policy_byid
(
int
dir
,
u32
id
,
int
delete
);
struct
xfrm_policy
*
xfrm_policy_byid
(
int
dir
,
u32
id
,
int
delete
);
void
xfrm_policy_flush
(
void
);
void
xfrm_policy_flush
(
void
);
u32
xfrm_get_acqseq
(
void
);
void
xfrm_alloc_spi
(
struct
xfrm_state
*
x
,
u32
minspi
,
u32
maxspi
);
void
xfrm_alloc_spi
(
struct
xfrm_state
*
x
,
u32
minspi
,
u32
maxspi
);
struct
xfrm_state
*
xfrm_find_acq
(
u8
mode
,
u16
reqid
,
u8
proto
,
struct
xfrm_state
*
xfrm_find_acq
(
u8
mode
,
u16
reqid
,
u8
proto
,
xfrm_address_t
*
daddr
,
xfrm_address_t
*
saddr
,
xfrm_address_t
*
daddr
,
xfrm_address_t
*
saddr
,
...
...
net/ipv4/xfrm_state.c
View file @
018a60ac
...
@@ -428,7 +428,18 @@ struct xfrm_state * xfrm_find_acq_byseq(u32 seq)
...
@@ -428,7 +428,18 @@ struct xfrm_state * xfrm_find_acq_byseq(u32 seq)
spin_unlock_bh
(
&
xfrm_state_lock
);
spin_unlock_bh
(
&
xfrm_state_lock
);
return
NULL
;
return
NULL
;
}
}
u32
xfrm_get_acqseq
(
void
)
{
u32
res
;
static
u32
acqseq
;
static
spinlock_t
acqseq_lock
=
SPIN_LOCK_UNLOCKED
;
spin_lock_bh
(
&
acqseq_lock
);
res
=
(
++
acqseq
?
:
++
acqseq
);
spin_unlock_bh
(
&
acqseq_lock
);
return
res
;
}
void
void
xfrm_alloc_spi
(
struct
xfrm_state
*
x
,
u32
minspi
,
u32
maxspi
)
xfrm_alloc_spi
(
struct
xfrm_state
*
x
,
u32
minspi
,
u32
maxspi
)
...
...
net/ipv4/xfrm_user.c
View file @
018a60ac
...
@@ -949,19 +949,6 @@ static int xfrm_send_notify(struct xfrm_state *x, int hard)
...
@@ -949,19 +949,6 @@ static int xfrm_send_notify(struct xfrm_state *x, int hard)
return
netlink_broadcast
(
xfrm_nl
,
skb
,
0
,
XFRMGRP_EXPIRE
,
GFP_ATOMIC
);
return
netlink_broadcast
(
xfrm_nl
,
skb
,
0
,
XFRMGRP_EXPIRE
,
GFP_ATOMIC
);
}
}
/* XXX Make this xfrm_state.c:xfrm_get_acqseq() */
static
u32
get_acqseq
(
void
)
{
u32
res
;
static
u32
acqseq
;
static
spinlock_t
acqseq_lock
=
SPIN_LOCK_UNLOCKED
;
spin_lock_bh
(
&
acqseq_lock
);
res
=
(
++
acqseq
?
:
++
acqseq
);
spin_unlock_bh
(
&
acqseq_lock
);
return
res
;
}
static
int
build_acquire
(
struct
sk_buff
*
skb
,
struct
xfrm_state
*
x
,
static
int
build_acquire
(
struct
sk_buff
*
skb
,
struct
xfrm_state
*
x
,
struct
xfrm_tmpl
*
xt
,
struct
xfrm_policy
*
xp
,
struct
xfrm_tmpl
*
xt
,
struct
xfrm_policy
*
xp
,
int
dir
)
int
dir
)
...
@@ -969,7 +956,7 @@ static int build_acquire(struct sk_buff *skb, struct xfrm_state *x,
...
@@ -969,7 +956,7 @@ static int build_acquire(struct sk_buff *skb, struct xfrm_state *x,
struct
xfrm_user_acquire
*
ua
;
struct
xfrm_user_acquire
*
ua
;
struct
nlmsghdr
*
nlh
;
struct
nlmsghdr
*
nlh
;
unsigned
char
*
b
=
skb
->
tail
;
unsigned
char
*
b
=
skb
->
tail
;
__u32
seq
=
get_acqseq
();
__u32
seq
=
xfrm_
get_acqseq
();
nlh
=
NLMSG_PUT
(
skb
,
0
,
0
,
XFRM_MSG_ACQUIRE
,
nlh
=
NLMSG_PUT
(
skb
,
0
,
0
,
XFRM_MSG_ACQUIRE
,
sizeof
(
*
ua
));
sizeof
(
*
ua
));
...
...
net/netsyms.c
View file @
018a60ac
...
@@ -316,6 +316,7 @@ EXPORT_SYMBOL(xfrm_replay_check);
...
@@ -316,6 +316,7 @@ EXPORT_SYMBOL(xfrm_replay_check);
EXPORT_SYMBOL
(
xfrm_replay_advance
);
EXPORT_SYMBOL
(
xfrm_replay_advance
);
EXPORT_SYMBOL
(
xfrm_check_selectors
);
EXPORT_SYMBOL
(
xfrm_check_selectors
);
EXPORT_SYMBOL
(
__secpath_destroy
);
EXPORT_SYMBOL
(
__secpath_destroy
);
EXPORT_SYMBOL
(
xfrm_get_acqseq
);
EXPORT_SYMBOL
(
xfrm_parse_spi
);
EXPORT_SYMBOL
(
xfrm_parse_spi
);
EXPORT_SYMBOL
(
xfrm4_rcv
);
EXPORT_SYMBOL
(
xfrm4_rcv
);
EXPORT_SYMBOL
(
xfrm_register_type
);
EXPORT_SYMBOL
(
xfrm_register_type
);
...
...
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