• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /netgear-R7000-V1.0.7.12_1.2.5/components/opensource/linux/linux-2.6.36/net/rose/

Lines Matching defs:sk

40 static int rose_state1_machine(struct sock *sk, struct sk_buff *skb, int frametype)
42 struct rose_sock *rose = rose_sk(sk);
46 rose_stop_timer(sk);
47 rose_start_idletimer(sk);
54 sk->sk_state = TCP_ESTABLISHED;
55 if (!sock_flag(sk, SOCK_DEAD))
56 sk->sk_state_change(sk);
60 rose_write_internal(sk, ROSE_CLEAR_CONFIRMATION);
61 rose_disconnect(sk, ECONNREFUSED, skb->data[3], skb->data[4]);
77 static int rose_state2_machine(struct sock *sk, struct sk_buff *skb, int frametype)
79 struct rose_sock *rose = rose_sk(sk);
83 rose_write_internal(sk, ROSE_CLEAR_CONFIRMATION);
84 rose_disconnect(sk, 0, skb->data[3], skb->data[4]);
89 rose_disconnect(sk, 0, -1, -1);
105 static int rose_state3_machine(struct sock *sk, struct sk_buff *skb, int frametype, int ns, int nr, int q, int d, int m)
107 struct rose_sock *rose = rose_sk(sk);
112 rose_stop_timer(sk);
113 rose_start_idletimer(sk);
114 rose_write_internal(sk, ROSE_RESET_CONFIRMATION);
120 rose_requeue_frames(sk);
124 rose_write_internal(sk, ROSE_CLEAR_CONFIRMATION);
125 rose_disconnect(sk, 0, skb->data[3], skb->data[4]);
131 if (!rose_validate_nr(sk, nr)) {
132 rose_write_internal(sk, ROSE_RESET_REQUEST);
139 rose_start_t2timer(sk);
140 rose_stop_idletimer(sk);
142 rose_frames_acked(sk, nr);
153 if (!rose_validate_nr(sk, nr)) {
154 rose_write_internal(sk, ROSE_RESET_REQUEST);
161 rose_start_t2timer(sk);
162 rose_stop_idletimer(sk);
165 rose_frames_acked(sk, nr);
167 rose_start_idletimer(sk);
168 if (sock_queue_rcv_skb(sk, skb) == 0) {
173 rose_write_internal(sk, ROSE_RESET_REQUEST);
180 rose_start_t2timer(sk);
181 rose_stop_idletimer(sk);
184 if (atomic_read(&sk->sk_rmem_alloc) >
185 (sk->sk_rcvbuf >> 1))
194 rose_stop_timer(sk);
195 rose_enquiry_response(sk);
198 rose_start_hbtimer(sk);
215 static int rose_state4_machine(struct sock *sk, struct sk_buff *skb, int frametype)
217 struct rose_sock *rose = rose_sk(sk);
221 rose_write_internal(sk, ROSE_RESET_CONFIRMATION);
223 rose_stop_timer(sk);
224 rose_start_idletimer(sk);
231 rose_requeue_frames(sk);
235 rose_write_internal(sk, ROSE_CLEAR_CONFIRMATION);
236 rose_disconnect(sk, 0, skb->data[3], skb->data[4]);
252 static int rose_state5_machine(struct sock *sk, struct sk_buff *skb, int frametype)
255 rose_write_internal(sk, ROSE_CLEAR_CONFIRMATION);
256 rose_disconnect(sk, 0, skb->data[3], skb->data[4]);
257 rose_sk(sk)->neighbour->use--;
264 int rose_process_rx_frame(struct sock *sk, struct sk_buff *skb)
266 struct rose_sock *rose = rose_sk(sk);
276 queued = rose_state1_machine(sk, skb, frametype);
279 queued = rose_state2_machine(sk, skb, frametype);
282 queued = rose_state3_machine(sk, skb, frametype, ns, nr, q, d, m);
285 queued = rose_state4_machine(sk, skb, frametype);
288 queued = rose_state5_machine(sk, skb, frametype);
292 rose_kick(sk);