mirror of
https://git.FreeBSD.org/src.git
synced 2024-11-25 07:49:18 +00:00
inpcb: provide pcbinfo pointer argument to inp_apply_all()
Allows to clear inpcb layer of TCP knowledge.
This commit is contained in:
parent
b6a816f116
commit
24cf7a8d62
@ -2694,9 +2694,10 @@ inp_unlock_assert(struct inpcb *inp)
|
||||
#endif
|
||||
|
||||
void
|
||||
inp_apply_all(void (*func)(struct inpcb *, void *), void *arg)
|
||||
inp_apply_all(struct inpcbinfo *pcbinfo,
|
||||
void (*func)(struct inpcb *, void *), void *arg)
|
||||
{
|
||||
struct inpcb_iterator inpi = INP_ALL_ITERATOR(&V_tcbinfo,
|
||||
struct inpcb_iterator inpi = INP_ALL_ITERATOR(pcbinfo,
|
||||
INPLOOKUP_WLOCKPCB);
|
||||
struct inpcb *inp;
|
||||
|
||||
|
@ -546,7 +546,8 @@ void inp_unlock_assert(struct inpcb *);
|
||||
#define inp_unlock_assert(inp) do {} while (0)
|
||||
#endif
|
||||
|
||||
void inp_apply_all(void (*func)(struct inpcb *, void *), void *arg);
|
||||
void inp_apply_all(struct inpcbinfo *, void (*func)(struct inpcb *, void *),
|
||||
void *arg);
|
||||
int inp_ip_tos_get(const struct inpcb *inp);
|
||||
void inp_ip_tos_set(struct inpcb *inp, int val);
|
||||
struct socket *
|
||||
|
@ -322,7 +322,7 @@ register_toedev(struct toedev *tod)
|
||||
registered_toedevs++;
|
||||
mtx_unlock(&toedev_lock);
|
||||
|
||||
inp_apply_all(toe_listen_start, tod);
|
||||
inp_apply_all(&V_tcbinfo, toe_listen_start, tod);
|
||||
|
||||
return (0);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user