ddp.c (97a4649d6ffce4a5d7f5ce018d87a6cefcb4ad03) | ddp.c (b24b8a247ff65c01b252025926fe564209fae4fc) |
---|---|
1/* 2 * DDP: An implementation of the AppleTalk DDP protocol for 3 * Ethernet 'ELAP'. 4 * 5 * Alan Cox <Alan.Cox@linux.org> 6 * 7 * With more than a little assistance from 8 * --- 163 unchanged lines hidden (view full) --- 172 173static inline void atalk_destroy_socket(struct sock *sk) 174{ 175 atalk_remove_socket(sk); 176 skb_queue_purge(&sk->sk_receive_queue); 177 178 if (atomic_read(&sk->sk_wmem_alloc) || 179 atomic_read(&sk->sk_rmem_alloc)) { | 1/* 2 * DDP: An implementation of the AppleTalk DDP protocol for 3 * Ethernet 'ELAP'. 4 * 5 * Alan Cox <Alan.Cox@linux.org> 6 * 7 * With more than a little assistance from 8 * --- 163 unchanged lines hidden (view full) --- 172 173static inline void atalk_destroy_socket(struct sock *sk) 174{ 175 atalk_remove_socket(sk); 176 skb_queue_purge(&sk->sk_receive_queue); 177 178 if (atomic_read(&sk->sk_wmem_alloc) || 179 atomic_read(&sk->sk_rmem_alloc)) { |
180 init_timer(&sk->sk_timer); | 180 setup_timer(&sk->sk_timer, atalk_destroy_timer, 181 (unsigned long)sk); |
181 sk->sk_timer.expires = jiffies + SOCK_DESTROY_TIME; | 182 sk->sk_timer.expires = jiffies + SOCK_DESTROY_TIME; |
182 sk->sk_timer.function = atalk_destroy_timer; 183 sk->sk_timer.data = (unsigned long)sk; | |
184 add_timer(&sk->sk_timer); 185 } else 186 sock_put(sk); 187} 188 189/**************************************************************************\ 190* * 191* Routing tables for the AppleTalk socket layer. * --- 1749 unchanged lines hidden --- | 183 add_timer(&sk->sk_timer); 184 } else 185 sock_put(sk); 186} 187 188/**************************************************************************\ 189* * 190* Routing tables for the AppleTalk socket layer. * --- 1749 unchanged lines hidden --- |