taglinefilesource code
sk117drivers/net/de600.cstatic unsigned long de600_rspace(struct sock *sk);
sk483drivers/net/de600.cif (skb->sk && (skb->sk->protocol == IPPROTO_TCP) &&
sk484drivers/net/de600.c(skb->sk->prot->rspace != &de600_rspace))
sk485drivers/net/de600.cskb->sk->prot->rspace = de600_rspace; /* Ugh! */
sk814drivers/net/de600.cde600_rspace(struct sock *sk)
sk818drivers/net/de600.cif (sk != NULL) {
sk825drivers/net/de600.cif (sk->rmem_alloc >= sk->rcvbuf-2*DE600_MIN_WINDOW) return(0);
sk826drivers/net/de600.camt = min((sk->rcvbuf-sk->rmem_alloc)/2/*-DE600_MIN_WINDOW*/, DE600_MAX_WINDOW);
sk85drivers/net/loopback.celse if(skb->sk)
sk93drivers/net/loopback.cskb->sk->wmem_alloc-=skb->truesize;
sk94drivers/net/loopback.cskb->sk->write_space(skb->sk);
sk34fs/smbfs/sock.csmb_data_callback(struct sock *sk,int len)
sk36fs/smbfs/sock.cstruct socket *sock = sk->socket;
sk38fs/smbfs/sock.cif(!sk->dead)
sk71fs/smbfs/sock.cwake_up_interruptible(sk->sleep);
sk82fs/smbfs/sock.cstruct sock   *sk;
sk102fs/smbfs/sock.csk   = (struct sock *)(sock->data);
sk104fs/smbfs/sock.cif (sk == NULL) {
sk111fs/smbfs/sock.c(unsigned int)(sk->data_ready),
sk114fs/smbfs/sock.cif (sk->data_ready == smb_data_callback) {
sk119fs/smbfs/sock.cserver->data_ready = sk->data_ready;
sk120fs/smbfs/sock.csk->data_ready = smb_data_callback;
sk130fs/smbfs/sock.cstruct sock   *sk;
sk149fs/smbfs/sock.csk   = (struct sock *)(sock->data);
sk151fs/smbfs/sock.cif (sk == NULL) {
sk162fs/smbfs/sock.cif (sk->data_ready != smb_data_callback) {
sk169fs/smbfs/sock.c(unsigned int)(sk->data_ready),
sk172fs/smbfs/sock.csk->data_ready = server->data_ready;
sk37include/linux/etherdevice.hextern void     eth_header_cache(struct device *dev, struct sock *sk, unsigned long saddr, unsigned long daddr);
sk90include/linux/igmp.hextern int ip_mc_join_group(struct sock *sk, struct device *dev, unsigned long addr);
sk91include/linux/igmp.hextern int ip_mc_leave_group(struct sock *sk, struct device *dev,unsigned long addr);
sk92include/linux/igmp.hextern void ip_mc_drop_socket(struct sock *sk);
sk122include/linux/mroute.hextern int ipmr_ioctl(struct sock *sk, int cmd, unsigned long arg);
sk123include/linux/mroute.hextern void mroute_close(struct sock *sk);
sk168include/linux/netdevice.hvoid        (*header_cache)(struct device *dev, struct sock *sk, unsigned long saddr, unsigned long daddr);
sk47include/linux/skbuff.hstruct sock      *sk;      /* Socket we are owned by       */
sk364include/linux/skbuff.hextern struct sk_buff *    skb_recv_datagram(struct sock *sk,unsigned flags,int noblock, int *err);
sk365include/linux/skbuff.hextern int      datagram_select(struct sock *sk, int sel_type, select_table *wait);
sk159include/net/ax25.hstruct sock    *sk;    /* Backlink to socket */
sk32include/net/icmp.hextern int  icmp_ioctl(struct sock *sk, int cmd,
sk85include/net/ip.hextern int    ip_ioctl(struct sock *sk, int cmd, unsigned long arg);
sk102include/net/ip.hextern void    ip_queue_xmit(struct sock *sk,
sk106include/net/ip.hextern int    ip_build_xmit(struct sock *sk,
sk128include/net/ip.hvoid ip_fragment(struct sock *sk, struct sk_buff *skb, struct device *dev, int is_frag);
sk149include/net/ip.hextern int     ip_setsockopt(struct sock *sk, int level, int optname, char *optval, int optlen);
sk150include/net/ip.hextern int     ip_getsockopt(struct sock *sk, int level, int optname, char *optval, int *optlen);
sk63include/net/netrom.hstruct sock    *sk;    /* Backlink to socket */
sk26include/net/raw.hextern int  raw_recvfrom(struct sock *sk, unsigned char *to,
sk29include/net/raw.hextern int  raw_read(struct sock *sk, unsigned char *buff,
sk253include/net/sock.hvoid      (*state_change)(struct sock *sk);
sk254include/net/sock.hvoid      (*data_ready)(struct sock *sk,int bytes);
sk255include/net/sock.hvoid      (*write_space)(struct sock *sk);
sk256include/net/sock.hvoid      (*error_report)(struct sock *sk);
sk266include/net/sock.hvoid      (*close)(struct sock *sk, int timeout);
sk267include/net/sock.hint      (*read)(struct sock *sk, unsigned char *to,
sk269include/net/sock.hint      (*write)(struct sock *sk, const unsigned char *to,
sk271include/net/sock.hint      (*sendto)(struct sock *sk,
sk275include/net/sock.hint      (*recvfrom)(struct sock *sk,
sk285include/net/sock.hint      (*connect)(struct sock *sk,
sk287include/net/sock.hstruct sock *    (*accept) (struct sock *sk, int flags);
sk288include/net/sock.hvoid      (*queue_xmit)(struct sock *sk,
sk291include/net/sock.hvoid      (*retransmit)(struct sock *sk, int all);
sk292include/net/sock.hvoid      (*write_wakeup)(struct sock *sk);
sk293include/net/sock.hvoid      (*read_wakeup)(struct sock *sk);
sk298include/net/sock.hint      (*select)(struct sock *sk, int which,
sk300include/net/sock.hint      (*ioctl)(struct sock *sk, int cmd,
sk302include/net/sock.hint      (*init)(struct sock *sk);
sk303include/net/sock.hvoid      (*shutdown)(struct sock *sk, int how);
sk304include/net/sock.hint      (*setsockopt)(struct sock *sk, int level, int optname,
sk306include/net/sock.hint      (*getsockopt)(struct sock *sk, int level, int optname,
sk308include/net/sock.hint      (*sendmsg)(struct sock *sk, struct msghdr *msg, int len,
sk310include/net/sock.hint      (*recvmsg)(struct sock *sk, struct msghdr *msg, int len,
sk343include/net/sock.hextern void      destroy_sock(struct sock *sk);
sk347include/net/sock.hextern void      release_sock(struct sock *sk);
sk357include/net/sock.hextern struct sk_buff    *sock_wmalloc(struct sock *sk,
sk360include/net/sock.hextern struct sk_buff    *sock_rmalloc(struct sock *sk,
sk363include/net/sock.hextern void      sock_wfree(struct sock *sk,
sk365include/net/sock.hextern void      sock_rfree(struct sock *sk,
sk367include/net/sock.hextern unsigned long    sock_rspace(struct sock *sk);
sk368include/net/sock.hextern unsigned long    sock_wspace(struct sock *sk);
sk370include/net/sock.hextern int      sock_setsockopt(struct sock *sk, int level,
sk374include/net/sock.hextern int      sock_getsockopt(struct sock *sk, int level,
sk392include/net/sock.hextern __inline__ int sock_queue_rcv_skb(struct sock *sk, struct sk_buff *skb)
sk395include/net/sock.hif(sk->rmem_alloc + skb->truesize >= sk->rcvbuf)
sk399include/net/sock.hsk->rmem_alloc+=skb->truesize;
sk400include/net/sock.hskb->sk=sk;
sk402include/net/sock.hskb_queue_tail(&sk->receive_queue,skb);
sk403include/net/sock.hif(!sk->dead)
sk404include/net/sock.hsk->data_ready(sk,skb->len);
sk128include/net/tcp.hextern void  tcp_shutdown (struct sock *sk, int how);
sk134include/net/tcp.hextern int  tcp_ioctl(struct sock *sk, int cmd, unsigned long arg);
sk136include/net/tcp.hextern int tcp_select_window(struct sock *sk);
sk138include/net/tcp.hunsigned long daddr, int len, struct sock *sk);
sk139include/net/tcp.hextern void tcp_send_probe0(struct sock *sk);
sk37include/net/udp.h__u32 daddr, int len, struct sock *sk);
sk38include/net/udp.hextern int  udp_recvfrom(struct sock *sk, unsigned char *to,
sk41include/net/udp.hextern int  udp_read(struct sock *sk, unsigned char *buff,
sk43include/net/udp.hextern int  udp_connect(struct sock *sk,
sk49include/net/udp.hextern int  udp_ioctl(struct sock *sk, int cmd, unsigned long arg);
sk6net/802/llc.cint llc_rx_adm(struct sock *sk,struct sk_buff *skb, int type, int cmd, int pf, int nr, int ns)
sk11net/802/llc.csend_response(sk,DM|pf);
sk14net/802/llc.cif(sk->state!=TCP_LISTEN)
sk15net/802/llc.csend_response(sk. DM|pf);
sk18net/802/llc.csk=ll_rx_accept(sk);
sk19net/802/llc.cif(sk!=NULL)
sk21net/802/llc.csend_response(sk, UA|pf);
sk22net/802/llc.csk->llc.vs=0;
sk23net/802/llc.csk->llc.vr=0;
sk24net/802/llc.csk->llc.p_flag=0;
sk25net/802/llc.csk->llc.remote_busy=0;
sk26net/802/llc.cllc_state(sk,LLC_NORMAL);
sk31net/802/llc.csend_response(sk, DM|PF);
sk36net/802/llc.cint llc_rx_setup(struct sock *sk, struct sk_buff *skb, int type, int cmd, int pf, int nr, int ns)
sk42net/802/llc.csk->llc.vs=0;
sk43net/802/llc.csk->llc.vr=0;
sk44net/802/llc.csend_response(sk, UA|pf);
sk48net/802/llc.csend_response(sk, DM|pf);
sk49net/802/llc.cllc_error(sk,ECONNRESET);
sk50net/802/llc.cllc_state(sk, LLC_ADM);
sk55net/802/llc.cif(cmd==UA && pf==sk->llc.p_flag)
sk57net/802/llc.cdel_timer(&sk->llc.t1);
sk58net/802/llc.csk->llc.vs=0;
sk59net/802/llc.cllc_update_p_flag(sk,pf);
sk60net/802/llc.cllc_state(sk,LLC_NORMAL);
sk64net/802/llc.cllc_error(sk, ECONNRESET);
sk65net/802/llc.cllc_state(sk, LLC_ADM);
sk70net/802/llc.cint llc_rx_reset(struct sock *sk, struct sk_buff *skb, int type, int cmd, int pf, int nr, int ns)
sk76net/802/llc.csk->llc.vr=0;
sk77net/802/llc.csk->llc.vs=0;
sk78net/802/llc.csend_response(sk, UA|pf);
sk82net/802/llc.cif(sk->llc.cause_flag==1)
sk83net/802/llc.cllc_shutdown(sk,SHUTDOWN_MASK);
sk85net/802/llc.cllc_eror(sk, ECONNREFUSED);
sk86net/802/llc.csend_response(sk, DM|pf);
sk87net/802/llc.cllc_state(sk, LLC_ADM);
sk94net/802/llc.cif(sk->llc.p_flag==pf)
sk96net/802/llc.cdel_timer(&sk->llc.t1);
sk97net/802/llc.csk->llc.vs=0;
sk98net/802/llc.csk->llc.vr=0;
sk99net/802/llc.cllc_update_p_flag(sk,pf);
sk100net/802/llc.cllc_confirm_reset(sk, sk->llc.cause_flag);
sk101net/802/llc.csk->llc.remote_busy=0;
sk102net/802/llc.cllc_state(sk, LLC_NORMAL);
sk107net/802/llc.cllc_shutdown(sk, SHUTDOWN_MASK);
sk108net/802/llc.cllc_state(sk, LLC_ADM);
sk114net/802/llc.cint llc_rx_d_conn(struct sock *sk, struct sk_buff *skb, int type, int cmd, int pf, int nr, int ns)
sk120net/802/llc.cllc_error(sk, ECONNRESET);
sk121net/802/llc.cllc_state(sk, ADM);
sk126net/802/llc.cllc_state(sk, LLC_D_CONN);
sk129net/802/llc.csend_response(sk, DM|PF);
sk133net/802/llc.cif(cmd==UA && pf==sk->llc.p_flag)
sk135net/802/llc.cdel_timer(&sk->llc.t1);
sk136net/802/llc.cllc_state(sk, ADM);
sk137net/802/llc.cllc_confirm_reset(sk, sk->llc.cause_flag);
sk141net/802/llc.cdel_timer(&sk->llc.t1);
sk143net/802/llc.cllc_shutdown(sk, SHUTDOWN_MASK);  
sk150net/802/llc.cint llc_rx_error(struct sock *sk, struct sk_buff *skb, int type, int cmd, int pf, int nr, int ns)
sk156net/802/llc.csk->llc.vs=0;
sk157net/802/llc.csk->llc.vr=0;
sk158net/802/llc.csend_response(sk, UA|pf);
sk159net/802/llc.cllc_error(sk,ECONNRESET);
sk160net/802/llc.csk->llc.p_flag=0;
sk161net/802/llc.csk->llc.remote_busy=0;
sk162net/802/llc.cllc_state(sk, LLC_NORMAL);
sk166net/802/llc.csend_response(sk, UA|pf);
sk167net/802/llc.cllc_shutdown(sk, SHUTDOWN_MASK);
sk168net/802/llc.cllc_state(sk, LLC_ADM);
sk171net/802/llc.cllc_resend_frmr_rsp(sk,pf);
sk177net/802/llc.cllc_error(sk, ECONNRESET);
sk178net/802/llc.cdel_timer(&sk->llc.t1);
sk179net/802/llc.cllc_state(sk, LLC_ADM);
sk183net/802/llc.csend_command(sk, SABM);
sk184net/802/llc.csk->llc.p_flag=pf;
sk186net/802/llc.csk->llc.retry_count=0;
sk187net/802/llc.csk->llc.cause_flag=0;
sk188net/802/llc.cllc_error(sk, EPROTO);
sk189net/802/llc.cllc_state(sk, LLC_RESET);
sk199net/802/llc.cint llc_rx_nr_shared(struct sock *sk, struct sk_buff *skb, int type, int cmd, int pf, int nr, int ns)
sk208net/802/llc.csend_response(sk,DM|pf);
sk209net/802/llc.cllc_error(sk, ECONNRESET);
sk210net/802/llc.cllc_state(sk, LLC_ADM);
sk214net/802/llc.csend_response(sk,UA|pf);
sk215net/802/llc.cllc_state(sk, LLC_ADM);
sk216net/802/llc.cllc_shutdown(sk, SHUTDOWN_MASK);
sk224net/802/llc.cllc_send_frmr_response(sk, ILLEGAL_TYPE,pf);
sk225net/802/llc.cllc_state(sk, LLC_ERROR);
sk226net/802/llc.cllc_error(sk, EPROTO);
sk241net/802/llc.csend_command(sk, DM|pf);
sk242net/802/llc.csk->llc.p_flag=pf;
sk243net/802/llc.cllc_start_t1(sk);
sk244net/802/llc.cllc_error(sk, EPROTO);
sk245net/802/llc.csk->llc.cause_flag=0;
sk246net/802/llc.cllc_state(sk, LLC_D_CONN):
sk250net/802/llc.cllc_state(sk, LLC_ADM);
sk251net/802/llc.cllc_error(sk, ECONNREFUSED);
sk260net/802/llc.cllc_send_frmr_response(sk, UNEXPECTED_CONTROL, pf);
sk261net/802/llc.cllc_state(sk, LLC_ERROR);
sk262net/802/llc.cllc_error(sk, EPROTO);
sk264net/802/llc.celse if(pf==1 && sk->llc.p_flag==0)
sk266net/802/llc.cllc_send_frmr_response(sk, UNEXPECTED_RESPONSE, pf);
sk267net/802/llc.cllc_state(sk, LLC_ERROR);
sk268net/802/llc.cllc_error(sk, EPROTO);
sk272net/802/llc.cllc_send_frmr_response(sk, ILLEGAL_TYPE,pf);
sk273net/802/llc.cllc_state(sk, LLC_ERROR);
sk274net/802/llc.cllc_error(sk, EPROTO);
sk288net/802/llc.cint llc_rx_normal(struct sock *sk, struct sk_buff *skb, int type, int cmd, int pf, int nr, int ns)
sk290net/802/llc.cif(llc_rx_nr_shared(sk, skb, type, cmd, pf, nr, ns))
sk294net/802/llc.cif(llc_invalid_ns(sk,ns))
sk296net/802/llc.cif((type==RESP && sk->llc.p_flag==pf)||(type==CMD && pf==0 && sk->llc.p_flag==0))
sk298net/802/llc.cllc_command(sk, REJ|PF);
sk299net/802/llc.cllc_ack_frames(sk,nr);  /* Ack frames and update N(R) */
sk300net/802/llc.csk->llc.p_flag=PF;
sk301net/802/llc.cllc_state(sk, LLC_REJECT);
sk302net/802/llc.csk->llc.retry_count=0;
sk303net/802/llc.cllc_start_t1(sk);
sk304net/802/llc.csk->llc.remote_busy=0;
sk306net/802/llc.celse if((type==CMD && !pf && sk->llc.p_flag==1) || (type==RESP && !pf && sk->llc.p_flag==1))
sk309net/802/llc.cllc_response(sk, REJ);
sk311net/802/llc.cllc_command(sk, REJ);
sk312net/802/llc.cllc_ack_frames(sk,nr);
sk313net/802/llc.csk->llc.retry_count=0;
sk314net/802/llc.cllc_state(sk, LLC_REJECT);
sk315net/802/llc.cllc_start_t1(sk);
sk319net/802/llc.cllc_response(sk, REJ|PF);
sk320net/802/llc.cllc_ack_frames(sk,nr);
sk321net/802/llc.csk->llc.retry_count=0;
sk322net/802/llc.cllc_start_t1(sk);
sk331net/802/llc.cif(sk->llc.p_flag==pf && !(type==CMD && pf))
sk333net/802/llc.csk->llc.vr=(sk->llc.vr+1)&7;
sk334net/802/llc.cllc_queue_rr_cmd(sk, PF);
sk335net/802/llc.csk->llc.retry_count=0;
sk336net/802/llc.cllc_start_t1(sk);
sk337net/802/llc.csk->llc.p_flag=1;
sk338net/802/llc.cllc_ack_frames(sk,nr);
sk339net/802/llc.csk->llc.remote_busy=0;
sk341net/802/llc.celse if(sk->ppc.p_flag!=pf)
sk343net/802/llc.csk->llc.vr=(sk->llc.vr+1)&7;
sk345net/802/llc.cllc_queue_rr_resp(sk, 0);
sk347net/802/llc.cllc_queue_rr_cmd(sk, 0);
sk348net/802/llc.cif(sk->llc.nr!=nr)
sk350net/802/llc.cllc_ack_frames(sk,nr);
sk351net/802/llc.cllc_reset_t1(sk);
sk356net/802/llc.csk->llc.vr=(sk->llc.vr+1)&7;
sk357net/802/llc.cllc_queue_rr_resp(sk,PF);
sk358net/802/llc.cif(sk->llc.nr!=nr)
sk360net/802/llc.cllc_ack_frames(sk,nr);
sk361net/802/llc.cllc_reset_t1(sk);
sk364net/802/llc.cllc_queue_data(sk,skb);
sk370net/802/llc.cif(type==CMD || (type==RESP && (!pf || pf==1 && sk->llc.p_flag==1)))
sk372net/802/llc.cllc_update_p_flag(sk,pf);
sk373net/802/llc.cif(sk->llc.nr!=nr)
sk375net/802/llc.cllc_ack_frames(sk,nr);
sk376net/802/llc.cllc_reset_t1(sk);
sk379net/802/llc.csk->llc.remote_busy=0;
sk381net/802/llc.c{  sk->llc.remote_busy=1;
sk382net/802/llc.cif(!llc_t1_running(sk))
sk383net/802/llc.cllc_start_t1(sk);
sk389net/802/llc.cllc_queue_rr_resp(sk,PF);
sk392net/802/llc.csend_response(sk, RR|PF);
sk393net/802/llc.cif(!llc_t1_running(sk))
sk394net/802/llc.cllc_start_t1(sk);
sk396net/802/llc.cif(sk->llc.nr!=nr)
sk398net/802/llc.cllc_ack_frames(sk,nr);
sk399net/802/llc.cllc_reset_t1(sk);
sk402net/802/llc.csk->llc.remote_busy=0;
sk404net/802/llc.csk->llc.remote_busy=1;
sk41net/802/p8022.cskb->sk = NULL;
sk66net/802/psnap.cskb->sk = NULL;
sk456net/appletalk/aarp.cif(skb->sk==NULL)
sk459net/appletalk/aarp.cdev_queue_xmit(skb, skb->dev, skb->sk->priority);
sk472net/appletalk/aarp.cif(skb->sk==NULL)
sk475net/appletalk/aarp.cdev_queue_xmit(skb, skb->dev, skb->sk->priority);
sk580net/appletalk/aarp.cif(skb->sk==NULL)
sk583net/appletalk/aarp.cdev_queue_xmit(skb, skb->dev, skb->sk->priority);
sk91net/appletalk/ddp.cstatic void atalk_remove_socket(atalk_socket *sk)
sk100net/appletalk/ddp.cif(s==sk)
sk108net/appletalk/ddp.cif(s->next==sk)
sk110net/appletalk/ddp.cs->next=sk->next;
sk119net/appletalk/ddp.cstatic void atalk_insert_socket(atalk_socket *sk)
sk124net/appletalk/ddp.csk->next=atalk_socket_list;
sk125net/appletalk/ddp.catalk_socket_list=sk;
sk192net/appletalk/ddp.cstatic void atalk_destroy_socket(atalk_socket *sk);
sk203net/appletalk/ddp.cstatic void atalk_destroy_socket(atalk_socket *sk)
sk206net/appletalk/ddp.catalk_remove_socket(sk);
sk208net/appletalk/ddp.cwhile((skb=skb_dequeue(&sk->receive_queue))!=NULL)
sk213net/appletalk/ddp.cif(sk->wmem_alloc == 0 && sk->rmem_alloc == 0 && sk->dead)
sk214net/appletalk/ddp.ckfree_s(sk,sizeof(*sk));
sk220net/appletalk/ddp.cinit_timer(&sk->timer);
sk221net/appletalk/ddp.csk->timer.expires=jiffies+10*HZ;
sk222net/appletalk/ddp.csk->timer.function=atalk_destroy_timer;
sk223net/appletalk/ddp.csk->timer.data = (unsigned long)sk;
sk224net/appletalk/ddp.cadd_timer(&sk->timer);
sk968net/appletalk/ddp.catalk_socket *sk;
sk971net/appletalk/ddp.csk=(atalk_socket *)sock->data;
sk992net/appletalk/ddp.creturn sock_setsockopt(sk,level,optname,optval,optlen);
sk1007net/appletalk/ddp.catalk_socket *sk;
sk1011net/appletalk/ddp.csk=(atalk_socket *)sock->data;
sk1025net/appletalk/ddp.creturn sock_getsockopt(sk,level,optname,optval,optlen);
sk1052net/appletalk/ddp.cstatic void def_callback1(struct sock *sk)
sk1054net/appletalk/ddp.cif(!sk->dead)
sk1055net/appletalk/ddp.cwake_up_interruptible(sk->sleep);
sk1058net/appletalk/ddp.cstatic void def_callback2(struct sock *sk, int len)
sk1060net/appletalk/ddp.cif(!sk->dead)
sk1062net/appletalk/ddp.cwake_up_interruptible(sk->sleep);
sk1063net/appletalk/ddp.csock_wake_async(sk->socket,0);
sk1074net/appletalk/ddp.catalk_socket *sk;
sk1075net/appletalk/ddp.csk=(atalk_socket *)kmalloc(sizeof(*sk),GFP_KERNEL);
sk1076net/appletalk/ddp.cif(sk==NULL)
sk1087net/appletalk/ddp.ckfree_s((void *)sk,sizeof(*sk));
sk1090net/appletalk/ddp.csk->dead=0;
sk1091net/appletalk/ddp.csk->next=NULL;
sk1092net/appletalk/ddp.csk->broadcast=0;
sk1093net/appletalk/ddp.csk->no_check=0;    /* Checksums on by default */
sk1094net/appletalk/ddp.csk->allocation=GFP_KERNEL;
sk1095net/appletalk/ddp.csk->rcvbuf=SK_RMEM_MAX;
sk1096net/appletalk/ddp.csk->sndbuf=SK_WMEM_MAX;
sk1097net/appletalk/ddp.csk->pair=NULL;
sk1098net/appletalk/ddp.csk->wmem_alloc=0;
sk1099net/appletalk/ddp.csk->rmem_alloc=0;
sk1100net/appletalk/ddp.csk->inuse=0;
sk1101net/appletalk/ddp.csk->proc=0;
sk1102net/appletalk/ddp.csk->priority=1;
sk1103net/appletalk/ddp.csk->shutdown=0;
sk1104net/appletalk/ddp.csk->prot=NULL;  /* So we use default free mechanisms */
sk1105net/appletalk/ddp.csk->broadcast=0;
sk1106net/appletalk/ddp.csk->err=0;
sk1107net/appletalk/ddp.cskb_queue_head_init(&sk->receive_queue);
sk1108net/appletalk/ddp.cskb_queue_head_init(&sk->write_queue);
sk1109net/appletalk/ddp.csk->send_head=NULL;
sk1110net/appletalk/ddp.cskb_queue_head_init(&sk->back_log);
sk1111net/appletalk/ddp.csk->state=TCP_CLOSE;
sk1112net/appletalk/ddp.csk->socket=sock;
sk1113net/appletalk/ddp.csk->type=sock->type;
sk1114net/appletalk/ddp.csk->debug=0;
sk1116net/appletalk/ddp.csk->protinfo.af_at.src_net=0;
sk1117net/appletalk/ddp.csk->protinfo.af_at.src_node=0;
sk1118net/appletalk/ddp.csk->protinfo.af_at.src_port=0;
sk1120net/appletalk/ddp.csk->protinfo.af_at.dest_net=0;
sk1121net/appletalk/ddp.csk->protinfo.af_at.dest_node=0;
sk1122net/appletalk/ddp.csk->protinfo.af_at.dest_port=0;
sk1124net/appletalk/ddp.csk->mtu=DDP_MAXSZ;
sk1128net/appletalk/ddp.csock->data=(void *)sk;
sk1129net/appletalk/ddp.csk->sleep=sock->wait;
sk1132net/appletalk/ddp.csk->state_change=def_callback1;
sk1133net/appletalk/ddp.csk->data_ready=def_callback2;
sk1134net/appletalk/ddp.csk->write_space=def_callback1;
sk1135net/appletalk/ddp.csk->error_report=def_callback1;
sk1137net/appletalk/ddp.csk->zapped=1;
sk1156net/appletalk/ddp.catalk_socket *sk=(atalk_socket *)sock->data;
sk1157net/appletalk/ddp.cif(sk==NULL)
sk1159net/appletalk/ddp.cif(!sk->dead)
sk1160net/appletalk/ddp.csk->state_change(sk);
sk1161net/appletalk/ddp.csk->dead=1;
sk1163net/appletalk/ddp.catalk_destroy_socket(sk);
sk1182net/appletalk/ddp.cstatic int atalk_autobind(atalk_socket *sk)
sk1190net/appletalk/ddp.csk->protinfo.af_at.src_net = sat.sat_addr.s_net = ap->s_net;
sk1191net/appletalk/ddp.csk->protinfo.af_at.src_node = sat.sat_addr.s_node = ap->s_node;
sk1195net/appletalk/ddp.csk->protinfo.af_at.src_port=n;
sk1196net/appletalk/ddp.catalk_insert_socket(sk);
sk1197net/appletalk/ddp.csk->zapped=0;
sk1207net/appletalk/ddp.catalk_socket *sk;
sk1210net/appletalk/ddp.csk=(atalk_socket *)sock->data;
sk1212net/appletalk/ddp.cif(sk->zapped==0)
sk1226net/appletalk/ddp.csk->protinfo.af_at.src_net=addr->sat_addr.s_net=ap->s_net;
sk1227net/appletalk/ddp.csk->protinfo.af_at.src_node=addr->sat_addr.s_node=ap->s_node;
sk1233net/appletalk/ddp.csk->protinfo.af_at.src_net=addr->sat_addr.s_net;
sk1234net/appletalk/ddp.csk->protinfo.af_at.src_node=addr->sat_addr.s_node;
sk1242net/appletalk/ddp.csk->protinfo.af_at.src_port=addr->sat_port=n;
sk1245net/appletalk/ddp.csk->protinfo.af_at.src_port=addr->sat_port;
sk1250net/appletalk/ddp.catalk_insert_socket(sk);
sk1251net/appletalk/ddp.csk->zapped=0;
sk1262net/appletalk/ddp.catalk_socket *sk=(atalk_socket *)sock->data;
sk1265net/appletalk/ddp.csk->state = TCP_CLOSE;  
sk1275net/appletalk/ddp.cif(addr->sat_addr.s_node==ATADDR_BCAST && !sk->broadcast)
sk1278net/appletalk/ddp.cif(sk->zapped)
sk1280net/appletalk/ddp.cif(atalk_autobind(sk)<0)
sk1287net/appletalk/ddp.csk->protinfo.af_at.dest_port=addr->sat_port;
sk1288net/appletalk/ddp.csk->protinfo.af_at.dest_net=addr->sat_addr.s_net;
sk1289net/appletalk/ddp.csk->protinfo.af_at.dest_node=addr->sat_addr.s_node;
sk1291net/appletalk/ddp.csk->state=TCP_ESTABLISHED;
sk1324net/appletalk/ddp.catalk_socket *sk;
sk1326net/appletalk/ddp.csk=(atalk_socket *)sock->data;
sk1327net/appletalk/ddp.cif(sk->zapped)
sk1329net/appletalk/ddp.cif(atalk_autobind(sk)<0)
sk1337net/appletalk/ddp.cif(sk->state!=TCP_ESTABLISHED)
sk1339net/appletalk/ddp.csat.sat_addr.s_net=sk->protinfo.af_at.dest_net;
sk1340net/appletalk/ddp.csat.sat_addr.s_node=sk->protinfo.af_at.dest_node;
sk1341net/appletalk/ddp.csat.sat_port=sk->protinfo.af_at.dest_port;
sk1345net/appletalk/ddp.csat.sat_addr.s_net=sk->protinfo.af_at.src_net;
sk1346net/appletalk/ddp.csat.sat_addr.s_node=sk->protinfo.af_at.src_node;
sk1347net/appletalk/ddp.csat.sat_port=sk->protinfo.af_at.src_port;
sk1502net/appletalk/ddp.cskb->sk = sock;
sk1506net/appletalk/ddp.cskb->sk=NULL;
sk1514net/appletalk/ddp.catalk_socket *sk=(atalk_socket *)sock->data;
sk1533net/appletalk/ddp.cif(sk->zapped)
sk1536net/appletalk/ddp.cif(atalk_autobind(sk)<0)
sk1545net/appletalk/ddp.cif(usat->sat_addr.s_node==ATADDR_BCAST && !sk->broadcast)
sk1551net/appletalk/ddp.cif(sk->state!=TCP_ESTABLISHED)
sk1555net/appletalk/ddp.cusat->sat_port=sk->protinfo.af_at.dest_port;
sk1556net/appletalk/ddp.cusat->sat_addr.s_node=sk->protinfo.af_at.dest_node;
sk1557net/appletalk/ddp.cusat->sat_addr.s_net=sk->protinfo.af_at.dest_net;
sk1562net/appletalk/ddp.cif(sk->debug)
sk1563net/appletalk/ddp.cprintk("SK %p: Got address.\n",sk);
sk1578net/appletalk/ddp.cat_hint.s_net=sk->protinfo.af_at.src_net;
sk1585net/appletalk/ddp.cif(sk->debug)
sk1586net/appletalk/ddp.cprintk("SK %p: Size needed %d, device %s\n", sk, size, dev->name);
sk1590net/appletalk/ddp.cskb = sock_alloc_send_skb(sk, size, 0, 0 , &err);
sk1594net/appletalk/ddp.cskb->sk=sk;
sk1602net/appletalk/ddp.cif(sk->debug)
sk1603net/appletalk/ddp.cprintk("SK %p: Begin build.\n", sk);
sk1617net/appletalk/ddp.cddp->deh_snet=sk->protinfo.af_at.src_net;
sk1619net/appletalk/ddp.cddp->deh_snode=sk->protinfo.af_at.src_node;
sk1621net/appletalk/ddp.cddp->deh_sport=sk->protinfo.af_at.src_port;
sk1623net/appletalk/ddp.cif(sk->debug)
sk1624net/appletalk/ddp.cprintk("SK %p: Copy user data (%d bytes).\n", sk, len);
sk1628net/appletalk/ddp.cif(sk->no_check==1)
sk1656net/appletalk/ddp.cif(sk->debug)
sk1657net/appletalk/ddp.cprintk("SK %p: send out(copy).\n", sk);
sk1667net/appletalk/ddp.cif(sk->debug)
sk1668net/appletalk/ddp.cprintk("SK %p: Loop back.\n", sk);
sk1670net/appletalk/ddp.csk->wmem_alloc-=skb->truesize;
sk1672net/appletalk/ddp.cskb->sk = NULL;
sk1681net/appletalk/ddp.cif(sk->debug)
sk1682net/appletalk/ddp.cprintk("SK %p: send out.\n", sk);
sk1693net/appletalk/ddp.cif(sk->debug)
sk1694net/appletalk/ddp.cprintk("SK %p: Done write (%d).\n", sk, len);
sk1722net/appletalk/ddp.catalk_socket *sk=(atalk_socket *)sock->data;
sk1729net/appletalk/ddp.cif(sk->err)
sk1731net/appletalk/ddp.cer= -sk->err;
sk1732net/appletalk/ddp.csk->err=0;
sk1739net/appletalk/ddp.cskb=skb_recv_datagram(sk,flags,noblock,&er);
sk1744net/appletalk/ddp.cif(sk->type==SOCK_RAW)
sk1796net/appletalk/ddp.catalk_socket *sk=(atalk_socket *)sock->data;
sk1797net/appletalk/ddp.cif(sk->zapped)
sk1808net/appletalk/ddp.cstatic int atalk_shutdown(struct socket *sk,int how)
sk1815net/appletalk/ddp.catalk_socket *sk=(atalk_socket *)sock->data;
sk1817net/appletalk/ddp.creturn datagram_select(sk,sel_type,wait);
sk1828net/appletalk/ddp.catalk_socket *sk=(atalk_socket *)sock->data;
sk1836net/appletalk/ddp.camount=sk->sndbuf-sk->wmem_alloc;
sk1844net/appletalk/ddp.cif((skb=skb_peek(&sk->receive_queue))!=NULL)
sk1849net/appletalk/ddp.cif (sk)
sk1851net/appletalk/ddp.cif(sk->stamp.tv_sec==0)
sk1856net/appletalk/ddp.cmemcpy_tofs((void *)arg,&sk->stamp,sizeof(struct timeval));
sk211net/ax25/af_ax25.cif (s->sk != NULL) {
sk212net/ax25/af_ax25.cs->sk->state = TCP_CLOSE;
sk213net/ax25/af_ax25.cs->sk->err   = ENETUNREACH;
sk214net/ax25/af_ax25.cif (!s->sk->dead)
sk215net/ax25/af_ax25.cs->sk->state_change(s->sk);
sk216net/ax25/af_ax25.cs->sk->dead  = 1;
sk274net/ax25/af_ax25.cif (s->sk != NULL && ax25cmp(&s->source_addr, addr) == 0 && s->sk->type == type && s->sk->state == TCP_LISTEN) {
sk278net/ax25/af_ax25.creturn s->sk;
sk299net/ax25/af_ax25.cif (s->sk != NULL && ax25cmp(&s->source_addr, my_addr) == 0 && ax25cmp(&s->dest_addr, dest_addr) == 0 && s->sk->type == type) {
sk301net/ax25/af_ax25.creturn s->sk;
sk323net/ax25/af_ax25.cif (s->sk != NULL && s->sk->type != SOCK_SEQPACKET)
sk348net/ax25/af_ax25.cif (s->sk != NULL && ax25cmp(&s->source_addr, addr) == 0 && s->sk->type == SOCK_RAW) {
sk350net/ax25/af_ax25.creturn s->sk;
sk359net/ax25/af_ax25.cstatic void ax25_send_to_raw(struct sock *sk, struct sk_buff *skb, int proto)
sk363net/ax25/af_ax25.cwhile (sk != NULL) {
sk364net/ax25/af_ax25.cif (sk->type == SOCK_RAW && sk->protocol == proto && sk->rmem_alloc <= sk->rcvbuf) {
sk368net/ax25/af_ax25.ccopy->sk = sk;
sk369net/ax25/af_ax25.csk->rmem_alloc += copy->truesize;
sk370net/ax25/af_ax25.cskb_queue_tail(&sk->receive_queue, copy);
sk371net/ax25/af_ax25.cif (!sk->dead)
sk372net/ax25/af_ax25.csk->data_ready(sk, skb->len);
sk375net/ax25/af_ax25.csk = sk->next;
sk411net/ax25/af_ax25.cif (ax25->sk != NULL) {
sk412net/ax25/af_ax25.cwhile ((skb = skb_dequeue(&ax25->sk->receive_queue)) != NULL) {
sk413net/ax25/af_ax25.cif (skb->sk != ax25->sk) {      /* A pending connection */
sk414net/ax25/af_ax25.cskb->sk->dead = 1;  /* Queue the unaccepted socket for death */
sk415net/ax25/af_ax25.cax25_set_timer(skb->sk->ax25);
sk416net/ax25/af_ax25.cskb->sk->ax25->state = AX25_STATE_0;
sk428net/ax25/af_ax25.cif (ax25->sk != NULL) {
sk429net/ax25/af_ax25.cif (ax25->sk->wmem_alloc || ax25->sk->rmem_alloc) { /* Defer: outstanding buffers */
sk436net/ax25/af_ax25.ckfree_s(ax25->sk, sizeof(*ax25->sk));
sk559net/ax25/af_ax25.cax25->sk       = NULL;
sk606net/ax25/af_ax25.cif (ax25->sk != NULL && ax25->sk->type != SOCK_SEQPACKET)
sk693net/ax25/af_ax25.cstruct sock *sk;
sk696net/ax25/af_ax25.csk = (struct sock *)sock->data;
sk699net/ax25/af_ax25.creturn sock_setsockopt(sk, level, optname, optval, optlen);
sk714net/ax25/af_ax25.cif (sk->ax25->modulus == MODULUS) {
sk721net/ax25/af_ax25.csk->ax25->window = opt;
sk727net/ax25/af_ax25.csk->ax25->rtt = (opt * PR_SLOWHZ) / 2;
sk733net/ax25/af_ax25.csk->ax25->t2 = opt * PR_SLOWHZ;
sk739net/ax25/af_ax25.csk->ax25->n2 = opt;
sk745net/ax25/af_ax25.csk->ax25->t3 = opt * PR_SLOWHZ;
sk749net/ax25/af_ax25.csk->ax25->backoff = opt ? 1 : 0;
sk753net/ax25/af_ax25.csk->ax25->modulus = opt ? EMODULUS : MODULUS;
sk757net/ax25/af_ax25.csk->ax25->hdrincl = opt ? 1 : 0;
sk768net/ax25/af_ax25.cstruct sock *sk;
sk772net/ax25/af_ax25.csk = (struct sock *)sock->data;
sk775net/ax25/af_ax25.creturn sock_getsockopt(sk, level, optname, optval, optlen);
sk782net/ax25/af_ax25.cval = sk->ax25->window;
sk786net/ax25/af_ax25.cval = (sk->ax25->t1 * 2) / PR_SLOWHZ;
sk790net/ax25/af_ax25.cval = sk->ax25->t2 / PR_SLOWHZ;
sk794net/ax25/af_ax25.cval = sk->ax25->n2;
sk798net/ax25/af_ax25.cval = sk->ax25->t3 / PR_SLOWHZ;
sk802net/ax25/af_ax25.cval = sk->ax25->backoff;
sk806net/ax25/af_ax25.cval = (sk->ax25->modulus == EMODULUS);
sk810net/ax25/af_ax25.cval = sk->ax25->hdrincl;
sk832net/ax25/af_ax25.cstruct sock *sk = (struct sock *)sock->data;
sk834net/ax25/af_ax25.cif (sk->type == SOCK_SEQPACKET && sk->state != TCP_LISTEN) {
sk835net/ax25/af_ax25.csk->max_ack_backlog = backlog;
sk836net/ax25/af_ax25.csk->state           = TCP_LISTEN;
sk843net/ax25/af_ax25.cstatic void def_callback1(struct sock *sk)
sk845net/ax25/af_ax25.cif (!sk->dead)
sk846net/ax25/af_ax25.cwake_up_interruptible(sk->sleep);
sk849net/ax25/af_ax25.cstatic void def_callback2(struct sock *sk, int len)
sk851net/ax25/af_ax25.cif (!sk->dead)
sk852net/ax25/af_ax25.cwake_up_interruptible(sk->sleep);
sk857net/ax25/af_ax25.cstruct sock *sk;
sk890net/ax25/af_ax25.cif ((sk = (struct sock *)kmalloc(sizeof(*sk), GFP_ATOMIC)) == NULL)
sk894net/ax25/af_ax25.ckfree_s(sk, sizeof(*sk));
sk898net/ax25/af_ax25.cskb_queue_head_init(&sk->receive_queue);
sk899net/ax25/af_ax25.cskb_queue_head_init(&sk->write_queue);
sk900net/ax25/af_ax25.cskb_queue_head_init(&sk->back_log);
sk902net/ax25/af_ax25.csk->socket        = sock;
sk903net/ax25/af_ax25.csk->type          = sock->type;
sk904net/ax25/af_ax25.csk->protocol      = protocol;
sk905net/ax25/af_ax25.csk->dead          = 0;
sk906net/ax25/af_ax25.csk->next          = NULL;
sk907net/ax25/af_ax25.csk->broadcast     = 0;
sk908net/ax25/af_ax25.csk->allocation    = GFP_KERNEL;
sk909net/ax25/af_ax25.csk->rcvbuf        = SK_RMEM_MAX;
sk910net/ax25/af_ax25.csk->sndbuf        = SK_WMEM_MAX;
sk911net/ax25/af_ax25.csk->wmem_alloc    = 0;
sk912net/ax25/af_ax25.csk->rmem_alloc    = 0;
sk913net/ax25/af_ax25.csk->inuse         = 0;
sk914net/ax25/af_ax25.csk->debug         = 0;
sk915net/ax25/af_ax25.csk->destroy       = 0;
sk916net/ax25/af_ax25.csk->prot          = NULL;  /* So we use default free mechanisms */
sk917net/ax25/af_ax25.csk->err           = 0;
sk918net/ax25/af_ax25.csk->localroute    = 0;
sk919net/ax25/af_ax25.csk->send_head     = NULL;
sk920net/ax25/af_ax25.csk->state         = TCP_CLOSE;
sk921net/ax25/af_ax25.csk->shutdown      = 0;
sk922net/ax25/af_ax25.csk->priority      = SOPRI_NORMAL;
sk923net/ax25/af_ax25.csk->ack_backlog   = 0;
sk924net/ax25/af_ax25.csk->mtu           = AX25_MTU;  /* 256 */
sk925net/ax25/af_ax25.csk->zapped        = 1;
sk927net/ax25/af_ax25.csk->state_change = def_callback1;
sk928net/ax25/af_ax25.csk->data_ready   = def_callback2;
sk929net/ax25/af_ax25.csk->write_space  = def_callback1;
sk930net/ax25/af_ax25.csk->error_report = def_callback1;
sk933net/ax25/af_ax25.csock->data = (void *)sk;
sk934net/ax25/af_ax25.csk->sleep  = sock->wait;
sk937net/ax25/af_ax25.cax25->sk = sk;
sk938net/ax25/af_ax25.csk->ax25 = ax25;
sk945net/ax25/af_ax25.cstruct sock *sk;
sk948net/ax25/af_ax25.cif ((sk = (struct sock *)kmalloc(sizeof(*sk), GFP_ATOMIC)) == NULL)
sk952net/ax25/af_ax25.ckfree_s(sk, sizeof(*sk));
sk958net/ax25/af_ax25.csk->type   = osk->type;
sk959net/ax25/af_ax25.csk->socket = osk->socket;
sk968net/ax25/af_ax25.ckfree_s((void *)sk, sizeof(*sk));
sk973net/ax25/af_ax25.cskb_queue_head_init(&sk->receive_queue);
sk974net/ax25/af_ax25.cskb_queue_head_init(&sk->write_queue);
sk975net/ax25/af_ax25.cskb_queue_head_init(&sk->back_log);
sk977net/ax25/af_ax25.csk->dead        = 0;
sk978net/ax25/af_ax25.csk->next        = NULL;
sk979net/ax25/af_ax25.csk->priority    = osk->priority;
sk980net/ax25/af_ax25.csk->broadcast   = 0;
sk981net/ax25/af_ax25.csk->protocol    = osk->protocol;
sk982net/ax25/af_ax25.csk->rcvbuf      = osk->rcvbuf;
sk983net/ax25/af_ax25.csk->sndbuf      = osk->sndbuf;
sk984net/ax25/af_ax25.csk->wmem_alloc  = 0;
sk985net/ax25/af_ax25.csk->rmem_alloc  = 0;
sk986net/ax25/af_ax25.csk->inuse       = 0;
sk987net/ax25/af_ax25.csk->ack_backlog = 0;
sk988net/ax25/af_ax25.csk->destroy     = 0;
sk989net/ax25/af_ax25.csk->prot        = NULL;  /* So we use default free mechanisms */
sk990net/ax25/af_ax25.csk->err         = 0;
sk991net/ax25/af_ax25.csk->localroute  = 0;
sk992net/ax25/af_ax25.csk->send_head   = NULL;
sk993net/ax25/af_ax25.csk->debug       = osk->debug;
sk994net/ax25/af_ax25.csk->state       = TCP_ESTABLISHED;
sk995net/ax25/af_ax25.csk->window      = osk->window;
sk996net/ax25/af_ax25.csk->shutdown    = 0;
sk997net/ax25/af_ax25.csk->mtu         = osk->mtu;
sk998net/ax25/af_ax25.csk->sleep       = osk->sleep;
sk999net/ax25/af_ax25.csk->zapped      = osk->zapped;
sk1001net/ax25/af_ax25.csk->state_change = def_callback1;
sk1002net/ax25/af_ax25.csk->data_ready   = def_callback2;
sk1003net/ax25/af_ax25.csk->write_space  = def_callback1;
sk1004net/ax25/af_ax25.csk->error_report = def_callback1;
sk1021net/ax25/af_ax25.ckfree_s(sk, sizeof(*sk));
sk1027net/ax25/af_ax25.csk->ax25 = ax25;
sk1028net/ax25/af_ax25.cax25->sk = sk;
sk1030net/ax25/af_ax25.creturn sk;
sk1035net/ax25/af_ax25.cstruct sock *sk = (struct sock *)oldsock->data;
sk1037net/ax25/af_ax25.creturn ax25_create(newsock, sk->protocol);
sk1042net/ax25/af_ax25.cstruct sock *sk = (struct sock *)sock->data;
sk1044net/ax25/af_ax25.cif (sk == NULL) return 0;
sk1046net/ax25/af_ax25.cif (sk->type == SOCK_SEQPACKET) {
sk1047net/ax25/af_ax25.cswitch (sk->ax25->state) {
sk1049net/ax25/af_ax25.csk->state       = TCP_CLOSE;
sk1050net/ax25/af_ax25.csk->state_change(sk);
sk1051net/ax25/af_ax25.csk->dead        = 1;
sk1052net/ax25/af_ax25.cax25_destroy_socket(sk->ax25);
sk1056net/ax25/af_ax25.cax25_send_control(sk->ax25, DISC, POLLON, C_COMMAND);
sk1057net/ax25/af_ax25.csk->ax25->state = AX25_STATE_0;
sk1058net/ax25/af_ax25.csk->state       = TCP_CLOSE;
sk1059net/ax25/af_ax25.csk->state_change(sk);
sk1060net/ax25/af_ax25.csk->dead        = 1;
sk1061net/ax25/af_ax25.cax25_destroy_socket(sk->ax25);
sk1065net/ax25/af_ax25.cax25_send_control(sk->ax25, DM, POLLON, C_RESPONSE);
sk1066net/ax25/af_ax25.csk->ax25->state = AX25_STATE_0;
sk1067net/ax25/af_ax25.csk->state       = TCP_CLOSE;
sk1068net/ax25/af_ax25.csk->state_change(sk);
sk1069net/ax25/af_ax25.csk->dead        = 1;
sk1070net/ax25/af_ax25.cax25_destroy_socket(sk->ax25);
sk1075net/ax25/af_ax25.cax25_clear_queues(sk->ax25);
sk1076net/ax25/af_ax25.csk->ax25->n2count = 0;
sk1077net/ax25/af_ax25.cax25_send_control(sk->ax25, DISC, POLLON, C_COMMAND);
sk1078net/ax25/af_ax25.csk->ax25->t3timer = 0;
sk1079net/ax25/af_ax25.csk->ax25->t1timer = sk->ax25->t1 = ax25_calculate_t1(sk->ax25);
sk1080net/ax25/af_ax25.csk->ax25->state   = AX25_STATE_2;
sk1081net/ax25/af_ax25.csk->state         = TCP_CLOSE;
sk1082net/ax25/af_ax25.csk->state_change(sk);
sk1083net/ax25/af_ax25.csk->dead          = 1;
sk1084net/ax25/af_ax25.csk->destroy       = 1;
sk1091net/ax25/af_ax25.csk->state       = TCP_CLOSE;
sk1092net/ax25/af_ax25.csk->state_change(sk);
sk1093net/ax25/af_ax25.csk->dead = 1;
sk1094net/ax25/af_ax25.cax25_destroy_socket(sk->ax25);
sk1098net/ax25/af_ax25.csk->socket = NULL;  /* Not used, but we should do this. **/
sk1111net/ax25/af_ax25.cstruct sock *sk;
sk1116net/ax25/af_ax25.csk = (struct sock *)sock->data;
sk1118net/ax25/af_ax25.cif (sk->zapped == 0)
sk1125net/ax25/af_ax25.cif (ax25_find_socket(&addr->fsa_ax25.sax25_call, sk->type) != NULL) {
sk1126net/ax25/af_ax25.cif (sk->debug)
sk1137net/ax25/af_ax25.cmemcpy(&sk->ax25->source_addr, &addr->fsa_ax25.sax25_call, sizeof(ax25_address));
sk1139net/ax25/af_ax25.cmemcpy(&sk->ax25->source_addr, call, sizeof(ax25_address));
sk1150net/ax25/af_ax25.cif (sk->debug)
sk1155net/ax25/af_ax25.cax25_fillin_cb(sk->ax25, dev);
sk1156net/ax25/af_ax25.cax25_insert_socket(sk->ax25);
sk1158net/ax25/af_ax25.csk->zapped = 0;
sk1160net/ax25/af_ax25.cif (sk->debug)
sk1169net/ax25/af_ax25.cstruct sock *sk = (struct sock *)sock->data;
sk1173net/ax25/af_ax25.cif (sk->state == TCP_ESTABLISHED && sock->state == SS_CONNECTING) {
sk1178net/ax25/af_ax25.cif (sk->state == TCP_CLOSE && sock->state == SS_CONNECTING) {
sk1183net/ax25/af_ax25.cif (sk->state == TCP_ESTABLISHED && sk->type == SOCK_SEQPACKET)
sk1186net/ax25/af_ax25.csk->state   = TCP_CLOSE;  
sk1199net/ax25/af_ax25.cif (sk->ax25->digipeat == NULL) {
sk1200net/ax25/af_ax25.cif ((sk->ax25->digipeat = (ax25_digi *)kmalloc(sizeof(ax25_digi), GFP_KERNEL)) == NULL)
sk1204net/ax25/af_ax25.csk->ax25->digipeat->ndigi = addr->sax25_ndigis;
sk1207net/ax25/af_ax25.csk->ax25->digipeat->repeated[ct] = 0;
sk1208net/ax25/af_ax25.cmemcpy(&sk->ax25->digipeat->calls[ct], &fsa->fsa_digipeater[ct], sizeof(ax25_address));
sk1212net/ax25/af_ax25.csk->ax25->digipeat->lastrepeat = 0;
sk1215net/ax25/af_ax25.cif (sk->zapped) {  /* Must bind first - autobinding in this may or may not work */
sk1216net/ax25/af_ax25.cif ((err = ax25_rt_autobind(sk->ax25, &addr->sax25_call)) < 0)
sk1218net/ax25/af_ax25.cax25_insert_socket(sk->ax25);    /* Finish the bind */
sk1221net/ax25/af_ax25.cif (sk->type == SOCK_SEQPACKET && ax25_find_cb(&sk->ax25->source_addr, &addr->sax25_call, sk->ax25->device) != NULL)
sk1224net/ax25/af_ax25.cmemcpy(&sk->ax25->dest_addr, &addr->sax25_call, sizeof(ax25_address));
sk1227net/ax25/af_ax25.cif (sk->type != SOCK_SEQPACKET) {
sk1229net/ax25/af_ax25.csk->state   = TCP_ESTABLISHED;
sk1235net/ax25/af_ax25.csk->state          = TCP_SYN_SENT;
sk1236net/ax25/af_ax25.cax25_establish_data_link(sk->ax25);
sk1237net/ax25/af_ax25.csk->ax25->state     = AX25_STATE_1;
sk1238net/ax25/af_ax25.cax25_set_timer(sk->ax25);    /* Start going SABM SABM until a UA or a give up and DM */
sk1241net/ax25/af_ax25.cif (sk->state != TCP_ESTABLISHED && (flags & O_NONBLOCK))
sk1247net/ax25/af_ax25.cwhile (sk->state == TCP_SYN_SENT) {
sk1248net/ax25/af_ax25.cinterruptible_sleep_on(sk->sleep);
sk1255net/ax25/af_ax25.cif (sk->state != TCP_ESTABLISHED) {  /* Not in ABM, not in WAIT_UA -> failed */
sk1258net/ax25/af_ax25.creturn -sk->err;  /* Always set at this point */
sk1275net/ax25/af_ax25.cstruct sock *sk;
sk1284net/ax25/af_ax25.csk = (struct sock *)sock->data;
sk1286net/ax25/af_ax25.cif (sk->type != SOCK_SEQPACKET)
sk1289net/ax25/af_ax25.cif (sk->state != TCP_LISTEN)
sk1296net/ax25/af_ax25.cif ((skb = skb_dequeue(&sk->receive_queue)) == NULL) {
sk1301net/ax25/af_ax25.cinterruptible_sleep_on(sk->sleep);
sk1309net/ax25/af_ax25.cnewsk = skb->sk;
sk1314net/ax25/af_ax25.cskb->sk = NULL;
sk1316net/ax25/af_ax25.csk->ack_backlog--;
sk1327net/ax25/af_ax25.cstruct sock *sk;
sk1330net/ax25/af_ax25.csk = (struct sock *)sock->data;
sk1333net/ax25/af_ax25.cif (sk->state != TCP_ESTABLISHED)
sk1335net/ax25/af_ax25.caddr = &sk->ax25->dest_addr;
sk1337net/ax25/af_ax25.caddr = &sk->ax25->source_addr;
sk1346net/ax25/af_ax25.cif (sk->ax25->digipeat != NULL) {
sk1347net/ax25/af_ax25.cndigi = sk->ax25->digipeat->ndigi;
sk1351net/ax25/af_ax25.cmemcpy(&sax->fsa_digipeater[i], &sk->ax25->digipeat->calls[i], sizeof(ax25_address));
sk1360net/ax25/af_ax25.cstruct sock *sk;
sk1487net/ax25/af_ax25.cif ((sk = ax25_find_socket(&dest, &src, SOCK_DGRAM)) != NULL) {
sk1488net/ax25/af_ax25.cif (sk->rmem_alloc >= sk->rcvbuf) {
sk1495net/ax25/af_ax25.cskb_queue_tail(&sk->receive_queue, skb);
sk1496net/ax25/af_ax25.cskb->sk = sk;
sk1497net/ax25/af_ax25.csk->rmem_alloc += skb->truesize;
sk1498net/ax25/af_ax25.cif (!sk->dead)
sk1499net/ax25/af_ax25.csk->data_ready(sk, skb->len);
sk1549net/ax25/af_ax25.cif ((sk = ax25_find_listener(&dest, dev, SOCK_SEQPACKET)) != NULL) {
sk1550net/ax25/af_ax25.cif (sk->ack_backlog == sk->max_ack_backlog || (make = ax25_make_new(sk, dev)) == NULL) {
sk1560net/ax25/af_ax25.cskb_queue_head(&sk->receive_queue, skb);
sk1562net/ax25/af_ax25.cskb->sk     = make;
sk1564net/ax25/af_ax25.cmake->pair  = sk;
sk1566net/ax25/af_ax25.csk->ack_backlog++;
sk1631net/ax25/af_ax25.cif (sk != NULL) {
sk1632net/ax25/af_ax25.cif (!sk->dead)
sk1633net/ax25/af_ax25.csk->data_ready(sk, skb->len );
sk1646net/ax25/af_ax25.cskb->sk = NULL;    /* Initially we don't know who its for */
sk1666net/ax25/af_ax25.cskb->sk = NULL;    /* Initially we don't know who its for */
sk1683net/ax25/af_ax25.cstruct sock *sk = (struct sock *)sock->data;
sk1695net/ax25/af_ax25.cif (sk->err) {
sk1697net/ax25/af_ax25.cerr     = sk->err;
sk1698net/ax25/af_ax25.csk->err = 0;
sk1706net/ax25/af_ax25.cif (sk->zapped)
sk1709net/ax25/af_ax25.cif (sk->ax25->device == NULL)
sk1737net/ax25/af_ax25.cif (sk->type == SOCK_SEQPACKET && memcmp(&sk->ax25->dest_addr, &sax.sax25_call, sizeof(ax25_address)) != 0)
sk1744net/ax25/af_ax25.cif (sk->state != TCP_ESTABLISHED)
sk1747net/ax25/af_ax25.cmemcpy(&sax.sax25_call, &sk->ax25->dest_addr, sizeof(ax25_address));
sk1748net/ax25/af_ax25.cdp = sk->ax25->digipeat;
sk1751net/ax25/af_ax25.cif (sk->debug)
sk1755net/ax25/af_ax25.cif (sk->debug)
sk1761net/ax25/af_ax25.cif ((skb = sock_alloc_send_skb(sk, size, 0, 0, &err)) == NULL)
sk1764net/ax25/af_ax25.cskb->sk   = sk;
sk1770net/ax25/af_ax25.cif (sk->debug)
sk1778net/ax25/af_ax25.c*asmptr = sk->protocol;
sk1780net/ax25/af_ax25.cif (sk->debug)
sk1783net/ax25/af_ax25.cif (sk->type == SOCK_SEQPACKET) {
sk1785net/ax25/af_ax25.cif (sk->state != TCP_ESTABLISHED) {
sk1790net/ax25/af_ax25.cax25_output(sk->ax25, skb);  /* Shove it onto the queue and kick */
sk1796net/ax25/af_ax25.cif (sk->debug) {
sk1803net/ax25/af_ax25.casmptr += (lv = build_ax25_addr(asmptr, &sk->ax25->source_addr, &sax.sax25_call, dp, C_COMMAND, MODULUS));
sk1805net/ax25/af_ax25.cif (sk->debug)
sk1810net/ax25/af_ax25.cif (sk->debug)
sk1816net/ax25/af_ax25.cax25_queue_xmit(skb, sk->ax25->device, SOPRI_NORMAL);
sk1853net/ax25/af_ax25.cstruct sock *sk = (struct sock *)sock->data;
sk1859net/ax25/af_ax25.cif (sk->err) {
sk1861net/ax25/af_ax25.cer      = -sk->err;
sk1862net/ax25/af_ax25.csk->err = 0;
sk1874net/ax25/af_ax25.cif (sk->type == SOCK_SEQPACKET && sk->state != TCP_ESTABLISHED)
sk1878net/ax25/af_ax25.cif ((skb = skb_recv_datagram(sk, flags, noblock, &er)) == NULL)
sk1881net/ax25/af_ax25.cif (sk->ax25->hdrincl) {
sk1884net/ax25/af_ax25.cif (sk->type == SOCK_SEQPACKET)
sk1954net/ax25/af_ax25.cstruct sock *sk = (struct sock *)sock->data;
sk1956net/ax25/af_ax25.cif (sk->zapped)
sk1967net/ax25/af_ax25.cstatic int ax25_shutdown(struct socket *sk, int how)
sk1975net/ax25/af_ax25.cstruct sock *sk = (struct sock *)sock->data;
sk1977net/ax25/af_ax25.creturn datagram_select(sk, sel_type, wait);
sk1982net/ax25/af_ax25.cstruct sock *sk = (struct sock *)sock->data;
sk1990net/ax25/af_ax25.camount = sk->sndbuf - sk->wmem_alloc;
sk2000net/ax25/af_ax25.cif ((skb = skb_peek(&sk->receive_queue)) != NULL)
sk2009net/ax25/af_ax25.cif (sk != NULL) {
sk2010net/ax25/af_ax25.cif (sk->stamp.tv_sec==0)
sk2014net/ax25/af_ax25.cmemcpy_tofs((void *)arg, &sk->stamp, sizeof(struct timeval));
sk2106net/ax25/af_ax25.cif (ax25->sk != NULL) {
sk2108net/ax25/af_ax25.cax25->sk->wmem_alloc,
sk2109net/ax25/af_ax25.cax25->sk->rmem_alloc);
sk84net/ax25/ax25_in.cif (ax25->sk != NULL) {
sk85net/ax25/ax25_in.cskbn->sk = ax25->sk;
sk86net/ax25/ax25_in.cax25->sk->rmem_alloc += skbn->truesize;
sk159net/ax25/ax25_in.cif (ax25->sk != NULL && ax25_dev_get_value(ax25->device, AX25_VALUES_TEXT) && ax25->sk->protocol == pid) {
sk160net/ax25/ax25_in.cif (sock_queue_rcv_skb(ax25->sk, skb) == 0) {
sk206net/ax25/ax25_in.cif (ax25->sk != NULL) {
sk207net/ax25/ax25_in.cax25->sk->state = TCP_ESTABLISHED;
sk209net/ax25/ax25_in.cif (!ax25->sk->dead)
sk210net/ax25/ax25_in.cax25->sk->state_change(ax25->sk);
sk220net/ax25/ax25_in.cif (ax25->sk != NULL) {
sk221net/ax25/ax25_in.cax25->sk->state = TCP_CLOSE;
sk222net/ax25/ax25_in.cax25->sk->err   = ECONNREFUSED;
sk223net/ax25/ax25_in.cif (!ax25->sk->dead)
sk224net/ax25/ax25_in.cax25->sk->state_change(ax25->sk);
sk225net/ax25/ax25_in.cax25->sk->dead  = 1;
sk261net/ax25/ax25_in.cif (ax25->sk != NULL) {
sk262net/ax25/ax25_in.cax25->sk->state = TCP_CLOSE;
sk263net/ax25/ax25_in.cax25->sk->err   = 0;
sk264net/ax25/ax25_in.cif (!ax25->sk->dead)
sk265net/ax25/ax25_in.cax25->sk->state_change(ax25->sk);
sk266net/ax25/ax25_in.cax25->sk->dead  = 1;
sk274net/ax25/ax25_in.cif (ax25->sk != NULL) {
sk275net/ax25/ax25_in.cax25->sk->state = TCP_CLOSE;
sk276net/ax25/ax25_in.cax25->sk->err   = 0;
sk277net/ax25/ax25_in.cif (!ax25->sk->dead)
sk278net/ax25/ax25_in.cax25->sk->state_change(ax25->sk);
sk279net/ax25/ax25_in.cax25->sk->dead  = 1;
sk338net/ax25/ax25_in.cif (ax25->sk != NULL) {
sk339net/ax25/ax25_in.cax25->sk->state = TCP_CLOSE;
sk340net/ax25/ax25_in.cax25->sk->err   = 0;
sk341net/ax25/ax25_in.cif (!ax25->sk->dead)
sk342net/ax25/ax25_in.cax25->sk->state_change(ax25->sk);
sk343net/ax25/ax25_in.cax25->sk->dead  = 1;
sk351net/ax25/ax25_in.cif (ax25->sk) {
sk352net/ax25/ax25_in.cax25->sk->state = TCP_CLOSE;
sk353net/ax25/ax25_in.cax25->sk->err   = ECONNRESET;
sk354net/ax25/ax25_in.cif (!ax25->sk->dead)
sk355net/ax25/ax25_in.cax25->sk->state_change(ax25->sk);
sk356net/ax25/ax25_in.cax25->sk->dead         = 1;
sk499net/ax25/ax25_in.cif (ax25->sk != NULL) {
sk500net/ax25/ax25_in.cax25->sk->state = TCP_CLOSE;
sk501net/ax25/ax25_in.cax25->sk->err   = 0;
sk502net/ax25/ax25_in.cif (!ax25->sk->dead)
sk503net/ax25/ax25_in.cax25->sk->state_change(ax25->sk);
sk504net/ax25/ax25_in.cax25->sk->dead  = 1;
sk512net/ax25/ax25_in.cif (ax25->sk != NULL) {
sk513net/ax25/ax25_in.cax25->sk->state = TCP_CLOSE;
sk514net/ax25/ax25_in.cax25->sk->err   = ECONNRESET;
sk515net/ax25/ax25_in.cif (!ax25->sk->dead)
sk516net/ax25/ax25_in.cax25->sk->state_change(ax25->sk);
sk517net/ax25/ax25_in.cax25->sk->dead  = 1;
sk671net/ax25/ax25_in.cif (ax25->sk != NULL && ax25->state == AX25_STATE_0 && ax25->sk->dead)
sk73net/ax25/ax25_out.cif (skb->sk != NULL) {
sk74net/ax25/ax25_out.cif ((skbn = sock_alloc_send_skb(skb->sk, mtu + 2 + frontlen, 0, 0, &err)) == NULL)
sk81net/ax25/ax25_out.cskbn->sk   = skb->sk;
sk217net/ax25/ax25_out.cif (ax25->sk != NULL) {
sk218net/ax25/ax25_out.cax25->sk->state = TCP_CLOSE;
sk219net/ax25/ax25_out.cax25->sk->err   = ENETUNREACH;
sk220net/ax25/ax25_out.cif (!ax25->sk->dead)
sk221net/ax25/ax25_out.cax25->sk->state_change(ax25->sk);
sk222net/ax25/ax25_out.cax25->sk->dead  = 1;
sk387net/ax25/ax25_route.cif (ax25->sk != NULL)
sk388net/ax25/ax25_route.cax25->sk->zapped = 0;
sk209net/ax25/ax25_subr.cif (ax25->sk != NULL) {
sk210net/ax25/ax25_subr.cskb->sk = ax25->sk;
sk211net/ax25/ax25_subr.cax25->sk->wmem_alloc += skb->truesize;
sk261net/ax25/ax25_subr.cskb->sk = NULL;
sk99net/ax25/ax25_timer.cif (ax25->sk == NULL || ax25->sk->destroy || (ax25->sk->state == TCP_LISTEN && ax25->sk->dead)) {
sk111net/ax25/ax25_timer.cif (ax25->sk != NULL) {
sk112net/ax25/ax25_timer.cif (ax25->sk->rmem_alloc < (ax25->sk->rcvbuf / 2) && (ax25->condition & OWN_RX_BUSY_CONDITION)) {
sk161net/ax25/ax25_timer.cif (ax25->sk != NULL) {
sk162net/ax25/ax25_timer.cax25->sk->state = TCP_CLOSE;
sk163net/ax25/ax25_timer.cax25->sk->err   = ETIMEDOUT;
sk164net/ax25/ax25_timer.cif (!ax25->sk->dead)
sk165net/ax25/ax25_timer.cax25->sk->state_change(ax25->sk);
sk166net/ax25/ax25_timer.cax25->sk->dead  = 1;
sk191net/ax25/ax25_timer.cif (ax25->sk != NULL) {
sk192net/ax25/ax25_timer.cax25->sk->state = TCP_CLOSE;
sk193net/ax25/ax25_timer.cax25->sk->err   = ETIMEDOUT;
sk194net/ax25/ax25_timer.cif (!ax25->sk->dead)
sk195net/ax25/ax25_timer.cax25->sk->state_change(ax25->sk);
sk196net/ax25/ax25_timer.cax25->sk->dead  = 1;
sk218net/ax25/ax25_timer.cif (ax25->sk != NULL) {
sk219net/ax25/ax25_timer.cax25->sk->state = TCP_CLOSE;
sk220net/ax25/ax25_timer.cax25->sk->err   = ETIMEDOUT;
sk221net/ax25/ax25_timer.cif (!ax25->sk->dead)
sk222net/ax25/ax25_timer.cax25->sk->state_change(ax25->sk);
sk223net/ax25/ax25_timer.cax25->sk->dead  = 1;
sk55net/core/datagram.cstruct sk_buff *skb_recv_datagram(struct sock *sk, unsigned flags, int noblock, int *err)
sk63net/core/datagram.csk->inuse = 1;
sk64net/core/datagram.cwhile(skb_peek(&sk->receive_queue) == NULL)  /* No data */
sk67net/core/datagram.cif (sk->shutdown & RCV_SHUTDOWN)
sk69net/core/datagram.crelease_sock(sk);
sk74net/core/datagram.cif(sk->err)
sk76net/core/datagram.crelease_sock(sk);
sk78net/core/datagram.c*err=-sk->err;
sk79net/core/datagram.csk->err=0;
sk85net/core/datagram.cif(sk->type==SOCK_SEQPACKET && sk->state!=TCP_ESTABLISHED)
sk87net/core/datagram.crelease_sock(sk);
sk95net/core/datagram.crelease_sock(sk);
sk99net/core/datagram.crelease_sock(sk);
sk104net/core/datagram.cif (skb_peek(&sk->receive_queue) == NULL)
sk106net/core/datagram.cinterruptible_sleep_on(sk->sleep);
sk114net/core/datagram.cif(sk->err != 0)  /* Error while waiting for packet
sk118net/core/datagram.c*err = -sk->err;
sk119net/core/datagram.csk->err=0;
sk124net/core/datagram.csk->inuse = 1;
sk131net/core/datagram.cskb=skb_dequeue(&sk->receive_queue);
sk140net/core/datagram.cskb=skb_peek(&sk->receive_queue);
sk192net/core/datagram.cint datagram_select(struct sock *sk, int sel_type, select_table *wait)
sk194net/core/datagram.cselect_wait(sk->sleep, wait);
sk198net/core/datagram.cif (sk->err)
sk200net/core/datagram.cif (sk->shutdown & RCV_SHUTDOWN)
sk202net/core/datagram.cif (sk->type==SOCK_SEQPACKET && sk->state==TCP_CLOSE)
sk207net/core/datagram.cif (skb_peek(&sk->receive_queue) != NULL)
sk215net/core/datagram.cif (sk->err)
sk217net/core/datagram.cif (sk->shutdown & SEND_SHUTDOWN)
sk219net/core/datagram.cif (sk->type==SOCK_SEQPACKET && sk->state==TCP_SYN_SENT)
sk224net/core/datagram.cif (sk->prot && sock_wspace(sk) >= MIN_WRITE_SPACE)
sk228net/core/datagram.cif (sk->prot==NULL && sk->sndbuf-sk->wmem_alloc >= MIN_WRITE_SPACE)
sk235net/core/datagram.cif (sk->err)
sk384net/core/dev.c((struct sock *)ptype->data != skb->sk))
sk430net/core/dev.cskb->sk = NULL;
sk463net/core/skbuff.cif (skb->sk)
sk465net/core/skbuff.cif(skb->sk->prot!=NULL)
sk468net/core/skbuff.csock_rfree(skb->sk, skb);
sk470net/core/skbuff.csock_wfree(skb->sk, skb);
sk480net/core/skbuff.cskb->sk->rmem_alloc-=skb->truesize;
sk482net/core/skbuff.cskb->sk->wmem_alloc-=skb->truesize;
sk484net/core/skbuff.cif(!skb->sk->dead)
sk485net/core/skbuff.cskb->sk->write_space(skb->sk);
sk547net/core/skbuff.cskb->sk = NULL;
sk618net/core/skbuff.cn->sk=NULL;
sk119net/core/sock.cint sock_setsockopt(struct sock *sk, int level, int optname,
sk142net/core/sock.csk->debug=valbool;
sk145net/core/sock.csk->reuse = valbool;
sk151net/core/sock.csk->localroute=valbool;
sk154net/core/sock.csk->broadcast=valbool;
sk161net/core/sock.csk->sndbuf=val;
sk169net/core/sock.csk->rcvbuf=val;
sk173net/core/sock.csk->keepopen = valbool;
sk177net/core/sock.csk->urginline = valbool;
sk181net/core/sock.csk->no_check = valbool;
sk187net/core/sock.csk->priority = val;
sk202net/core/sock.csk->linger=0;
sk205net/core/sock.csk->lingertime=ling.l_linger;
sk206net/core/sock.csk->linger=1;
sk217net/core/sock.cint sock_getsockopt(struct sock *sk, int level, int optname,
sk227net/core/sock.cval = sk->debug;
sk231net/core/sock.cval = sk->localroute;
sk235net/core/sock.cval= sk->broadcast;
sk239net/core/sock.cval=sk->sndbuf;
sk243net/core/sock.cval =sk->rcvbuf;
sk247net/core/sock.cval = sk->reuse;
sk251net/core/sock.cval = sk->keepopen;
sk255net/core/sock.cval = sk->type;          
sk259net/core/sock.cval = sk->err;
sk260net/core/sock.csk->err = 0;
sk264net/core/sock.cval = sk->urginline;
sk268net/core/sock.cval = sk->no_check;
sk272net/core/sock.cval = sk->priority;
sk283net/core/sock.cling.l_onoff=sk->linger;
sk284net/core/sock.cling.l_linger=sk->lingertime;
sk307net/core/sock.cstruct sk_buff *sock_wmalloc(struct sock *sk, unsigned long size, int force, int priority)
sk309net/core/sock.cif (sk) 
sk311net/core/sock.cif (sk->wmem_alloc + size < sk->sndbuf || force) 
sk319net/core/sock.csk->wmem_alloc+= c->truesize;
sk330net/core/sock.cstruct sk_buff *sock_rmalloc(struct sock *sk, unsigned long size, int force, int priority)
sk332net/core/sock.cif (sk) 
sk334net/core/sock.cif (sk->rmem_alloc + size < sk->rcvbuf || force) 
sk342net/core/sock.csk->rmem_alloc += c->truesize;
sk353net/core/sock.cunsigned long sock_rspace(struct sock *sk)
sk357net/core/sock.cif (sk != NULL) 
sk359net/core/sock.cif (sk->rmem_alloc >= sk->rcvbuf-2*MIN_WINDOW) 
sk361net/core/sock.camt = min((sk->rcvbuf-sk->rmem_alloc)/2-MIN_WINDOW, MAX_WINDOW);
sk370net/core/sock.cunsigned long sock_wspace(struct sock *sk)
sk372net/core/sock.cif (sk != NULL) 
sk374net/core/sock.cif (sk->shutdown & SEND_SHUTDOWN)
sk376net/core/sock.cif (sk->wmem_alloc >= sk->sndbuf)
sk378net/core/sock.creturn(sk->sndbuf-sk->wmem_alloc );
sk384net/core/sock.cvoid sock_wfree(struct sock *sk, struct sk_buff *skb)
sk391net/core/sock.cif (sk) 
sk396net/core/sock.csk->wmem_alloc -= s;
sk399net/core/sock.csk->write_space(sk);
sk405net/core/sock.cvoid sock_rfree(struct sock *sk, struct sk_buff *skb)
sk412net/core/sock.cif (sk) 
sk417net/core/sock.csk->rmem_alloc -= s;
sk426net/core/sock.cstruct sk_buff *sock_alloc_send_skb(struct sock *sk, unsigned long size, unsigned long fallback, int noblock, int *errcode)
sk431net/core/sock.csk->inuse=1;
sk435net/core/sock.cif(sk->err!=0)
sk438net/core/sock.cerr= -sk->err;
sk439net/core/sock.csk->err=0;
sk445net/core/sock.cif(sk->shutdown&SEND_SHUTDOWN)
sk452net/core/sock.cskb = sock_wmalloc(sk, size, 0, sk->allocation);
sk457net/core/sock.cskb = sock_wmalloc(sk, size, 0 , GFP_BUFFER);
sk459net/core/sock.cskb=sock_wmalloc(sk, fallback, 0, GFP_KERNEL);
sk470net/core/sock.csk->socket->flags |= SO_NOSPACE;
sk476net/core/sock.cif(sk->shutdown&SEND_SHUTDOWN)
sk481net/core/sock.ctmp = sk->wmem_alloc;
sk483net/core/sock.cif(sk->shutdown&SEND_SHUTDOWN)
sk491net/core/sock.cif( tmp <= sk->wmem_alloc)
sk501net/core/sock.cif (sk->wmem_alloc + size >= sk->sndbuf) 
sk504net/core/sock.cif (sk->wmem_alloc <= 0)
sk505net/core/sock.cprintk("sock.c: Look where I am %ld<%ld\n", tmp, sk->wmem_alloc);
sk506net/core/sock.csk->socket->flags &= ~SO_NOSPACE;
sk507net/core/sock.cinterruptible_sleep_on(sk->sleep);
sk524net/core/sock.cvoid release_sock(struct sock *sk)
sk531net/core/sock.cif (!sk->prot)
sk542net/core/sock.cif (sk->blog) 
sk547net/core/sock.csk->blog=1;
sk548net/core/sock.csk->inuse = 1;
sk552net/core/sock.cwhile((skb = skb_dequeue(&sk->back_log)) != NULL) 
sk554net/core/sock.csk->blog = 1;
sk555net/core/sock.cif (sk->prot->rcv) 
sk556net/core/sock.csk->prot->rcv(skb, skb->dev, (struct options*)skb->proto_priv,
sk559net/core/sock.c(struct inet_protocol *)sk->pair); 
sk562net/core/sock.csk->blog = 0;
sk563net/core/sock.csk->inuse = 0;
sk565net/core/sock.cif (sk->dead && sk->state == TCP_CLOSE) 
sk568net/core/sock.creset_timer(sk, TIME_DONE, min(sk->rtt * 2, TCP_DONE_TIME));
sk224net/ethernet/eth.cvoid eth_header_cache(struct device *dev, struct sock *sk, unsigned long saddr, unsigned long daddr)
sk226net/ethernet/eth.cint v=arp_find_cache(sk->ip_hcache_data, daddr, dev);
sk228net/ethernet/eth.csk->ip_hcache_state=0;  /* Try when arp resolves */
sk231net/ethernet/eth.cmemcpy(sk->ip_hcache_data+6, dev->dev_addr, ETH_ALEN);
sk232net/ethernet/eth.csk->ip_hcache_data[12]=ETH_P_IP>>8;
sk233net/ethernet/eth.csk->ip_hcache_data[13]=ETH_P_IP&0xFF;
sk234net/ethernet/eth.csk->ip_hcache_state=1;
sk235net/ethernet/eth.csk->ip_hcache_stamp=arp_cache_stamp;
sk236net/ethernet/eth.csk->ip_hcache_ver=&arp_cache_stamp;
sk108net/ipv4/af_inet.cstruct sock *sk;
sk110net/ipv4/af_inet.cfor(sk = prot->sock_array[num & (SOCK_ARRAY_SIZE -1 )];
sk111net/ipv4/af_inet.csk != NULL;  sk=sk->next) 
sk113net/ipv4/af_inet.cif (sk->num == num) 
sk136net/ipv4/af_inet.cstruct sock *sk;
sk152net/ipv4/af_inet.csk = prot->sock_array[(i+base+1) &(SOCK_ARRAY_SIZE -1)];
sk153net/ipv4/af_inet.cwhile(sk != NULL) 
sk155net/ipv4/af_inet.csk = sk->next;
sk183net/ipv4/af_inet.cvoid put_sock(unsigned short num, struct sock *sk)
sk189net/ipv4/af_inet.cif(sk->type==SOCK_PACKET)
sk192net/ipv4/af_inet.csk->num = num;
sk193net/ipv4/af_inet.csk->next = NULL;
sk203net/ipv4/af_inet.csk->prot->inuse += 1;
sk204net/ipv4/af_inet.cif (sk->prot->highestinuse < sk->prot->inuse)
sk205net/ipv4/af_inet.csk->prot->highestinuse = sk->prot->inuse;
sk207net/ipv4/af_inet.cif (sk->prot->sock_array[num] == NULL) 
sk209net/ipv4/af_inet.csk->prot->sock_array[num] = sk;
sk217net/ipv4/af_inet.cif ((mask & sk->rcv_saddr) &&
sk218net/ipv4/af_inet.c(mask & sk->rcv_saddr) != (mask & 0xffffffff)) 
sk228net/ipv4/af_inet.cskp = sk->prot->sock_array + num;
sk235net/ipv4/af_inet.csk->next = tmp;
sk236net/ipv4/af_inet.c*skp = sk;
sk281net/ipv4/af_inet.cvoid destroy_sock(struct sock *sk)
sk285net/ipv4/af_inet.csk->inuse = 1;      /* just to be safe. */
sk291net/ipv4/af_inet.cif (!sk->dead) 
sk292net/ipv4/af_inet.csk->write_space(sk);
sk294net/ipv4/af_inet.cremove_sock(sk);
sk301net/ipv4/af_inet.cdelete_timer(sk);
sk302net/ipv4/af_inet.cdel_timer(&sk->retransmit_timer);
sk308net/ipv4/af_inet.cwhile ((skb = tcp_dequeue_partial(sk)) != NULL) 
sk318net/ipv4/af_inet.cwhile((skb = skb_dequeue(&sk->write_queue)) != NULL) {
sk328net/ipv4/af_inet.cif (sk->dead) 
sk330net/ipv4/af_inet.cwhile((skb=skb_dequeue(&sk->receive_queue))!=NULL) 
sk336net/ipv4/af_inet.cif (skb->sk != NULL && skb->sk != sk) 
sk339net/ipv4/af_inet.cskb->sk->dead = 1;
sk340net/ipv4/af_inet.cskb->sk->prot->close(skb->sk, 0);
sk352net/ipv4/af_inet.cfor(skb = sk->send_head; skb != NULL; )
sk370net/ipv4/af_inet.csk->send_head = NULL;
sk377net/ipv4/af_inet.cwhile((skb=skb_dequeue(&sk->back_log))!=NULL) 
sk387net/ipv4/af_inet.cif (sk->pair) 
sk389net/ipv4/af_inet.csk->pair->dead = 1;
sk390net/ipv4/af_inet.csk->pair->prot->close(sk->pair, 0);
sk391net/ipv4/af_inet.csk->pair = NULL;
sk400net/ipv4/af_inet.cif (sk->dead && sk->rmem_alloc == 0 && sk->wmem_alloc == 0) 
sk402net/ipv4/af_inet.cif(sk->opt)
sk403net/ipv4/af_inet.ckfree(sk->opt);
sk409net/ipv4/af_inet.ckfree_s((void *)sk,sizeof(*sk));
sk415net/ipv4/af_inet.csk->destroy = 1;
sk416net/ipv4/af_inet.csk->ack_backlog = 0;
sk417net/ipv4/af_inet.csk->inuse = 0;
sk418net/ipv4/af_inet.creset_timer(sk, TIME_DESTROY, SOCK_DESTROY_TIME);
sk430net/ipv4/af_inet.cstruct sock *sk;
sk432net/ipv4/af_inet.csk = (struct sock *) sock->data;
sk444net/ipv4/af_inet.csk->proc = arg;
sk447net/ipv4/af_inet.creturn(sk->proc);
sk460net/ipv4/af_inet.cstruct sock *sk = (struct sock *) sock->data;  
sk462net/ipv4/af_inet.creturn sock_setsockopt(sk,level,optname,optval,optlen);
sk463net/ipv4/af_inet.cif (sk->prot->setsockopt==NULL)
sk466net/ipv4/af_inet.creturn sk->prot->setsockopt(sk,level,optname,optval,optlen);
sk476net/ipv4/af_inet.cstruct sock *sk = (struct sock *) sock->data;    
sk478net/ipv4/af_inet.creturn sock_getsockopt(sk,level,optname,optval,optlen);
sk479net/ipv4/af_inet.cif(sk->prot->getsockopt==NULL)    
sk482net/ipv4/af_inet.creturn sk->prot->getsockopt(sk,level,optname,optval,optlen);
sk489net/ipv4/af_inet.cstatic int inet_autobind(struct sock *sk)
sk492net/ipv4/af_inet.cif (sk->num == 0) 
sk494net/ipv4/af_inet.csk->num = get_new_socknum(sk->prot, 0);
sk495net/ipv4/af_inet.cif (sk->num == 0) 
sk499net/ipv4/af_inet.cput_sock(sk->num, sk);
sk500net/ipv4/af_inet.csk->dummy_th.source = ntohs(sk->num);
sk511net/ipv4/af_inet.cstruct sock *sk = (struct sock *) sock->data;
sk513net/ipv4/af_inet.cif(inet_autobind(sk)!=0)
sk527net/ipv4/af_inet.csk->max_ack_backlog = backlog;
sk528net/ipv4/af_inet.cif (sk->state != TCP_LISTEN)
sk530net/ipv4/af_inet.csk->ack_backlog = 0;
sk531net/ipv4/af_inet.csk->state = TCP_LISTEN;
sk541net/ipv4/af_inet.cstatic void def_callback1(struct sock *sk)
sk543net/ipv4/af_inet.cif(!sk->dead)
sk544net/ipv4/af_inet.cwake_up_interruptible(sk->sleep);
sk547net/ipv4/af_inet.cstatic void def_callback2(struct sock *sk,int len)
sk549net/ipv4/af_inet.cif(!sk->dead)
sk551net/ipv4/af_inet.cwake_up_interruptible(sk->sleep);
sk552net/ipv4/af_inet.csock_wake_async(sk->socket, 1);
sk556net/ipv4/af_inet.cstatic void def_callback3(struct sock *sk)
sk558net/ipv4/af_inet.cif(!sk->dead)
sk560net/ipv4/af_inet.cwake_up_interruptible(sk->sleep);
sk561net/ipv4/af_inet.csock_wake_async(sk->socket, 2);
sk574net/ipv4/af_inet.cstruct sock *sk;
sk578net/ipv4/af_inet.csk = (struct sock *) kmalloc(sizeof(*sk), GFP_KERNEL);
sk579net/ipv4/af_inet.cif (sk == NULL) 
sk581net/ipv4/af_inet.cmemset(sk,0,sizeof(*sk));  /* Efficient way to set most fields to zero */
sk590net/ipv4/af_inet.ckfree_s((void *)sk, sizeof(*sk));
sk594net/ipv4/af_inet.csk->no_check = TCP_NO_CHECK;
sk601net/ipv4/af_inet.ckfree_s((void *)sk, sizeof(*sk));
sk605net/ipv4/af_inet.csk->no_check = UDP_NO_CHECK;
sk612net/ipv4/af_inet.ckfree_s((void *)sk, sizeof(*sk));
sk617net/ipv4/af_inet.ckfree_s((void *)sk, sizeof(*sk));
sk621net/ipv4/af_inet.csk->reuse = 1;
sk622net/ipv4/af_inet.csk->num = protocol;
sk628net/ipv4/af_inet.ckfree_s((void *)sk, sizeof(*sk));
sk633net/ipv4/af_inet.ckfree_s((void *)sk, sizeof(*sk));
sk637net/ipv4/af_inet.csk->reuse = 1;
sk638net/ipv4/af_inet.csk->num = protocol;
sk642net/ipv4/af_inet.ckfree_s((void *)sk, sizeof(*sk));
sk645net/ipv4/af_inet.csk->socket = sock;
sk647net/ipv4/af_inet.csk->nonagle = 1;
sk651net/ipv4/af_inet.csk->type = sock->type;
sk652net/ipv4/af_inet.csk->protocol = protocol;
sk653net/ipv4/af_inet.csk->allocation = GFP_KERNEL;
sk654net/ipv4/af_inet.csk->sndbuf = SK_WMEM_MAX;
sk655net/ipv4/af_inet.csk->rcvbuf = SK_RMEM_MAX;
sk656net/ipv4/af_inet.csk->rto = TCP_TIMEOUT_INIT;    /*TCP_WRITE_TIME*/
sk657net/ipv4/af_inet.csk->cong_window = 1; /* start with only sending one packet at a time. */
sk658net/ipv4/af_inet.csk->priority = 1;
sk659net/ipv4/af_inet.csk->state = TCP_CLOSE;
sk661net/ipv4/af_inet.csk->stamp.tv_sec=0;
sk662net/ipv4/af_inet.csk->wmem_alloc = 0;
sk663net/ipv4/af_inet.csk->rmem_alloc = 0;
sk664net/ipv4/af_inet.csk->pair = NULL;
sk665net/ipv4/af_inet.csk->opt = NULL;
sk666net/ipv4/af_inet.csk->write_seq = 0;
sk667net/ipv4/af_inet.csk->acked_seq = 0;
sk668net/ipv4/af_inet.csk->copied_seq = 0;
sk669net/ipv4/af_inet.csk->fin_seq = 0;
sk670net/ipv4/af_inet.csk->urg_seq = 0;
sk671net/ipv4/af_inet.csk->urg_data = 0;
sk672net/ipv4/af_inet.csk->proc = 0;
sk673net/ipv4/af_inet.csk->rtt = 0;        /*TCP_WRITE_TIME << 3;*/
sk674net/ipv4/af_inet.csk->mdev = 0;
sk675net/ipv4/af_inet.csk->backoff = 0;
sk676net/ipv4/af_inet.csk->packets_out = 0;
sk677net/ipv4/af_inet.csk->cong_count = 0;
sk678net/ipv4/af_inet.csk->ssthresh = 0;
sk679net/ipv4/af_inet.csk->max_window = 0;
sk680net/ipv4/af_inet.csk->urginline = 0;
sk681net/ipv4/af_inet.csk->intr = 0;
sk682net/ipv4/af_inet.csk->linger = 0;
sk683net/ipv4/af_inet.csk->destroy = 0;
sk684net/ipv4/af_inet.csk->shutdown = 0;
sk685net/ipv4/af_inet.csk->keepopen = 0;
sk686net/ipv4/af_inet.csk->zapped = 0;
sk687net/ipv4/af_inet.csk->done = 0;
sk688net/ipv4/af_inet.csk->ack_backlog = 0;
sk689net/ipv4/af_inet.csk->window = 0;
sk690net/ipv4/af_inet.csk->bytes_rcv = 0;
sk691net/ipv4/af_inet.csk->dead = 0;
sk692net/ipv4/af_inet.csk->ack_timed = 0;
sk693net/ipv4/af_inet.csk->partial = NULL;
sk694net/ipv4/af_inet.csk->user_mss = 0;
sk695net/ipv4/af_inet.csk->debug = 0;
sk698net/ipv4/af_inet.csk->max_ack_backlog = 0;
sk699net/ipv4/af_inet.csk->inuse = 0;
sk700net/ipv4/af_inet.csk->delay_acks = 0;
sk701net/ipv4/af_inet.csk->daddr = 0;
sk702net/ipv4/af_inet.csk->saddr = 0;
sk703net/ipv4/af_inet.csk->rcv_saddr = 0;
sk704net/ipv4/af_inet.csk->err = 0;
sk705net/ipv4/af_inet.csk->next = NULL;
sk706net/ipv4/af_inet.csk->pair = NULL;
sk707net/ipv4/af_inet.csk->send_tail = NULL;
sk708net/ipv4/af_inet.csk->send_head = NULL;
sk709net/ipv4/af_inet.csk->timeout = 0;
sk710net/ipv4/af_inet.csk->broadcast = 0;
sk711net/ipv4/af_inet.csk->localroute = 0;
sk712net/ipv4/af_inet.csk->blog = 0;
sk713net/ipv4/af_inet.csk->dummy_th.res1=0;
sk714net/ipv4/af_inet.csk->dummy_th.res2=0;
sk715net/ipv4/af_inet.csk->dummy_th.urg_ptr = 0;
sk716net/ipv4/af_inet.csk->dummy_th.fin = 0;
sk717net/ipv4/af_inet.csk->dummy_th.syn = 0;
sk718net/ipv4/af_inet.csk->dummy_th.rst = 0;
sk719net/ipv4/af_inet.csk->dummy_th.psh = 0;
sk720net/ipv4/af_inet.csk->dummy_th.ack = 0;
sk721net/ipv4/af_inet.csk->dummy_th.urg = 0;
sk722net/ipv4/af_inet.csk->dummy_th.dest = 0;
sk723net/ipv4/af_inet.csk->ip_tos=0;
sk724net/ipv4/af_inet.csk->ip_route_cache=NULL;
sk725net/ipv4/af_inet.csk->ip_hcache_ver= 0;
sk726net/ipv4/af_inet.csk->ip_option_len=0;
sk727net/ipv4/af_inet.csk->ip_option_flen=0;
sk728net/ipv4/af_inet.csk->ip_opt_next_hop=0;
sk729net/ipv4/af_inet.csk->ip_opt_ptr[0]=NULL;
sk730net/ipv4/af_inet.csk->ip_opt_ptr[1]=NULL;
sk734net/ipv4/af_inet.csk->max_unacked = 2048; /* needs to be at most 2 full packets. */
sk736net/ipv4/af_inet.cskb_queue_head_init(&sk->write_queue);
sk737net/ipv4/af_inet.cskb_queue_head_init(&sk->receive_queue);
sk738net/ipv4/af_inet.csk->mtu = 576;
sk739net/ipv4/af_inet.csk->prot = prot;
sk740net/ipv4/af_inet.csk->sleep = sock->wait;
sk741net/ipv4/af_inet.cinit_timer(&sk->timer);
sk742net/ipv4/af_inet.cinit_timer(&sk->retransmit_timer);
sk743net/ipv4/af_inet.csk->timer.data = (unsigned long)sk;
sk744net/ipv4/af_inet.csk->timer.function = &net_timer;
sk745net/ipv4/af_inet.cskb_queue_head_init(&sk->back_log);
sk746net/ipv4/af_inet.csock->data =(void *) sk;
sk747net/ipv4/af_inet.csk->dummy_th.doff = sizeof(sk->dummy_th)/4;
sk748net/ipv4/af_inet.csk->ip_ttl=64;
sk749net/ipv4/af_inet.cif(sk->type==SOCK_RAW && protocol==IPPROTO_RAW)
sk750net/ipv4/af_inet.csk->ip_hdrincl=1;
sk752net/ipv4/af_inet.csk->ip_hdrincl=0;
sk754net/ipv4/af_inet.csk->ip_mc_loop=1;
sk755net/ipv4/af_inet.csk->ip_mc_ttl=1;
sk756net/ipv4/af_inet.c*sk->ip_mc_name=0;
sk757net/ipv4/af_inet.csk->ip_mc_list=NULL;
sk760net/ipv4/af_inet.csk->state_change = def_callback1;
sk761net/ipv4/af_inet.csk->data_ready = def_callback2;
sk762net/ipv4/af_inet.csk->write_space = def_callback3;
sk763net/ipv4/af_inet.csk->error_report = def_callback1;
sk765net/ipv4/af_inet.cif (sk->num) 
sk773net/ipv4/af_inet.cput_sock(sk->num, sk);
sk774net/ipv4/af_inet.csk->dummy_th.source = ntohs(sk->num);
sk777net/ipv4/af_inet.cif (sk->prot->init) 
sk779net/ipv4/af_inet.cerr = sk->prot->init(sk);
sk782net/ipv4/af_inet.cdestroy_sock(sk);
sk803net/ipv4/af_inet.cstatic inline int closing(struct sock * sk)
sk805net/ipv4/af_inet.cswitch (sk->state) {
sk823net/ipv4/af_inet.cstruct sock *sk = (struct sock *) sock->data;
sk824net/ipv4/af_inet.cif (sk == NULL) 
sk827net/ipv4/af_inet.csk->state_change(sk);
sk833net/ipv4/af_inet.cip_mc_drop_socket(sk);
sk844net/ipv4/af_inet.cif (sk->linger == 0 || (current->flags & PF_EXITING))
sk846net/ipv4/af_inet.csk->prot->close(sk,0);
sk847net/ipv4/af_inet.csk->dead = 1;
sk851net/ipv4/af_inet.csk->prot->close(sk, 0);
sk853net/ipv4/af_inet.cif (sk->lingertime)
sk854net/ipv4/af_inet.ccurrent->timeout = jiffies + HZ*sk->lingertime;
sk855net/ipv4/af_inet.cwhile(closing(sk) && current->timeout>0) 
sk857net/ipv4/af_inet.cinterruptible_sleep_on(sk->sleep);
sk871net/ipv4/af_inet.csk->dead = 1;
sk873net/ipv4/af_inet.csk->inuse = 1;
sk882net/ipv4/af_inet.crelease_sock(sk);
sk884net/ipv4/af_inet.csk->socket = NULL;
sk893net/ipv4/af_inet.cstruct sock *sk=(struct sock *)sock->data, *sk2;
sk898net/ipv4/af_inet.cif (sk->state != TCP_CLOSE)
sk905net/ipv4/af_inet.cif (sk->num != 0) 
sk919net/ipv4/af_inet.csnum = get_new_socknum(sk->prot, 0);
sk938net/ipv4/af_inet.csk->rcv_saddr = addr->sin_addr.s_addr;
sk940net/ipv4/af_inet.csk->saddr = 0;  /* Use device */
sk942net/ipv4/af_inet.csk->saddr = addr->sin_addr.s_addr;
sk948net/ipv4/af_inet.cfor(sk2 = sk->prot->sock_array[snum & (SOCK_ARRAY_SIZE -1)];
sk954net/ipv4/af_inet.cif (!sk->reuse)
sk962net/ipv4/af_inet.cif (sk2->rcv_saddr != sk->rcv_saddr) 
sk972net/ipv4/af_inet.cremove_sock(sk);
sk977net/ipv4/af_inet.cput_sock(snum, sk);
sk978net/ipv4/af_inet.csk->dummy_th.source = ntohs(sk->num);
sk979net/ipv4/af_inet.csk->daddr = 0;
sk980net/ipv4/af_inet.csk->dummy_th.dest = 0;
sk982net/ipv4/af_inet.csk->ip_route_cache=NULL;
sk990net/ipv4/af_inet.cstatic int inet_error(struct sock *sk)
sk996net/ipv4/af_inet.cerr=sk->err;
sk997net/ipv4/af_inet.csk->err=0;
sk1010net/ipv4/af_inet.cstruct sock *sk=(struct sock *)sock->data;
sk1014net/ipv4/af_inet.cif (sock->state == SS_CONNECTING && tcp_connected(sk->state))
sk1021net/ipv4/af_inet.cif (sock->state == SS_CONNECTING && sk->protocol == IPPROTO_TCP && (flags & O_NONBLOCK))
sk1023net/ipv4/af_inet.cif(sk->err!=0)
sk1024net/ipv4/af_inet.creturn inet_error(sk);
sk1030net/ipv4/af_inet.cif(inet_autobind(sk)!=0)
sk1032net/ipv4/af_inet.cif (sk->prot->connect == NULL) 
sk1034net/ipv4/af_inet.cerr = sk->prot->connect(sk, (struct sockaddr_in *)uaddr, addr_len);
sk1040net/ipv4/af_inet.cif (sk->state > TCP_FIN_WAIT2 && sock->state==SS_CONNECTING)
sk1043net/ipv4/af_inet.creturn inet_error(sk);
sk1046net/ipv4/af_inet.cif (sk->state != TCP_ESTABLISHED &&(flags & O_NONBLOCK)) 
sk1050net/ipv4/af_inet.cwhile(sk->state == TCP_SYN_SENT || sk->state == TCP_SYN_RECV) 
sk1052net/ipv4/af_inet.cinterruptible_sleep_on(sk->sleep);
sk1060net/ipv4/af_inet.cif(sk->err && sk->protocol == IPPROTO_TCP)
sk1064net/ipv4/af_inet.creturn inet_error(sk); /* set by tcp_err() */
sk1070net/ipv4/af_inet.cif (sk->state != TCP_ESTABLISHED && sk->err) 
sk1073net/ipv4/af_inet.creturn inet_error(sk);
sk1103net/ipv4/af_inet.cstruct sock *sk=(struct sock *)newsock->data;
sk1105net/ipv4/af_inet.csk->dead = 1;
sk1106net/ipv4/af_inet.cdestroy_sock(sk);
sk1170net/ipv4/af_inet.cstruct sock *sk;
sk1173net/ipv4/af_inet.csk = (struct sock *) sock->data;
sk1176net/ipv4/af_inet.cif (!tcp_connected(sk->state)) 
sk1178net/ipv4/af_inet.csin->sin_port = sk->dummy_th.dest;
sk1179net/ipv4/af_inet.csin->sin_addr.s_addr = sk->daddr;
sk1183net/ipv4/af_inet.c__u32 addr = sk->rcv_saddr;
sk1185net/ipv4/af_inet.caddr = sk->saddr;
sk1189net/ipv4/af_inet.csin->sin_port = sk->dummy_th.source;
sk1204net/ipv4/af_inet.cstruct sock *sk = (struct sock *) sock->data;
sk1206net/ipv4/af_inet.cif (sk->prot->recvfrom == NULL) 
sk1208net/ipv4/af_inet.cif(sk->err)
sk1209net/ipv4/af_inet.creturn inet_error(sk);
sk1211net/ipv4/af_inet.cif(inet_autobind(sk)!=0)
sk1213net/ipv4/af_inet.creturn(sk->prot->recvfrom(sk, (unsigned char *) ubuf, size, noblock, flags,
sk1220net/ipv4/af_inet.cstruct sock *sk = (struct sock *) sock->data;
sk1222net/ipv4/af_inet.cif (sk->prot->recvmsg == NULL) 
sk1224net/ipv4/af_inet.cif(sk->err)
sk1225net/ipv4/af_inet.creturn inet_error(sk);
sk1227net/ipv4/af_inet.cif(inet_autobind(sk)!=0)
sk1229net/ipv4/af_inet.creturn(sk->prot->recvmsg(sk, ubuf, size, noblock, flags,addr_len));
sk1242net/ipv4/af_inet.cstruct sock *sk = (struct sock *) sock->data;
sk1244net/ipv4/af_inet.cif(sk->err)
sk1245net/ipv4/af_inet.creturn inet_error(sk);
sk1247net/ipv4/af_inet.cif(inet_autobind(sk))
sk1249net/ipv4/af_inet.creturn(sk->prot->read(sk, (unsigned char *) ubuf, size, noblock, 0));
sk1255net/ipv4/af_inet.cstruct sock *sk = (struct sock *) sock->data;
sk1256net/ipv4/af_inet.cif (sk->shutdown & SEND_SHUTDOWN) 
sk1261net/ipv4/af_inet.cif(sk->err)
sk1262net/ipv4/af_inet.creturn inet_error(sk);
sk1264net/ipv4/af_inet.cif(inet_autobind(sk)!=0)
sk1266net/ipv4/af_inet.creturn(sk->prot->write(sk, (const unsigned char *) ubuf, size, noblock, flags));
sk1277net/ipv4/af_inet.cstruct sock *sk = (struct sock *) sock->data;
sk1278net/ipv4/af_inet.cif (sk->shutdown & SEND_SHUTDOWN) 
sk1283net/ipv4/af_inet.cif (sk->prot->sendto == NULL) 
sk1285net/ipv4/af_inet.cif(sk->err)
sk1286net/ipv4/af_inet.creturn inet_error(sk);
sk1288net/ipv4/af_inet.cif(inet_autobind(sk)!=0)
sk1290net/ipv4/af_inet.creturn(sk->prot->sendto(sk, (const unsigned char *) ubuf, size, noblock, flags, 
sk1297net/ipv4/af_inet.cstruct sock *sk = (struct sock *) sock->data;
sk1298net/ipv4/af_inet.cif (sk->shutdown & SEND_SHUTDOWN) 
sk1303net/ipv4/af_inet.cif (sk->prot->sendmsg == NULL) 
sk1305net/ipv4/af_inet.cif(sk->err)
sk1306net/ipv4/af_inet.creturn inet_error(sk);
sk1308net/ipv4/af_inet.cif(inet_autobind(sk)!=0)
sk1310net/ipv4/af_inet.creturn(sk->prot->sendmsg(sk, msg, size, noblock, flags));
sk1317net/ipv4/af_inet.cstruct sock *sk=(struct sock*)sock->data;
sk1328net/ipv4/af_inet.cif (sock->state == SS_CONNECTING && sk->state == TCP_ESTABLISHED)
sk1330net/ipv4/af_inet.cif (!tcp_connected(sk->state)) 
sk1332net/ipv4/af_inet.csk->shutdown |= how;
sk1333net/ipv4/af_inet.cif (sk->prot->shutdown)
sk1334net/ipv4/af_inet.csk->prot->shutdown(sk, how);
sk1341net/ipv4/af_inet.cstruct sock *sk=(struct sock *) sock->data;
sk1342net/ipv4/af_inet.cif (sk->prot->select == NULL) 
sk1346net/ipv4/af_inet.creturn(sk->prot->select(sk, sel_type, wait));
sk1361net/ipv4/af_inet.cstruct sock *sk=(struct sock *)sock->data;
sk1376net/ipv4/af_inet.csk->proc = pid;
sk1383net/ipv4/af_inet.cput_fs_long(sk->proc,(int *)arg);
sk1386net/ipv4/af_inet.cif(sk->stamp.tv_sec==0)
sk1391net/ipv4/af_inet.cmemcpy_tofs((void *)arg,&sk->stamp,sizeof(struct timeval));
sk1439net/ipv4/af_inet.cif (sk->prot->ioctl==NULL) 
sk1441net/ipv4/af_inet.creturn(sk->prot->ioctl(sk, cmd, arg));
sk1520net/ipv4/af_inet.cstruct sock *get_sock_raw(struct sock *sk, 
sk1527net/ipv4/af_inet.cs=sk;
sk1549net/ipv4/af_inet.cstruct sock *get_sock_mcast(struct sock *sk, 
sk1568net/ipv4/af_inet.cs=sk;
sk532net/ipv4/arp.cif(skb->sk==NULL)
sk535net/ipv4/arp.cdev_queue_xmit(skb,skb->dev,skb->sk->priority);
sk233net/ipv4/icmp.cstruct sock *sk=icmp_socket.data;
sk237net/ipv4/icmp.cip_build_xmit(sk, icmp_glue_bits, icmp_param, 
sk711net/ipv4/icmp.cstruct sock *sk;
sk717net/ipv4/icmp.csk=icmp_socket.data;
sk718net/ipv4/icmp.csk->allocation=GFP_ATOMIC;
sk719net/ipv4/icmp.csk->num = 256;      /* Don't receive any data */
sk346net/ipv4/igmp.cint ip_mc_join_group(struct sock *sk , struct device *dev, unsigned long addr)
sk354net/ipv4/igmp.cif(sk->ip_mc_list==NULL)
sk356net/ipv4/igmp.cif((sk->ip_mc_list=(struct ip_mc_socklist *)kmalloc(sizeof(*sk->ip_mc_list), GFP_KERNEL))==NULL)
sk358net/ipv4/igmp.cmemset(sk->ip_mc_list,'\0',sizeof(*sk->ip_mc_list));
sk362net/ipv4/igmp.cif(sk->ip_mc_list->multiaddr[i]==addr && sk->ip_mc_list->multidev[i]==dev)
sk364net/ipv4/igmp.cif(sk->ip_mc_list->multidev[i]==NULL)
sk370net/ipv4/igmp.csk->ip_mc_list->multiaddr[unused]=addr;
sk371net/ipv4/igmp.csk->ip_mc_list->multidev[unused]=dev;
sk380net/ipv4/igmp.cint ip_mc_leave_group(struct sock *sk, struct device *dev, unsigned long addr)
sk387net/ipv4/igmp.cif(sk->ip_mc_list==NULL)
sk392net/ipv4/igmp.cif(sk->ip_mc_list->multiaddr[i]==addr && sk->ip_mc_list->multidev[i]==dev)
sk394net/ipv4/igmp.csk->ip_mc_list->multidev[i]=NULL;
sk406net/ipv4/igmp.cvoid ip_mc_drop_socket(struct sock *sk)
sk410net/ipv4/igmp.cif(sk->ip_mc_list==NULL)
sk415net/ipv4/igmp.cif(sk->ip_mc_list->multidev[i])
sk417net/ipv4/igmp.cip_mc_dec_group(sk->ip_mc_list->multidev[i], sk->ip_mc_list->multiaddr[i]);
sk418net/ipv4/igmp.csk->ip_mc_list->multidev[i]=NULL;
sk421net/ipv4/igmp.ckfree_s(sk->ip_mc_list,sizeof(*sk->ip_mc_list));
sk422net/ipv4/igmp.csk->ip_mc_list=NULL;
sk477net/ipv4/ip_fragment.cskb->sk = NULL;
sk578net/ipv4/ip_fragment.cskb->sk = NULL;
sk619net/ipv4/ip_fragment.cvoid ip_fragment(struct sock *sk, struct sk_buff *skb, struct device *dev, int is_frag)
sk735net/ipv4/ip_fragment.cif (sk)
sk738net/ipv4/ip_fragment.csk->wmem_alloc += skb2->truesize;
sk739net/ipv4/ip_fragment.cskb2->sk=sk;
sk789net/ipv4/ip_fragment.cip_queue_xmit(sk, dev, skb2, 2);
sk874net/ipv4/ip_fw.ctcp_send_check(th,iph->saddr,iph->daddr,size,skb->sk);
sk979net/ipv4/ip_fw.ctcp_send_check((struct tcphdr *)portptr,iph->saddr,iph->daddr,size,skb_ptr->sk);
sk156net/ipv4/ip_input.cextern void sort_send(struct sock *sk);
sk176net/ipv4/ip_input.cint ip_ioctl(struct sock *sk, int cmd, unsigned long arg)
sk76net/ipv4/ip_output.cnewskb->sk=NULL;
sk183net/ipv4/ip_output.cif(MULTICAST(daddr) && *dev==NULL && skb->sk && *skb->sk->ip_mc_name)
sk184net/ipv4/ip_output.c*dev=dev_get(skb->sk->ip_mc_name);
sk318net/ipv4/ip_output.cvoid ip_queue_xmit(struct sock *sk, struct device *dev,
sk368net/ipv4/ip_output.cif (sk == NULL)
sk381net/ipv4/ip_output.cip_fragment(sk,skb,dev,0);
sk419net/ipv4/ip_output.csk->packets_out++;
sk430net/ipv4/ip_output.cif (sk->send_head == NULL)
sk432net/ipv4/ip_output.csk->send_tail = skb;
sk433net/ipv4/ip_output.csk->send_head = skb;
sk437net/ipv4/ip_output.csk->send_tail->link3 = skb;
sk438net/ipv4/ip_output.csk->send_tail = skb;
sk447net/ipv4/ip_output.cskb->sk = sk;
sk466net/ipv4/ip_output.cif(sk==NULL || sk->ip_mc_loop)
sk505net/ipv4/ip_output.cif (sk != NULL)
sk507net/ipv4/ip_output.cdev_queue_xmit(skb, dev, sk->priority);
sk516net/ipv4/ip_output.cif(sk)
sk517net/ipv4/ip_output.csk->err = ENETDOWN;
sk545net/ipv4/ip_output.cint ip_build_xmit(struct sock *sk,
sk571net/ipv4/ip_output.cif (opt && opt->srr && !sk->ip_hdrincl)
sk577net/ipv4/ip_output.cif(sk && MULTICAST(daddr) && *sk->ip_mc_name)
sk579net/ipv4/ip_output.cdev=dev_get(sk->ip_mc_name);
sk583net/ipv4/ip_output.cif (sk->saddr && (!LOOPBACK(sk->saddr) || LOOPBACK(daddr)))
sk584net/ipv4/ip_output.csaddr = sk->saddr;
sk595net/ipv4/ip_output.cif(sk->localroute || flags&MSG_DONTROUTE)
sk598net/ipv4/ip_output.crt = sk->ip_route_cache;
sk605net/ipv4/ip_output.csaddr=sk->ip_route_saddr;   
sk606net/ipv4/ip_output.cif(!rt || sk->ip_route_stamp != rt_stamp ||
sk607net/ipv4/ip_output.cdaddr!=sk->ip_route_daddr || sk->ip_route_local!=local ||
sk608net/ipv4/ip_output.c(sk->saddr && sk->saddr != saddr))
sk614net/ipv4/ip_output.csk->ip_route_local=local;
sk615net/ipv4/ip_output.csk->ip_route_daddr=daddr;
sk616net/ipv4/ip_output.csk->ip_route_saddr=saddr;
sk617net/ipv4/ip_output.csk->ip_route_stamp=rt_stamp;
sk618net/ipv4/ip_output.csk->ip_route_cache=rt;
sk619net/ipv4/ip_output.csk->ip_hcache_ver=NULL;
sk620net/ipv4/ip_output.csk->ip_hcache_state= 0;
sk630net/ipv4/ip_output.cif(rt->rt_dev->header_cache && sk->ip_hcache_state!= -1)
sk632net/ipv4/ip_output.cif(sk->ip_hcache_ver==NULL || sk->ip_hcache_stamp!=*sk->ip_hcache_ver)
sk633net/ipv4/ip_output.crt->rt_dev->header_cache(rt->rt_dev,sk,saddr,daddr);
sk636net/ipv4/ip_output.csk->ip_hcache_state= -1;
sk646net/ipv4/ip_output.cif (sk->saddr && (!LOOPBACK(sk->saddr) || LOOPBACK(daddr)))
sk647net/ipv4/ip_output.csaddr = sk->saddr;
sk666net/ipv4/ip_output.cif (!sk->ip_hdrincl && opt) 
sk678net/ipv4/ip_output.cstruct sk_buff *skb=sock_alloc_send_skb(sk, length+15+dev->hard_header_len,0, noblock, &error);
sk687net/ipv4/ip_output.cskb->sk=sk;
sk692net/ipv4/ip_output.cif(sk->ip_hcache_state>0)
sk694net/ipv4/ip_output.cmemcpy(skb_push(skb,dev->hard_header_len),sk->ip_hcache_data,dev->hard_header_len);
sk706net/ipv4/ip_output.cif(!sk->ip_hdrincl)
sk710net/ipv4/ip_output.ciph->tos=sk->ip_tos;
sk714net/ipv4/ip_output.ciph->ttl=sk->ip_ttl;
sk742net/ipv4/ip_output.cdev_queue_xmit(skb,dev,sk->priority);
sk751net/ipv4/ip_output.cif (sk && !sk->ip_hdrincl && opt) 
sk760net/ipv4/ip_output.cif(!sk->ip_hdrincl)
sk800net/ipv4/ip_output.cif (sk->ip_hdrincl && offset > 0)
sk829net/ipv4/ip_output.cskb = sock_alloc_send_skb(sk, fraglen+15, 0, noblock, &error);
sk847net/ipv4/ip_output.cskb->sk = sk;
sk861net/ipv4/ip_output.cif(sk->ip_hcache_state>0)
sk863net/ipv4/ip_output.cmemcpy(skb_push(skb,dev->hard_header_len),sk->ip_hcache_data, dev->hard_header_len);
sk883net/ipv4/ip_output.cif(!sk->ip_hdrincl) 
sk893net/ipv4/ip_output.ciph->tos = sk->ip_tos;
sk900net/ipv4/ip_output.ciph->ttl = sk->ip_mc_ttl;
sk903net/ipv4/ip_output.ciph->ttl = sk->ip_ttl;
sk958net/ipv4/ip_output.cif(sk==NULL || sk->ip_mc_loop)
sk1002net/ipv4/ip_output.cdev_queue_xmit(skb, dev, sk->priority);
sk1018net/ipv4/ip_output.cif(sk!=NULL)
sk1019net/ipv4/ip_output.csk->err=ENETDOWN;
sk111net/ipv4/ip_sockglue.cint ip_setsockopt(struct sock *sk, int level, int optname, char *optval, int optlen)
sk137net/ipv4/ip_sockglue.creturn ip_mroute_setsockopt(sk,optname,optval,optlen);
sk173net/ipv4/ip_sockglue.cold_opt = sk->opt;
sk174net/ipv4/ip_sockglue.csk->opt = opt;
sk183net/ipv4/ip_sockglue.csk->ip_tos=val;
sk185net/ipv4/ip_sockglue.csk->priority=SOPRI_INTERACTIVE;
sk187net/ipv4/ip_sockglue.csk->priority=SOPRI_BACKGROUND;
sk192net/ipv4/ip_sockglue.csk->ip_ttl=val;
sk195net/ipv4/ip_sockglue.cif(sk->type!=SOCK_RAW)
sk197net/ipv4/ip_sockglue.csk->ip_hdrincl=val?1:0;
sk202net/ipv4/ip_sockglue.csk->ip_mc_ttl=(int)ucval;
sk209net/ipv4/ip_sockglue.csk->ip_mc_loop=(int)ucval;
sk234net/ipv4/ip_sockglue.csk->ip_mc_name[0]=0;
sk250net/ipv4/ip_sockglue.cstrcpy(sk->ip_mc_name,dev->name);
sk312net/ipv4/ip_sockglue.creturn ip_mc_join_group(sk,dev,mreq.imr_multiaddr.s_addr);
sk361net/ipv4/ip_sockglue.creturn ip_mc_leave_group(sk,dev,mreq.imr_multiaddr.s_addr);
sk416net/ipv4/ip_sockglue.cint ip_getsockopt(struct sock *sk, int level, int optname, char *optval, int *optlen)
sk429net/ipv4/ip_sockglue.creturn ip_mroute_getsockopt(sk,optname,optval,optlen);
sk444net/ipv4/ip_sockglue.cif (sk->opt)
sk445net/ipv4/ip_sockglue.cmemcpy(optbuf, sk->opt, sizeof(struct options)+sk->opt->optlen);
sk489net/ipv4/ip_sockglue.cval=sk->ip_tos;
sk492net/ipv4/ip_sockglue.cval=sk->ip_ttl;
sk495net/ipv4/ip_sockglue.cval=sk->ip_hdrincl;
sk499net/ipv4/ip_sockglue.cval=sk->ip_mc_ttl;
sk502net/ipv4/ip_sockglue.cval=sk->ip_mc_loop;
sk508net/ipv4/ip_sockglue.clen=strlen(sk->ip_mc_name);
sk513net/ipv4/ip_sockglue.cmemcpy_tofs((void *)optval,sk->ip_mc_name, len);
sk287net/ipv4/ipmr.cskb->sk=NULL;
sk427net/ipv4/ipmr.cint ip_mroute_setsockopt(struct sock *sk,int optname,char *optval,int optlen)
sk435net/ipv4/ipmr.cif(sk!=mroute_socket)
sk442net/ipv4/ipmr.cif(sk->type!=SOCK_RAW || sk->num!=IPPROTO_IGMP)
sk452net/ipv4/ipmr.cmroute_socket=sk;
sk456net/ipv4/ipmr.cmroute_close(sk);
sk568net/ipv4/ipmr.cint ip_mroute_getsockopt(struct sock *sk,int optname,char *optval,int *optlen)
sk573net/ipv4/ipmr.cif(sk!=mroute_socket)
sk596net/ipv4/ipmr.cint ipmr_ioctl(struct sock *sk, int cmd, unsigned long arg)
sk639net/ipv4/ipmr.cvoid mroute_close(struct sock *sk)
sk76net/ipv4/packet.cstruct sock *sk;
sk83net/ipv4/packet.csk = (struct sock *) pt->data;  
sk103net/ipv4/packet.cif(sock_queue_rcv_skb(sk,skb)<0)
sk105net/ipv4/packet.cskb->sk = NULL;
sk107net/ipv4/packet.crelease_sock(sk);    
sk123net/ipv4/packet.cstatic int packet_sendmsg(struct sock *sk, struct msghdr *msg, int len,
sk168net/ipv4/packet.cskb = sock_wmalloc(sk, len, 0, GFP_KERNEL);
sk185net/ipv4/packet.cskb->sk = sk;
sk195net/ipv4/packet.cdev_queue_xmit(skb, dev, sk->priority);
sk201net/ipv4/packet.cstatic int packet_sendto(struct sock *sk, const unsigned char *from, int len,
sk217net/ipv4/packet.creturn packet_sendmsg(sk, &msg, len, noblock, flags);
sk226net/ipv4/packet.cstatic int packet_write(struct sock *sk, const unsigned char *buff, 
sk229net/ipv4/packet.creturn(packet_sendto(sk, buff, len, noblock, flags, NULL, 0));
sk239net/ipv4/packet.cstatic void packet_close(struct sock *sk, int timeout)
sk241net/ipv4/packet.csk->inuse = 1;
sk242net/ipv4/packet.csk->state = TCP_CLOSE;
sk243net/ipv4/packet.cdev_remove_pack((struct packet_type *)sk->pair);
sk244net/ipv4/packet.ckfree_s((void *)sk->pair, sizeof(struct packet_type));
sk245net/ipv4/packet.csk->pair = NULL;
sk246net/ipv4/packet.crelease_sock(sk);
sk257net/ipv4/packet.cstatic int packet_init(struct sock *sk)
sk266net/ipv4/packet.cp->type = sk->num;
sk267net/ipv4/packet.cp->data = (void *)sk;
sk275net/ipv4/packet.csk->pair = (struct sock *)p;
sk286net/ipv4/packet.cint packet_recvmsg(struct sock *sk, struct msghdr *msg, int len,
sk294net/ipv4/packet.cif (sk->shutdown & RCV_SHUTDOWN) 
sk311net/ipv4/packet.cskb=skb_recv_datagram(sk,flags,noblock,&err);
sk330net/ipv4/packet.csk->stamp=skb->stamp;
sk353net/ipv4/packet.crelease_sock(sk);
sk357net/ipv4/packet.cstatic int packet_recvfrom(struct sock *sk, unsigned char *ubuf, int size, int noblock, unsigned flags,
sk374net/ipv4/packet.creturn packet_recvmsg(sk, &msg, size, noblock, flags, addr_len);
sk384net/ipv4/packet.cint packet_read(struct sock *sk, unsigned char *buff,
sk387net/ipv4/packet.creturn(packet_recvfrom(sk, buff, len, noblock, flags, NULL, NULL));
sk79net/ipv4/raw.cstruct sock *sk;
sk83net/ipv4/raw.csk = (struct sock *) protocol->data;
sk84net/ipv4/raw.cif (sk == NULL) 
sk90net/ipv4/raw.cif (sk->cong_window > 1) sk->cong_window = sk->cong_window/2;
sk96net/ipv4/raw.csk->err = EPROTO;
sk97net/ipv4/raw.csk->error_report(sk);
sk102net/ipv4/raw.csk->err = icmp_err_convert[code & 0xff].errno;
sk103net/ipv4/raw.csk->error_report(sk);
sk116net/ipv4/raw.cint raw_rcv(struct sock *sk, struct sk_buff *skb, struct device *dev, __u32 saddr, __u32 daddr)
sk119net/ipv4/raw.cskb->sk = sk;
sk129net/ipv4/raw.cif(sock_queue_rcv_skb(sk,skb)<0)
sk132net/ipv4/raw.cskb->sk=NULL;
sk138net/ipv4/raw.crelease_sock(sk);
sk178net/ipv4/raw.cstatic int raw_sendto(struct sock *sk, const unsigned char *from, 
sk207net/ipv4/raw.cif (sk->state != TCP_ESTABLISHED) 
sk210net/ipv4/raw.csin.sin_port = sk->protocol;
sk211net/ipv4/raw.csin.sin_addr.s_addr = sk->daddr;
sk214net/ipv4/raw.csin.sin_port = sk->protocol;
sk219net/ipv4/raw.cif (sk->broadcast == 0 && ip_chk_addr(sin.sin_addr.s_addr)==IS_BROADCAST)
sk222net/ipv4/raw.cif(sk->ip_hdrincl)
sk226net/ipv4/raw.cerr=ip_build_xmit(sk, raw_getrawfrag, from, len, sin.sin_addr.s_addr, 0, sk->opt, flags, sin.sin_port, noblock);
sk232net/ipv4/raw.cerr=ip_build_xmit(sk, raw_getfrag, from, len, sin.sin_addr.s_addr, 0, sk->opt, flags, sin.sin_port, noblock);
sk238net/ipv4/raw.cstatic int raw_write(struct sock *sk, const unsigned char *buff, int len, int noblock,
sk241net/ipv4/raw.creturn(raw_sendto(sk, buff, len, noblock, flags, NULL, 0));
sk245net/ipv4/raw.cstatic void raw_close(struct sock *sk, int timeout)
sk247net/ipv4/raw.csk->state = TCP_CLOSE;
sk249net/ipv4/raw.cif(sk==mroute_socket)
sk251net/ipv4/raw.cmroute_close(sk);
sk258net/ipv4/raw.cstatic int raw_init(struct sock *sk)
sk269net/ipv4/raw.cint raw_recvmsg(struct sock *sk, struct msghdr *msg, int len,
sk280net/ipv4/raw.cif (sk->shutdown & RCV_SHUTDOWN) 
sk286net/ipv4/raw.cskb=skb_recv_datagram(sk,flags,noblock,&err);
sk293net/ipv4/raw.csk->stamp=skb->stamp;
sk302net/ipv4/raw.crelease_sock(sk);
sk307net/ipv4/raw.cstatic int raw_recvfrom(struct sock *sk, unsigned char *ubuf, int size, int noblock, unsigned flags,
sk324net/ipv4/raw.creturn raw_recvmsg(sk, &msg, size, noblock, flags, addr_len);
sk327net/ipv4/raw.cint raw_read (struct sock *sk, unsigned char *buff, int len, int noblock, unsigned flags)
sk329net/ipv4/raw.creturn(raw_recvfrom(sk, buff, len, noblock, flags, NULL, NULL));
sk469net/ipv4/tcp.cstatic void tcp_close(struct sock *sk, int timeout);
sk495net/ipv4/tcp.cstatic __inline__ void tcp_set_state(struct sock *sk, int state)
sk497net/ipv4/tcp.cif(sk->state==TCP_ESTABLISHED)
sk500net/ipv4/tcp.cif(sk->debug)
sk501net/ipv4/tcp.cprintk("TCP sk=%p, State %s -> %s\n",sk, statename[sk->state],statename[state]);
sk506net/ipv4/tcp.cif(state==TCP_ESTABLISHED && sk->state==TCP_SYN_RECV)
sk510net/ipv4/tcp.csk->state=state;
sk513net/ipv4/tcp.cif(sk->state==TCP_CLOSE)
sk532net/ipv4/tcp.cint tcp_select_window(struct sock *sk)
sk534net/ipv4/tcp.cint new_window = sock_rspace(sk);
sk536net/ipv4/tcp.cif(sk->window_clamp)
sk537net/ipv4/tcp.cnew_window=min(sk->window_clamp,new_window);
sk551net/ipv4/tcp.cif (new_window < min(sk->mss, MAX_WINDOW/2) || new_window < sk->window)
sk552net/ipv4/tcp.creturn(sk->window);
sk568net/ipv4/tcp.cif(p->sk->state == TCP_ESTABLISHED || p->sk->state >= TCP_FIN_WAIT1)
sk600net/ipv4/tcp.cstatic void tcp_close_pending (struct sock *sk) 
sk604net/ipv4/tcp.cwhile ((skb = skb_dequeue(&sk->receive_queue)) != NULL) 
sk606net/ipv4/tcp.cskb->sk->dead=1;
sk607net/ipv4/tcp.ctcp_close(skb->sk, 0);
sk617net/ipv4/tcp.cstatic void tcp_time_wait(struct sock *sk)
sk619net/ipv4/tcp.ctcp_set_state(sk,TCP_TIME_WAIT);
sk620net/ipv4/tcp.csk->shutdown = SHUTDOWN_MASK;
sk621net/ipv4/tcp.cif (!sk->dead)
sk622net/ipv4/tcp.csk->state_change(sk);
sk623net/ipv4/tcp.creset_msl_timer(sk, TIME_CLOSE, TCP_TIMEWAIT_LEN);
sk631net/ipv4/tcp.cvoid tcp_do_retransmit(struct sock *sk, int all)
sk639net/ipv4/tcp.cprot = sk->prot;
sk640net/ipv4/tcp.cskb = sk->send_head;
sk690net/ipv4/tcp.cif(skb->sk)
sk692net/ipv4/tcp.cskb->sk->err=ENETUNREACH;
sk693net/ipv4/tcp.cskb->sk->error_report(skb->sk);
sk721net/ipv4/tcp.cth->ack_seq = ntohl(sk->acked_seq);
sk722net/ipv4/tcp.cth->window = ntohs(tcp_select_window(sk));
sk723net/ipv4/tcp.ctcp_send_check(th, sk->saddr, sk->daddr, size, sk);
sk739net/ipv4/tcp.cif (sk && !skb_device_locked(skb))
sk745net/ipv4/tcp.cdev_queue_xmit(skb, dev, sk->priority);
sk755net/ipv4/tcp.csk->prot->retransmits ++;
sk770net/ipv4/tcp.cif (ct >= sk->cong_window)
sk780net/ipv4/tcp.cstatic void reset_xmit_timer(struct sock *sk, int why, unsigned long when)
sk782net/ipv4/tcp.cdel_timer(&sk->retransmit_timer);
sk783net/ipv4/tcp.csk->ip_xmit_timeout = why;
sk789net/ipv4/tcp.csk->retransmit_timer.expires=jiffies+when;
sk790net/ipv4/tcp.cadd_timer(&sk->retransmit_timer);
sk801net/ipv4/tcp.cvoid tcp_retransmit_time(struct sock *sk, int all)
sk803net/ipv4/tcp.ctcp_do_retransmit(sk, all);
sk822net/ipv4/tcp.csk->retransmits++;
sk823net/ipv4/tcp.csk->prot->retransmits++;
sk824net/ipv4/tcp.csk->backoff++;
sk825net/ipv4/tcp.csk->rto = min(sk->rto << 1, 120*HZ);
sk826net/ipv4/tcp.creset_xmit_timer(sk, TIME_WRITE, sk->rto);
sk837net/ipv4/tcp.cstatic void tcp_retransmit(struct sock *sk, int all)
sk841net/ipv4/tcp.ctcp_retransmit_time(sk, all);
sk845net/ipv4/tcp.csk->ssthresh = sk->cong_window >> 1; /* remember window where we lost */
sk847net/ipv4/tcp.csk->cong_count = 0;
sk849net/ipv4/tcp.csk->cong_window = 1;
sk852net/ipv4/tcp.ctcp_retransmit_time(sk, all);
sk859net/ipv4/tcp.cstatic int tcp_write_timeout(struct sock *sk)
sk864net/ipv4/tcp.cif ((sk->state == TCP_ESTABLISHED && sk->retransmits && !(sk->retransmits & 7))
sk865net/ipv4/tcp.c|| (sk->state != TCP_ESTABLISHED && sk->retransmits > TCP_RETR1)) 
sk871net/ipv4/tcp.carp_destroy (sk->daddr, 0);
sk879net/ipv4/tcp.cif(sk->retransmits > TCP_SYN_RETRIES && sk->state==TCP_SYN_SENT)
sk881net/ipv4/tcp.csk->err=ETIMEDOUT;
sk882net/ipv4/tcp.csk->error_report(sk);
sk883net/ipv4/tcp.cdel_timer(&sk->retransmit_timer);
sk885net/ipv4/tcp.ctcp_set_state(sk,TCP_CLOSE);
sk887net/ipv4/tcp.crelease_sock(sk);
sk893net/ipv4/tcp.cif (sk->retransmits > TCP_RETR2) 
sk895net/ipv4/tcp.csk->err = ETIMEDOUT;
sk896net/ipv4/tcp.csk->error_report(sk);
sk897net/ipv4/tcp.cdel_timer(&sk->retransmit_timer);
sk901net/ipv4/tcp.cif (sk->state == TCP_FIN_WAIT1 || sk->state == TCP_FIN_WAIT2 || sk->state == TCP_CLOSING ) 
sk903net/ipv4/tcp.ctcp_set_state(sk,TCP_TIME_WAIT);
sk904net/ipv4/tcp.creset_msl_timer (sk, TIME_CLOSE, TCP_TIMEWAIT_LEN);
sk911net/ipv4/tcp.ctcp_set_state(sk, TCP_CLOSE);
sk912net/ipv4/tcp.crelease_sock(sk);
sk931net/ipv4/tcp.cstruct sock *sk = (struct sock*)data;
sk932net/ipv4/tcp.cint why = sk->ip_xmit_timeout;
sk939net/ipv4/tcp.cif (sk->inuse || in_bh) 
sk942net/ipv4/tcp.csk->retransmit_timer.expires = jiffies+HZ;
sk943net/ipv4/tcp.cadd_timer(&sk->retransmit_timer);
sk948net/ipv4/tcp.csk->inuse = 1;
sk953net/ipv4/tcp.cif (sk->ack_backlog && !sk->zapped) 
sk955net/ipv4/tcp.csk->prot->read_wakeup (sk);
sk956net/ipv4/tcp.cif (! sk->dead)
sk957net/ipv4/tcp.csk->data_ready(sk,0);
sk966net/ipv4/tcp.ctcp_send_probe0(sk);
sk967net/ipv4/tcp.ctcp_write_timeout(sk);
sk980net/ipv4/tcp.cskb = sk->send_head;
sk991net/ipv4/tcp.cif (jiffies < skb->when + sk->rto) 
sk993net/ipv4/tcp.creset_xmit_timer (sk, TIME_WRITE, skb->when + sk->rto - jiffies);
sk1001net/ipv4/tcp.csk->retransmits++;
sk1002net/ipv4/tcp.csk->prot->retransmits++;
sk1003net/ipv4/tcp.csk->prot->retransmit (sk, 0);
sk1004net/ipv4/tcp.ctcp_write_timeout(sk);
sk1014net/ipv4/tcp.creset_xmit_timer (sk, TIME_KEEPOPEN, TCP_TIMEOUT_LEN);
sk1017net/ipv4/tcp.cif (sk->prot->write_wakeup)
sk1018net/ipv4/tcp.csk->prot->write_wakeup (sk);
sk1019net/ipv4/tcp.csk->retransmits++;
sk1020net/ipv4/tcp.csk->prot->retransmits++;
sk1021net/ipv4/tcp.ctcp_write_timeout(sk);
sk1027net/ipv4/tcp.crelease_sock(sk);
sk1043net/ipv4/tcp.cstruct sock *sk;
sk1050net/ipv4/tcp.csk = get_sock(&tcp_prot, th->source, daddr, th->dest, saddr);
sk1052net/ipv4/tcp.cif (sk == NULL) 
sk1062net/ipv4/tcp.cif (sk->cong_window > 4)
sk1063net/ipv4/tcp.csk->cong_window--;
sk1069net/ipv4/tcp.csk->err=EPROTO;
sk1070net/ipv4/tcp.csk->error_report(sk);
sk1078net/ipv4/tcp.cif (code < 13 && (icmp_err_convert[code].fatal || sk->state == TCP_SYN_SENT || sk->state == TCP_SYN_RECV))
sk1080net/ipv4/tcp.csk->err = icmp_err_convert[code].errno;
sk1081net/ipv4/tcp.cif (sk->state == TCP_SYN_SENT || sk->state == TCP_SYN_RECV) 
sk1084net/ipv4/tcp.ctcp_set_state(sk,TCP_CLOSE);
sk1085net/ipv4/tcp.csk->error_report(sk);    /* Wake people up to see the error (see connect in sock.c) */
sk1098net/ipv4/tcp.cstatic int tcp_readable(struct sock *sk)
sk1106net/ipv4/tcp.cif(sk && sk->debug)
sk1107net/ipv4/tcp.cprintk("tcp_readable: %p - ",sk);
sk1111net/ipv4/tcp.cif (sk == NULL || (skb = skb_peek(&sk->receive_queue)) == NULL)
sk1114net/ipv4/tcp.cif(sk && sk->debug) 
sk1119net/ipv4/tcp.ccounted = sk->copied_seq;  /* Where we are at the moment */
sk1161net/ipv4/tcp.cwhile(skb != (struct sk_buff *)&sk->receive_queue);
sk1164net/ipv4/tcp.cif(sk->debug)
sk1172net/ipv4/tcp.cstatic int tcp_listen_select(struct sock *sk, int sel_type, select_table *wait)
sk1177net/ipv4/tcp.csk->inuse = 1;
sk1178net/ipv4/tcp.cretval = (tcp_find_established(sk) != NULL);
sk1179net/ipv4/tcp.crelease_sock(sk);
sk1195net/ipv4/tcp.cstatic int tcp_select(struct sock *sk, int sel_type, select_table *wait)
sk1197net/ipv4/tcp.cif (sk->state == TCP_LISTEN)
sk1198net/ipv4/tcp.creturn tcp_listen_select(sk, sel_type, wait);
sk1202net/ipv4/tcp.cif (sk->err)
sk1204net/ipv4/tcp.cif (sk->state == TCP_SYN_SENT || sk->state == TCP_SYN_RECV)
sk1207net/ipv4/tcp.cif (sk->shutdown & RCV_SHUTDOWN)
sk1210net/ipv4/tcp.cif (sk->acked_seq == sk->copied_seq)
sk1213net/ipv4/tcp.cif (sk->urg_seq != sk->copied_seq ||
sk1214net/ipv4/tcp.csk->acked_seq != sk->copied_seq+1 ||
sk1215net/ipv4/tcp.csk->urginline || !sk->urg_data)
sk1220net/ipv4/tcp.cif (sk->err)
sk1222net/ipv4/tcp.cif (sk->shutdown & SEND_SHUTDOWN) 
sk1224net/ipv4/tcp.cif (sk->state == TCP_SYN_SENT || sk->state == TCP_SYN_RECV)
sk1231net/ipv4/tcp.cif (sock_wspace(sk) < sk->mtu+128+sk->prot->max_header)
sk1236net/ipv4/tcp.cif (sk->urg_data)
sk1240net/ipv4/tcp.cselect_wait(sk->sleep, wait);
sk1244net/ipv4/tcp.cint tcp_ioctl(struct sock *sk, int cmd, unsigned long arg)
sk1257net/ipv4/tcp.cif (sk->state == TCP_LISTEN) 
sk1260net/ipv4/tcp.csk->inuse = 1;
sk1261net/ipv4/tcp.camount = tcp_readable(sk);
sk1262net/ipv4/tcp.crelease_sock(sk);
sk1271net/ipv4/tcp.cint answ = sk->urg_data && sk->urg_seq == sk->copied_seq;
sk1283net/ipv4/tcp.cif (sk->state == TCP_LISTEN) return(-EINVAL);
sk1284net/ipv4/tcp.camount = sock_wspace(sk);
sk1313net/ipv4/tcp.cunsigned long daddr, int len, struct sock *sk)
sk1326net/ipv4/tcp.cstatic void tcp_send_skb(struct sock *sk, struct sk_buff *skb)
sk1380net/ipv4/tcp.cif (after(skb->h.seq, sk->window_seq) ||
sk1381net/ipv4/tcp.c(sk->retransmits && sk->ip_xmit_timeout == TIME_WRITE) ||
sk1382net/ipv4/tcp.csk->packets_out >= sk->cong_window) 
sk1392net/ipv4/tcp.cskb_queue_tail(&sk->write_queue, skb);
sk1401net/ipv4/tcp.cif (before(sk->window_seq, sk->write_queue.next->h.seq) &&
sk1402net/ipv4/tcp.csk->send_head == NULL && sk->ack_backlog == 0)
sk1403net/ipv4/tcp.creset_xmit_timer(sk, TIME_PROBE0, sk->rto);
sk1411net/ipv4/tcp.cth->ack_seq = ntohl(sk->acked_seq);
sk1412net/ipv4/tcp.cth->window = ntohs(tcp_select_window(sk));
sk1414net/ipv4/tcp.ctcp_send_check(th, sk->saddr, sk->daddr, size, sk);
sk1416net/ipv4/tcp.csk->sent_seq = sk->write_seq;
sk1424net/ipv4/tcp.csk->prot->queue_xmit(sk, skb->dev, skb, 0);
sk1432net/ipv4/tcp.creset_xmit_timer(sk, TIME_WRITE, sk->rto);
sk1445net/ipv4/tcp.cstruct sk_buff * tcp_dequeue_partial(struct sock * sk)
sk1452net/ipv4/tcp.cskb = sk->partial;
sk1454net/ipv4/tcp.csk->partial = NULL;
sk1455net/ipv4/tcp.cdel_timer(&sk->partial_timer);
sk1465net/ipv4/tcp.cstatic void tcp_send_partial(struct sock *sk)
sk1469net/ipv4/tcp.cif (sk == NULL)
sk1471net/ipv4/tcp.cwhile ((skb = tcp_dequeue_partial(sk)) != NULL)
sk1472net/ipv4/tcp.ctcp_send_skb(sk, skb);
sk1479net/ipv4/tcp.cvoid tcp_enqueue_partial(struct sk_buff * skb, struct sock * sk)
sk1486net/ipv4/tcp.ctmp = sk->partial;
sk1488net/ipv4/tcp.cdel_timer(&sk->partial_timer);
sk1489net/ipv4/tcp.csk->partial = skb;
sk1490net/ipv4/tcp.cinit_timer(&sk->partial_timer);
sk1494net/ipv4/tcp.csk->partial_timer.expires = jiffies+HZ;
sk1495net/ipv4/tcp.csk->partial_timer.function = (void (*)(unsigned long)) tcp_send_partial;
sk1496net/ipv4/tcp.csk->partial_timer.data = (unsigned long) sk;
sk1497net/ipv4/tcp.cadd_timer(&sk->partial_timer);
sk1500net/ipv4/tcp.ctcp_send_skb(sk, tmp);
sk1509net/ipv4/tcp.cstruct sock *sk,
sk1517net/ipv4/tcp.cif(sk->zapped)
sk1525net/ipv4/tcp.cbuff = sock_wmalloc(sk, MAX_ACK_SIZE, 1, GFP_ATOMIC);
sk1535net/ipv4/tcp.csk->ack_backlog++;
sk1536net/ipv4/tcp.cif (sk->ip_xmit_timeout != TIME_WRITE && tcp_connected(sk->state)) 
sk1538net/ipv4/tcp.creset_xmit_timer(sk, TIME_WRITE, HZ);
sk1547net/ipv4/tcp.cbuff->sk = sk;
sk1548net/ipv4/tcp.cbuff->localroute = sk->localroute;
sk1554net/ipv4/tcp.ctmp = sk->prot->build_header(buff, sk->saddr, daddr, &dev,
sk1555net/ipv4/tcp.cIPPROTO_TCP, sk->opt, MAX_ACK_SIZE,sk->ip_tos,sk->ip_ttl);
sk1559net/ipv4/tcp.csock_wfree(sk, buff);
sk1574net/ipv4/tcp.csk->window = tcp_select_window(sk);
sk1575net/ipv4/tcp.ct1->window = ntohs(sk->window);
sk1590net/ipv4/tcp.cif (ack == sk->acked_seq) 
sk1592net/ipv4/tcp.csk->ack_backlog = 0;
sk1593net/ipv4/tcp.csk->bytes_rcv = 0;
sk1594net/ipv4/tcp.csk->ack_timed = 0;
sk1595net/ipv4/tcp.cif (sk->send_head == NULL && skb_peek(&sk->write_queue) == NULL
sk1596net/ipv4/tcp.c&& sk->ip_xmit_timeout == TIME_WRITE) 
sk1598net/ipv4/tcp.cif(sk->keepopen) {
sk1599net/ipv4/tcp.creset_xmit_timer(sk,TIME_KEEPOPEN,TCP_TIMEOUT_LEN);
sk1601net/ipv4/tcp.cdelete_timer(sk);
sk1612net/ipv4/tcp.ctcp_send_check(t1, sk->saddr, daddr, sizeof(*t1), sk);
sk1613net/ipv4/tcp.cif (sk->debug)
sk1616net/ipv4/tcp.csk->prot->queue_xmit(sk, dev, buff, 1);
sk1624net/ipv4/tcp.cextern __inline int tcp_build_header(struct tcphdr *th, struct sock *sk, int push)
sk1627net/ipv4/tcp.cmemcpy(th,(void *) &(sk->dummy_th), sizeof(*th));
sk1628net/ipv4/tcp.cth->seq = htonl(sk->write_seq);
sk1633net/ipv4/tcp.csk->ack_backlog = 0;
sk1634net/ipv4/tcp.csk->bytes_rcv = 0;
sk1635net/ipv4/tcp.csk->ack_timed = 0;
sk1636net/ipv4/tcp.cth->ack_seq = htonl(sk->acked_seq);
sk1637net/ipv4/tcp.csk->window = tcp_select_window(sk);
sk1638net/ipv4/tcp.cth->window = htons(sk->window);
sk1648net/ipv4/tcp.cstatic int tcp_sendmsg(struct sock *sk, struct msghdr *msg,
sk1671net/ipv4/tcp.cif(sk->state == TCP_CLOSE)
sk1677net/ipv4/tcp.cif (addr->sin_port != sk->dummy_th.dest) 
sk1679net/ipv4/tcp.cif (addr->sin_addr.s_addr != sk->daddr) 
sk1691net/ipv4/tcp.csk->inuse=1;
sk1692net/ipv4/tcp.cprot = sk->prot;
sk1695net/ipv4/tcp.cif (sk->err) 
sk1697net/ipv4/tcp.crelease_sock(sk);
sk1700net/ipv4/tcp.ctmp = -sk->err;
sk1701net/ipv4/tcp.csk->err = 0;
sk1709net/ipv4/tcp.cif (sk->shutdown & SEND_SHUTDOWN) 
sk1711net/ipv4/tcp.crelease_sock(sk);
sk1712net/ipv4/tcp.csk->err = EPIPE;
sk1715net/ipv4/tcp.csk->err = 0;
sk1723net/ipv4/tcp.cwhile(sk->state != TCP_ESTABLISHED && sk->state != TCP_CLOSE_WAIT) 
sk1725net/ipv4/tcp.cif (sk->err) 
sk1727net/ipv4/tcp.crelease_sock(sk);
sk1730net/ipv4/tcp.ctmp = -sk->err;
sk1731net/ipv4/tcp.csk->err = 0;
sk1735net/ipv4/tcp.cif (sk->state != TCP_SYN_SENT && sk->state != TCP_SYN_RECV) 
sk1737net/ipv4/tcp.crelease_sock(sk);
sk1741net/ipv4/tcp.cif (sk->err) 
sk1743net/ipv4/tcp.ctmp = -sk->err;
sk1744net/ipv4/tcp.csk->err = 0;
sk1748net/ipv4/tcp.cif (sk->keepopen) 
sk1757net/ipv4/tcp.crelease_sock(sk);
sk1763net/ipv4/tcp.crelease_sock(sk);
sk1766net/ipv4/tcp.cif (sk->state != TCP_ESTABLISHED &&
sk1767net/ipv4/tcp.csk->state != TCP_CLOSE_WAIT && sk->err == 0) 
sk1769net/ipv4/tcp.cinterruptible_sleep_on(sk->sleep);  
sk1778net/ipv4/tcp.csk->inuse = 1;
sk1798net/ipv4/tcp.cif ((skb = tcp_dequeue_partial(sk)) != NULL) 
sk1809net/ipv4/tcp.ccopy = min(sk->mss - (skb->len - hdrlen), len);
sk1820net/ipv4/tcp.csk->write_seq += copy;
sk1823net/ipv4/tcp.cif ((skb->len - hdrlen) >= sk->mss ||
sk1824net/ipv4/tcp.c(flags & MSG_OOB) || !sk->packets_out)
sk1825net/ipv4/tcp.ctcp_send_skb(sk, skb);
sk1827net/ipv4/tcp.ctcp_enqueue_partial(skb, sk);
sk1843net/ipv4/tcp.ccopy = sk->window_seq - sk->write_seq;
sk1844net/ipv4/tcp.cif (copy <= 0 || copy < (sk->max_window >> 1) || copy > sk->mss)
sk1845net/ipv4/tcp.ccopy = sk->mss;
sk1854net/ipv4/tcp.cif (copy < sk->mss && !(flags & MSG_OOB)) 
sk1859net/ipv4/tcp.crelease_sock(sk);
sk1864net/ipv4/tcp.cskb = sock_wmalloc(sk, sk->mtu + 128 + prot->max_header + 15, 0, GFP_KERNEL);
sk1865net/ipv4/tcp.csk->inuse = 1;
sk1873net/ipv4/tcp.crelease_sock(sk);
sk1874net/ipv4/tcp.cskb = sock_wmalloc(sk, copy + prot->max_header + 15 , 0, GFP_KERNEL);
sk1875net/ipv4/tcp.csk->inuse = 1;
sk1884net/ipv4/tcp.csk->socket->flags |= SO_NOSPACE;
sk1887net/ipv4/tcp.crelease_sock(sk);
sk1897net/ipv4/tcp.ctmp = sk->wmem_alloc;
sk1898net/ipv4/tcp.crelease_sock(sk);
sk1903net/ipv4/tcp.cif (tmp <= sk->wmem_alloc &&
sk1904net/ipv4/tcp.c(sk->state == TCP_ESTABLISHED||sk->state == TCP_CLOSE_WAIT)
sk1905net/ipv4/tcp.c&& sk->err == 0) 
sk1907net/ipv4/tcp.csk->socket->flags &= ~SO_NOSPACE;
sk1908net/ipv4/tcp.cinterruptible_sleep_on(sk->sleep);
sk1917net/ipv4/tcp.csk->inuse = 1;
sk1922net/ipv4/tcp.cskb->sk = sk;
sk1924net/ipv4/tcp.cskb->localroute = sk->localroute|(flags&MSG_DONTROUTE);
sk1931net/ipv4/tcp.ctmp = prot->build_header(skb, sk->saddr, sk->daddr, &dev,
sk1932net/ipv4/tcp.cIPPROTO_TCP, sk->opt, skb->truesize,sk->ip_tos,sk->ip_ttl);
sk1935net/ipv4/tcp.csock_wfree(sk, skb);
sk1936net/ipv4/tcp.crelease_sock(sk);
sk1943net/ipv4/tcp.ctmp = tcp_build_header(skb->h.th, sk, len-copy);
sk1946net/ipv4/tcp.csock_wfree(sk, skb);
sk1947net/ipv4/tcp.crelease_sock(sk);
sk1966net/ipv4/tcp.csk->write_seq += copy;
sk1968net/ipv4/tcp.cif (send_tmp != NULL && sk->packets_out) 
sk1970net/ipv4/tcp.ctcp_enqueue_partial(send_tmp, sk);
sk1973net/ipv4/tcp.ctcp_send_skb(sk, skb);
sk1976net/ipv4/tcp.csk->err = 0;
sk1989net/ipv4/tcp.cif(sk->partial && ((!sk->packets_out) 
sk1991net/ipv4/tcp.c|| (sk->nonagle && before(sk->write_seq , sk->window_seq))
sk1993net/ipv4/tcp.ctcp_send_partial(sk);
sk1995net/ipv4/tcp.crelease_sock(sk);
sk1999net/ipv4/tcp.cstatic int tcp_sendto(struct sock *sk, const unsigned char *ubuf, int size, int noblock, unsigned flags,
sk2014net/ipv4/tcp.creturn tcp_sendmsg(sk, &msg, size, noblock, flags);
sk2017net/ipv4/tcp.cstatic int tcp_write(struct sock *sk, const unsigned char *ubuf, int size, int noblock, unsigned flags)
sk2019net/ipv4/tcp.creturn tcp_sendto(sk,ubuf,size,noblock,flags,NULL,0);
sk2028net/ipv4/tcp.cstatic void tcp_read_wakeup(struct sock *sk)
sk2035net/ipv4/tcp.cif (!sk->ack_backlog) 
sk2042net/ipv4/tcp.cif ((sk->state == TCP_CLOSE) || (sk->state == TCP_TIME_WAIT))
sk2056net/ipv4/tcp.cbuff = sock_wmalloc(sk,MAX_ACK_SIZE,1, GFP_ATOMIC);
sk2060net/ipv4/tcp.creset_xmit_timer(sk, TIME_WRITE, HZ);
sk2064net/ipv4/tcp.cbuff->sk = sk;
sk2065net/ipv4/tcp.cbuff->localroute = sk->localroute;
sk2071net/ipv4/tcp.ctmp = sk->prot->build_header(buff, sk->saddr, sk->daddr, &dev,
sk2072net/ipv4/tcp.cIPPROTO_TCP, sk->opt, MAX_ACK_SIZE,sk->ip_tos,sk->ip_ttl);
sk2076net/ipv4/tcp.csock_wfree(sk, buff);
sk2082net/ipv4/tcp.cmemcpy(t1,(void *) &sk->dummy_th, sizeof(*t1));
sk2083net/ipv4/tcp.ct1->seq = htonl(sk->sent_seq);
sk2091net/ipv4/tcp.csk->ack_backlog = 0;
sk2092net/ipv4/tcp.csk->bytes_rcv = 0;
sk2093net/ipv4/tcp.csk->window = tcp_select_window(sk);
sk2094net/ipv4/tcp.ct1->window = ntohs(sk->window);
sk2095net/ipv4/tcp.ct1->ack_seq = ntohl(sk->acked_seq);
sk2097net/ipv4/tcp.ctcp_send_check(t1, sk->saddr, sk->daddr, sizeof(*t1), sk);
sk2098net/ipv4/tcp.csk->prot->queue_xmit(sk, dev, buff, 1);
sk2110net/ipv4/tcp.cstatic void cleanup_rbuf(struct sock *sk)
sk2117net/ipv4/tcp.cif(sk->debug)
sk2118net/ipv4/tcp.cprintk("cleaning rbuf for sk=%p\n", sk);
sk2123net/ipv4/tcp.cleft = sock_rspace(sk);
sk2130net/ipv4/tcp.cwhile((skb=skb_peek(&sk->receive_queue)) != NULL) 
sk2135net/ipv4/tcp.cskb->sk = sk;
sk2148net/ipv4/tcp.cif(sk->debug)
sk2149net/ipv4/tcp.cprintk("sk->rspace = %lu, was %lu\n", sock_rspace(sk),
sk2151net/ipv4/tcp.cif ((rspace=sock_rspace(sk)) != left) 
sk2163net/ipv4/tcp.csk->ack_backlog++;
sk2173net/ipv4/tcp.cif (rspace > (sk->window - sk->bytes_rcv + sk->mtu)) 
sk2176net/ipv4/tcp.ctcp_read_wakeup(sk);
sk2181net/ipv4/tcp.cint was_active = del_timer(&sk->retransmit_timer);
sk2182net/ipv4/tcp.cif (!was_active || jiffies+TCP_ACK_TIME < sk->timer.expires) 
sk2184net/ipv4/tcp.creset_xmit_timer(sk, TIME_WRITE, TCP_ACK_TIME);
sk2187net/ipv4/tcp.cadd_timer(&sk->retransmit_timer);
sk2198net/ipv4/tcp.cstatic int tcp_recv_urg(struct sock * sk, int nonblock,
sk2204net/ipv4/tcp.cif (sk->urginline || !sk->urg_data || sk->urg_data == URG_READ)
sk2207net/ipv4/tcp.cif (sk->err) 
sk2209net/ipv4/tcp.cint tmp = -sk->err;
sk2210net/ipv4/tcp.csk->err = 0;
sk2214net/ipv4/tcp.cif (sk->state == TCP_CLOSE || sk->done) 
sk2216net/ipv4/tcp.cif (!sk->done) 
sk2218net/ipv4/tcp.csk->done = 1;
sk2224net/ipv4/tcp.cif (sk->shutdown & RCV_SHUTDOWN) 
sk2226net/ipv4/tcp.csk->done = 1;
sk2229net/ipv4/tcp.csk->inuse = 1;
sk2230net/ipv4/tcp.cif (sk->urg_data & URG_VALID) 
sk2232net/ipv4/tcp.cchar c = sk->urg_data;
sk2234net/ipv4/tcp.csk->urg_data = URG_READ;
sk2240net/ipv4/tcp.csin->sin_addr.s_addr=sk->daddr;
sk2241net/ipv4/tcp.csin->sin_port=sk->dummy_th.dest;
sk2245net/ipv4/tcp.crelease_sock(sk);
sk2248net/ipv4/tcp.crelease_sock(sk);
sk2265net/ipv4/tcp.cstatic int tcp_recvmsg(struct sock *sk, struct msghdr *msg,
sk2278net/ipv4/tcp.cif (sk->state == TCP_LISTEN)
sk2286net/ipv4/tcp.creturn tcp_recv_urg(sk, nonblock, msg, len, flags, addr_len);
sk2294net/ipv4/tcp.cpeek_seq = sk->copied_seq;
sk2295net/ipv4/tcp.cseq = &sk->copied_seq;
sk2299net/ipv4/tcp.cadd_wait_queue(sk->sleep, &wait);
sk2300net/ipv4/tcp.csk->inuse = 1;
sk2310net/ipv4/tcp.cif (copied && sk->urg_data && sk->urg_seq == *seq)
sk2319net/ipv4/tcp.cskb = skb_peek(&sk->receive_queue);
sk2337net/ipv4/tcp.cwhile (skb != (struct sk_buff *)&sk->receive_queue);
sk2342net/ipv4/tcp.cif (sk->err) 
sk2344net/ipv4/tcp.ccopied = -sk->err;
sk2345net/ipv4/tcp.csk->err = 0;
sk2349net/ipv4/tcp.cif (sk->state == TCP_CLOSE) 
sk2351net/ipv4/tcp.cif (!sk->done) 
sk2353net/ipv4/tcp.csk->done = 1;
sk2360net/ipv4/tcp.cif (sk->shutdown & RCV_SHUTDOWN) 
sk2362net/ipv4/tcp.csk->done = 1;
sk2372net/ipv4/tcp.ccleanup_rbuf(sk);
sk2373net/ipv4/tcp.crelease_sock(sk);
sk2374net/ipv4/tcp.csk->socket->flags |= SO_WAITDATA;
sk2376net/ipv4/tcp.csk->socket->flags &= ~SO_WAITDATA;
sk2377net/ipv4/tcp.csk->inuse = 1;
sk2407net/ipv4/tcp.cif (sk->urg_data) 
sk2409net/ipv4/tcp.cu32 urg_offset = sk->urg_seq - *seq;
sk2414net/ipv4/tcp.cif (!sk->urginline) 
sk2452net/ipv4/tcp.cif (after(sk->copied_seq,sk->urg_seq))
sk2453net/ipv4/tcp.csk->urg_data = 0;
sk2478net/ipv4/tcp.csk->shutdown |= RCV_SHUTDOWN;
sk2487net/ipv4/tcp.csin->sin_addr.s_addr=sk->daddr;
sk2488net/ipv4/tcp.csin->sin_port=sk->dummy_th.dest;
sk2493net/ipv4/tcp.cremove_wait_queue(sk->sleep, &wait);
sk2497net/ipv4/tcp.ccleanup_rbuf(sk);
sk2498net/ipv4/tcp.crelease_sock(sk);
sk2503net/ipv4/tcp.cstatic int tcp_recvfrom(struct sock *sk, unsigned char *ubuf, int size, int noblock, unsigned flags,
sk2520net/ipv4/tcp.creturn tcp_recvmsg(sk, &msg, size, noblock, flags, addr_len);
sk2523net/ipv4/tcp.cint tcp_read(struct sock *sk, unsigned char *buff, int len, int noblock,
sk2526net/ipv4/tcp.creturn(tcp_recvfrom(sk, buff, len, noblock, flags, NULL, NULL));
sk2537net/ipv4/tcp.cstatic int tcp_close_state(struct sock *sk, int dead)
sk2541net/ipv4/tcp.cswitch(sk->state)
sk2553net/ipv4/tcp.cns=sk->state;
sk2564net/ipv4/tcp.ctcp_set_state(sk,ns);
sk2577net/ipv4/tcp.cint timer_active=del_timer(&sk->timer);
sk2579net/ipv4/tcp.cadd_timer(&sk->timer);
sk2581net/ipv4/tcp.creset_msl_timer(sk, TIME_CLOSE, TCP_FIN_TIMEOUT);
sk2591net/ipv4/tcp.cstatic void tcp_send_fin(struct sock *sk)
sk2593net/ipv4/tcp.cstruct proto *prot =(struct proto *)sk->prot;
sk2594net/ipv4/tcp.cstruct tcphdr *th =(struct tcphdr *)&sk->dummy_th;
sk2600net/ipv4/tcp.crelease_sock(sk); /* in case the malloc sleeps. */
sk2602net/ipv4/tcp.cbuff = sock_wmalloc(sk, MAX_RESET_SIZE,1 , GFP_KERNEL);
sk2603net/ipv4/tcp.csk->inuse = 1;
sk2616net/ipv4/tcp.cbuff->sk = sk;
sk2617net/ipv4/tcp.cbuff->localroute = sk->localroute;
sk2623net/ipv4/tcp.ctmp = prot->build_header(buff,sk->saddr, sk->daddr, &dev,
sk2624net/ipv4/tcp.cIPPROTO_TCP, sk->opt,
sk2625net/ipv4/tcp.csizeof(struct tcphdr),sk->ip_tos,sk->ip_ttl);
sk2635net/ipv4/tcp.csock_wfree(sk,buff);
sk2636net/ipv4/tcp.csk->write_seq++;
sk2637net/ipv4/tcp.ct=del_timer(&sk->timer);
sk2639net/ipv4/tcp.cadd_timer(&sk->timer);
sk2641net/ipv4/tcp.creset_msl_timer(sk, TIME_CLOSE, TCP_TIMEWAIT_LEN);
sk2653net/ipv4/tcp.ct1->seq = ntohl(sk->write_seq);
sk2654net/ipv4/tcp.csk->write_seq++;
sk2655net/ipv4/tcp.cbuff->h.seq = sk->write_seq;
sk2657net/ipv4/tcp.ct1->ack_seq = ntohl(sk->acked_seq);
sk2658net/ipv4/tcp.ct1->window = ntohs(sk->window=tcp_select_window(sk));
sk2662net/ipv4/tcp.ctcp_send_check(t1, sk->saddr, sk->daddr, sizeof(*t1), sk);
sk2669net/ipv4/tcp.cif (skb_peek(&sk->write_queue) != NULL) 
sk2677net/ipv4/tcp.cskb_queue_tail(&sk->write_queue, buff);
sk2681net/ipv4/tcp.csk->sent_seq = sk->write_seq;
sk2682net/ipv4/tcp.csk->prot->queue_xmit(sk, dev, buff, 0);
sk2683net/ipv4/tcp.creset_xmit_timer(sk, TIME_WRITE, sk->rto);
sk2692net/ipv4/tcp.cvoid tcp_shutdown(struct sock *sk, int how)
sk2707net/ipv4/tcp.cif (sk->state == TCP_FIN_WAIT1 ||
sk2708net/ipv4/tcp.csk->state == TCP_FIN_WAIT2 ||
sk2709net/ipv4/tcp.csk->state == TCP_CLOSING ||
sk2710net/ipv4/tcp.csk->state == TCP_LAST_ACK ||
sk2711net/ipv4/tcp.csk->state == TCP_TIME_WAIT || 
sk2712net/ipv4/tcp.csk->state == TCP_CLOSE ||
sk2713net/ipv4/tcp.csk->state == TCP_LISTEN
sk2718net/ipv4/tcp.csk->inuse = 1;
sk2724net/ipv4/tcp.csk->shutdown |= SEND_SHUTDOWN;
sk2730net/ipv4/tcp.cif (sk->partial)
sk2731net/ipv4/tcp.ctcp_send_partial(sk);
sk2737net/ipv4/tcp.cif(tcp_close_state(sk,0))
sk2738net/ipv4/tcp.ctcp_send_fin(sk);
sk2740net/ipv4/tcp.crelease_sock(sk);
sk2771net/ipv4/tcp.cbuff->sk = NULL;
sk2838net/ipv4/tcp.cstatic void tcp_options(struct sock *sk, struct tcphdr *th)
sk2867net/ipv4/tcp.csk->mtu=min(sk->mtu,ntohs(*(unsigned short *)ptr));
sk2880net/ipv4/tcp.csk->mtu=min(sk->mtu, 536);  /* default MSS if none sent */
sk2883net/ipv4/tcp.csk->mss = min(sk->max_window >> 1, sk->mtu);
sk2885net/ipv4/tcp.csk->mss = min(sk->max_window, sk->mtu);
sk2923net/ipv4/tcp.cstatic void tcp_conn_request(struct sock *sk, struct sk_buff *skb,
sk2939net/ipv4/tcp.cif (!sk->dead) 
sk2941net/ipv4/tcp.csk->data_ready(sk,0);
sk2945net/ipv4/tcp.cif(sk->debug)
sk2946net/ipv4/tcp.cprintk("Reset on %p: Connect on dead socket.\n",sk);
sk2947net/ipv4/tcp.ctcp_reset(daddr, saddr, th, sk->prot, opt, dev, sk->ip_tos,sk->ip_ttl);
sk2958net/ipv4/tcp.cif (sk->ack_backlog >= sk->max_ack_backlog) 
sk2982net/ipv4/tcp.cmemcpy(newsk, sk, sizeof(*newsk));
sk2985net/ipv4/tcp.csk->opt = (struct options*)kmalloc(sizeof(struct options)+opt->optlen, GFP_ATOMIC);
sk2986net/ipv4/tcp.cif (!sk->opt) {
sk2992net/ipv4/tcp.cif (ip_options_echo(sk->opt, opt, daddr, saddr, skb)) {
sk2993net/ipv4/tcp.ckfree_s(sk->opt, sizeof(struct options)+opt->optlen);
sk3021net/ipv4/tcp.cnewsk->localroute = sk->localroute;
sk3076net/ipv4/tcp.cnewsk->ip_ttl=sk->ip_ttl;
sk3094net/ipv4/tcp.cif (sk->user_mss)
sk3095net/ipv4/tcp.cnewsk->mtu = sk->user_mss;
sk3127net/ipv4/tcp.csk->err = ENOMEM;
sk3137net/ipv4/tcp.cbuff->sk = newsk;
sk3144net/ipv4/tcp.ctmp = sk->prot->build_header(buff, newsk->saddr, newsk->daddr, &ndev,
sk3145net/ipv4/tcp.cIPPROTO_TCP, NULL, MAX_SYN_SIZE,sk->ip_tos,sk->ip_ttl);
sk3153net/ipv4/tcp.csk->err = tmp;
sk3159net/ipv4/tcp.cskb->sk = sk;
sk3196net/ipv4/tcp.cskb->sk = newsk;
sk3202net/ipv4/tcp.csk->rmem_alloc -= skb->truesize;
sk3205net/ipv4/tcp.cskb_queue_tail(&sk->receive_queue,skb);
sk3206net/ipv4/tcp.csk->ack_backlog++;
sk3212net/ipv4/tcp.cstatic void tcp_close(struct sock *sk, int timeout)
sk3219net/ipv4/tcp.csk->inuse = 1;
sk3221net/ipv4/tcp.cif(th_cache_sk==sk)
sk3223net/ipv4/tcp.cif(sk->state == TCP_LISTEN)
sk3226net/ipv4/tcp.ctcp_set_state(sk, TCP_CLOSE);
sk3227net/ipv4/tcp.ctcp_close_pending(sk);
sk3228net/ipv4/tcp.crelease_sock(sk);
sk3232net/ipv4/tcp.csk->keepopen = 1;
sk3233net/ipv4/tcp.csk->shutdown = SHUTDOWN_MASK;
sk3235net/ipv4/tcp.cif (!sk->dead) 
sk3236net/ipv4/tcp.csk->state_change(sk);
sk3248net/ipv4/tcp.cwhile((skb=skb_dequeue(&sk->receive_queue))!=NULL)
sk3254net/ipv4/tcp.cif (sk->partial) 
sk3255net/ipv4/tcp.ctcp_send_partial(sk);
sk3266net/ipv4/tcp.ctcp_set_state(sk, TCP_CLOSE);  /* Dead */
sk3270net/ipv4/tcp.cif(tcp_close_state(sk,1)==1)
sk3272net/ipv4/tcp.ctcp_send_fin(sk);
sk3275net/ipv4/tcp.crelease_sock(sk);
sk3285net/ipv4/tcp.cstatic void tcp_write_xmit(struct sock *sk)
sk3294net/ipv4/tcp.cif(sk->zapped)
sk3305net/ipv4/tcp.cwhile((skb = skb_peek(&sk->write_queue)) != NULL &&
sk3306net/ipv4/tcp.cbefore(skb->h.seq, sk->window_seq + 1) &&
sk3307net/ipv4/tcp.c(sk->retransmits == 0 ||
sk3308net/ipv4/tcp.csk->ip_xmit_timeout != TIME_WRITE ||
sk3309net/ipv4/tcp.cbefore(skb->h.seq, sk->rcv_ack_seq + 1))
sk3310net/ipv4/tcp.c&& sk->packets_out < sk->cong_window) 
sk3319net/ipv4/tcp.cif (before(skb->h.seq, sk->rcv_ack_seq +1)) 
sk3326net/ipv4/tcp.csk->retransmits = 0;
sk3328net/ipv4/tcp.cif (!sk->dead) 
sk3329net/ipv4/tcp.csk->write_space(sk);
sk3347net/ipv4/tcp.cth->ack_seq = ntohl(sk->acked_seq);
sk3348net/ipv4/tcp.cth->window = ntohs(tcp_select_window(sk));
sk3350net/ipv4/tcp.ctcp_send_check(th, sk->saddr, sk->daddr, size, sk);
sk3352net/ipv4/tcp.csk->sent_seq = skb->h.seq;
sk3358net/ipv4/tcp.csk->prot->queue_xmit(sk, skb->dev, skb, skb->free);
sk3364net/ipv4/tcp.creset_xmit_timer(sk, TIME_WRITE, sk->rto);
sk3374net/ipv4/tcp.cextern __inline__ int tcp_ack(struct sock *sk, struct tcphdr *th, unsigned long saddr, int len)
sk3386net/ipv4/tcp.cif(sk->zapped)
sk3395net/ipv4/tcp.cif (ntohs(th->window) > sk->max_window) 
sk3397net/ipv4/tcp.csk->max_window = ntohs(th->window);
sk3401net/ipv4/tcp.csk->mss = min(sk->max_window>>1, sk->mtu);
sk3403net/ipv4/tcp.csk->mss = min(sk->max_window, sk->mtu);
sk3412net/ipv4/tcp.cif (sk->retransmits && sk->ip_xmit_timeout == TIME_KEEPOPEN)
sk3413net/ipv4/tcp.csk->retransmits = 0;
sk3420net/ipv4/tcp.cif (after(ack, sk->sent_seq) || before(ack, sk->rcv_ack_seq)) 
sk3422net/ipv4/tcp.cif(sk->debug)
sk3423net/ipv4/tcp.cprintk("Ack ignored %u %u\n",ack,sk->sent_seq);
sk3429net/ipv4/tcp.cif (after(ack, sk->sent_seq)) 
sk3438net/ipv4/tcp.cif (sk->keepopen) 
sk3440net/ipv4/tcp.cif(sk->ip_xmit_timeout==TIME_KEEPOPEN)
sk3441net/ipv4/tcp.creset_xmit_timer(sk, TIME_KEEPOPEN, TCP_TIMEOUT_LEN);
sk3457net/ipv4/tcp.cif (after(sk->window_seq, ack+ntohs(th->window))) 
sk3470net/ipv4/tcp.cskb2 = sk->send_head;
sk3471net/ipv4/tcp.csk->send_head = NULL;
sk3472net/ipv4/tcp.csk->send_tail = NULL;
sk3481net/ipv4/tcp.csk->window_seq = ack + ntohs(th->window);
sk3488net/ipv4/tcp.cif (after(skb->h.seq, sk->window_seq)) 
sk3490net/ipv4/tcp.cif (sk->packets_out > 0) 
sk3491net/ipv4/tcp.csk->packets_out--;
sk3499net/ipv4/tcp.cskb_queue_head(&sk->write_queue,skb);
sk3506net/ipv4/tcp.cif (sk->send_head == NULL) 
sk3508net/ipv4/tcp.csk->send_head = skb;
sk3509net/ipv4/tcp.csk->send_tail = skb;
sk3513net/ipv4/tcp.csk->send_tail->link3 = skb;
sk3514net/ipv4/tcp.csk->send_tail = skb;
sk3526net/ipv4/tcp.cif (sk->send_tail == NULL || sk->send_head == NULL) 
sk3528net/ipv4/tcp.csk->send_head = NULL;
sk3529net/ipv4/tcp.csk->send_tail = NULL;
sk3530net/ipv4/tcp.csk->packets_out= 0;
sk3537net/ipv4/tcp.csk->window_seq = ack + ntohs(th->window);
sk3543net/ipv4/tcp.cif (sk->ip_xmit_timeout == TIME_WRITE && 
sk3544net/ipv4/tcp.csk->cong_window < 2048 && after(ack, sk->rcv_ack_seq)) 
sk3555net/ipv4/tcp.cif (sk->cong_window < sk->ssthresh)  
sk3559net/ipv4/tcp.csk->cong_window++;
sk3566net/ipv4/tcp.cif (sk->cong_count >= sk->cong_window) 
sk3568net/ipv4/tcp.csk->cong_window++;
sk3569net/ipv4/tcp.csk->cong_count = 0;
sk3572net/ipv4/tcp.csk->cong_count++;
sk3580net/ipv4/tcp.csk->rcv_ack_seq = ack;
sk3588net/ipv4/tcp.cif (sk->ip_xmit_timeout == TIME_PROBE0) 
sk3590net/ipv4/tcp.csk->retransmits = 0;  /* Our probe was answered */
sk3596net/ipv4/tcp.cif (skb_peek(&sk->write_queue) != NULL &&   /* should always be non-null */
sk3597net/ipv4/tcp.c! before (sk->window_seq, sk->write_queue.next->h.seq)) 
sk3599net/ipv4/tcp.csk->backoff = 0;
sk3605net/ipv4/tcp.csk->rto = ((sk->rtt >> 2) + sk->mdev) >> 1;
sk3606net/ipv4/tcp.cif (sk->rto > 120*HZ)
sk3607net/ipv4/tcp.csk->rto = 120*HZ;
sk3608net/ipv4/tcp.cif (sk->rto < 20)  /* Was 1*HZ, then 1 - turns out we must allow about
sk3611net/ipv4/tcp.csk->rto = 20;
sk3619net/ipv4/tcp.cwhile(sk->send_head != NULL) 
sk3622net/ipv4/tcp.cif (sk->send_head->link3 &&
sk3623net/ipv4/tcp.cafter(sk->send_head->h.seq, sk->send_head->link3->h.seq)) 
sk3631net/ipv4/tcp.cif (before(sk->send_head->h.seq, ack+1)) 
sk3634net/ipv4/tcp.cif (sk->retransmits) 
sk3649net/ipv4/tcp.cif (sk->send_head->link3)  /* Any more queued retransmits? */
sk3650net/ipv4/tcp.csk->retransmits = 1;
sk3652net/ipv4/tcp.csk->retransmits = 0;
sk3670net/ipv4/tcp.cif (sk->packets_out > 0) 
sk3671net/ipv4/tcp.csk->packets_out --;
sk3675net/ipv4/tcp.cif (!sk->dead) 
sk3676net/ipv4/tcp.csk->write_space(sk);
sk3677net/ipv4/tcp.coskb = sk->send_head;
sk3694net/ipv4/tcp.cm -= (sk->rtt >> 3);    /* m is now error in rtt est */
sk3695net/ipv4/tcp.csk->rtt += m;           /* rtt = 7/8 rtt + 1/8 new */
sk3698net/ipv4/tcp.cm -= (sk->mdev >> 2);   /* similar update on mdev */
sk3699net/ipv4/tcp.csk->mdev += m;        /* mdev = 3/4 mdev + 1/4 new */
sk3705net/ipv4/tcp.csk->rto = ((sk->rtt >> 2) + sk->mdev) >> 1;
sk3706net/ipv4/tcp.cif (sk->rto > 120*HZ)
sk3707net/ipv4/tcp.csk->rto = 120*HZ;
sk3708net/ipv4/tcp.cif (sk->rto < 20)  /* Was 1*HZ - keep .2 as minimum cos of the BSD delayed acks */
sk3709net/ipv4/tcp.csk->rto = 20;
sk3710net/ipv4/tcp.csk->backoff = 0;
sk3715net/ipv4/tcp.coskb = sk->send_head;
sk3717net/ipv4/tcp.csk->send_head = oskb->link3;
sk3718net/ipv4/tcp.cif (sk->send_head == NULL) 
sk3720net/ipv4/tcp.csk->send_tail = NULL;
sk3731net/ipv4/tcp.cif (!sk->dead) 
sk3732net/ipv4/tcp.csk->write_space(sk);
sk3753net/ipv4/tcp.cif (skb_peek(&sk->write_queue) != NULL) 
sk3755net/ipv4/tcp.cif (after (sk->window_seq+1, sk->write_queue.next->h.seq) &&
sk3756net/ipv4/tcp.c(sk->retransmits == 0 || 
sk3757net/ipv4/tcp.csk->ip_xmit_timeout != TIME_WRITE ||
sk3758net/ipv4/tcp.cbefore(sk->write_queue.next->h.seq, sk->rcv_ack_seq + 1))
sk3759net/ipv4/tcp.c&& sk->packets_out < sk->cong_window) 
sk3765net/ipv4/tcp.ctcp_write_xmit(sk);
sk3767net/ipv4/tcp.celse if (before(sk->window_seq, sk->write_queue.next->h.seq) &&
sk3768net/ipv4/tcp.csk->send_head == NULL &&
sk3769net/ipv4/tcp.csk->ack_backlog == 0 &&
sk3770net/ipv4/tcp.csk->state != TCP_TIME_WAIT) 
sk3775net/ipv4/tcp.creset_xmit_timer(sk, TIME_PROBE0, sk->rto);
sk3793net/ipv4/tcp.cswitch(sk->state) {
sk3799net/ipv4/tcp.creset_msl_timer(sk, TIME_CLOSE, TCP_TIMEWAIT_LEN);
sk3811net/ipv4/tcp.cif (sk->send_head || skb_peek(&sk->write_queue) != NULL || sk->ack_backlog) {
sk3812net/ipv4/tcp.creset_xmit_timer(sk, TIME_WRITE, sk->rto);
sk3813net/ipv4/tcp.c} else if (sk->keepopen) {
sk3814net/ipv4/tcp.creset_xmit_timer(sk, TIME_KEEPOPEN, TCP_TIMEOUT_LEN);
sk3816net/ipv4/tcp.cdel_timer(&sk->retransmit_timer);
sk3817net/ipv4/tcp.csk->ip_xmit_timeout = 0;
sk3828net/ipv4/tcp.cif (sk->packets_out == 0 && sk->partial != NULL &&
sk3829net/ipv4/tcp.cskb_peek(&sk->write_queue) == NULL && sk->send_head == NULL) 
sk3832net/ipv4/tcp.ctcp_send_partial(sk);
sk3843net/ipv4/tcp.cif (sk->state == TCP_LAST_ACK) 
sk3845net/ipv4/tcp.cif (!sk->dead)
sk3846net/ipv4/tcp.csk->state_change(sk);
sk3847net/ipv4/tcp.cif(sk->debug)
sk3849net/ipv4/tcp.csk->rcv_ack_seq,sk->write_seq,sk->acked_seq,sk->fin_seq);
sk3850net/ipv4/tcp.cif (sk->rcv_ack_seq == sk->write_seq /*&& sk->acked_seq == sk->fin_seq*/) 
sk3853net/ipv4/tcp.ctcp_set_state(sk,TCP_CLOSE);
sk3854net/ipv4/tcp.csk->shutdown = SHUTDOWN_MASK;
sk3865net/ipv4/tcp.cif (sk->state == TCP_FIN_WAIT1) 
sk3868net/ipv4/tcp.cif (!sk->dead) 
sk3869net/ipv4/tcp.csk->state_change(sk);
sk3870net/ipv4/tcp.cif (sk->rcv_ack_seq == sk->write_seq) 
sk3873net/ipv4/tcp.csk->shutdown |= SEND_SHUTDOWN;
sk3874net/ipv4/tcp.ctcp_set_state(sk, TCP_FIN_WAIT2);
sk3884net/ipv4/tcp.cif (sk->state == TCP_CLOSING) 
sk3887net/ipv4/tcp.cif (!sk->dead) 
sk3888net/ipv4/tcp.csk->state_change(sk);
sk3889net/ipv4/tcp.cif (sk->rcv_ack_seq == sk->write_seq) 
sk3892net/ipv4/tcp.ctcp_time_wait(sk);
sk3900net/ipv4/tcp.cif(sk->state==TCP_SYN_RECV)
sk3902net/ipv4/tcp.ctcp_set_state(sk, TCP_ESTABLISHED);
sk3903net/ipv4/tcp.ctcp_options(sk,th);
sk3904net/ipv4/tcp.csk->dummy_th.dest=th->source;
sk3905net/ipv4/tcp.csk->copied_seq = sk->acked_seq;
sk3906net/ipv4/tcp.cif(!sk->dead)
sk3907net/ipv4/tcp.csk->state_change(sk);
sk3908net/ipv4/tcp.cif(sk->max_window==0)
sk3910net/ipv4/tcp.csk->max_window=32;  /* Sanity check */
sk3911net/ipv4/tcp.csk->mss=min(sk->max_window,sk->mtu);
sk3944net/ipv4/tcp.cif (((!flag) || (flag&4)) && sk->send_head != NULL &&
sk3945net/ipv4/tcp.c(((flag&2) && sk->retransmits) ||
sk3946net/ipv4/tcp.c(sk->send_head->when + sk->rto < jiffies))) 
sk3948net/ipv4/tcp.cif(sk->send_head->when + sk->rto < jiffies)
sk3949net/ipv4/tcp.ctcp_retransmit(sk,0);  
sk3952net/ipv4/tcp.ctcp_do_retransmit(sk, 1);
sk3953net/ipv4/tcp.creset_xmit_timer(sk, TIME_WRITE, sk->rto);
sk3977net/ipv4/tcp.cstatic int tcp_fin(struct sk_buff *skb, struct sock *sk, struct tcphdr *th)
sk3979net/ipv4/tcp.csk->fin_seq = th->seq + skb->len + th->syn + th->fin;
sk3981net/ipv4/tcp.cif (!sk->dead) 
sk3983net/ipv4/tcp.csk->state_change(sk);
sk3984net/ipv4/tcp.csock_wake_async(sk->socket, 1);
sk3987net/ipv4/tcp.cswitch(sk->state) 
sk3996net/ipv4/tcp.ctcp_set_state(sk,TCP_CLOSE_WAIT);
sk3998net/ipv4/tcp.csk->shutdown = SHUTDOWN_MASK;
sk4013net/ipv4/tcp.creset_msl_timer(sk, TIME_CLOSE, TCP_TIMEWAIT_LEN);
sk4028net/ipv4/tcp.cif(sk->ip_xmit_timeout != TIME_WRITE)
sk4029net/ipv4/tcp.creset_xmit_timer(sk, TIME_WRITE, sk->rto);
sk4030net/ipv4/tcp.ctcp_set_state(sk,TCP_CLOSING);
sk4036net/ipv4/tcp.creset_msl_timer(sk, TIME_CLOSE, TCP_TIMEWAIT_LEN);
sk4037net/ipv4/tcp.csk->shutdown|=SHUTDOWN_MASK;
sk4038net/ipv4/tcp.ctcp_set_state(sk,TCP_TIME_WAIT);
sk4046net/ipv4/tcp.ctcp_set_state(sk,TCP_LAST_ACK);
sk4049net/ipv4/tcp.creset_msl_timer(sk, TIME_CLOSE, TCP_TIMEWAIT_LEN);
sk4064net/ipv4/tcp.cextern __inline__ int tcp_data(struct sk_buff *skb, struct sock *sk, 
sk4081net/ipv4/tcp.csk->bytes_rcv += skb->len;
sk4090net/ipv4/tcp.ctcp_send_ack(sk->sent_seq, sk->acked_seq,sk, th, saddr);
sk4101net/ipv4/tcp.cif(sk->shutdown & RCV_SHUTDOWN)
sk4126net/ipv4/tcp.cshut_seq=sk->acked_seq+1;  /* Last byte */
sk4130net/ipv4/tcp.cif(sk->debug)
sk4132net/ipv4/tcp.csk, new_seq, shut_seq, sk->blog);
sk4133net/ipv4/tcp.cif(sk->dead)
sk4135net/ipv4/tcp.csk->acked_seq = new_seq + th->fin;
sk4136net/ipv4/tcp.ctcp_reset(sk->saddr, sk->daddr, skb->h.th,
sk4137net/ipv4/tcp.csk->prot, NULL, skb->dev, sk->ip_tos, sk->ip_ttl);
sk4139net/ipv4/tcp.ctcp_set_state(sk,TCP_CLOSE);
sk4140net/ipv4/tcp.csk->err = EPIPE;
sk4141net/ipv4/tcp.csk->shutdown = SHUTDOWN_MASK;
sk4163net/ipv4/tcp.cif (skb_peek(&sk->receive_queue) == NULL)   /* Empty queue is easy case */
sk4165net/ipv4/tcp.cskb_queue_head(&sk->receive_queue,skb);
sk4170net/ipv4/tcp.cfor(skb1=sk->receive_queue.prev; ; skb1 = skb1->prev) 
sk4172net/ipv4/tcp.cif(sk->debug)
sk4177net/ipv4/tcp.cprintk("copied_seq = %d acked_seq = %d\n", sk->copied_seq,
sk4178net/ipv4/tcp.csk->acked_seq);
sk4212net/ipv4/tcp.cif (skb1 == skb_peek(&sk->receive_queue))
sk4214net/ipv4/tcp.cskb_queue_head(&sk->receive_queue, skb);
sk4230net/ipv4/tcp.cif (before(sk->acked_seq, sk->copied_seq)) 
sk4233net/ipv4/tcp.csk->acked_seq = sk->copied_seq;
sk4242net/ipv4/tcp.cif ((!dup_dumped && (skb1 == NULL || skb1->acked)) || before(th->seq, sk->acked_seq+1)) 
sk4244net/ipv4/tcp.cif (before(th->seq, sk->acked_seq+1)) 
sk4248net/ipv4/tcp.cif (after(th->ack_seq, sk->acked_seq)) 
sk4250net/ipv4/tcp.cnewwindow = sk->window-(th->ack_seq - sk->acked_seq);
sk4253net/ipv4/tcp.csk->window = newwindow;
sk4254net/ipv4/tcp.csk->acked_seq = th->ack_seq;
sk4265net/ipv4/tcp.ctcp_fin(skb,sk,skb->h.th);
sk4269net/ipv4/tcp.cskb2 != (struct sk_buff *)&sk->receive_queue;
sk4272net/ipv4/tcp.cif (before(skb2->h.th->seq, sk->acked_seq+1)) 
sk4274net/ipv4/tcp.cif (after(skb2->h.th->ack_seq, sk->acked_seq))
sk4276net/ipv4/tcp.cnewwindow = sk->window -
sk4277net/ipv4/tcp.c(skb2->h.th->ack_seq - sk->acked_seq);
sk4280net/ipv4/tcp.csk->window = newwindow;
sk4281net/ipv4/tcp.csk->acked_seq = skb2->h.th->ack_seq;
sk4290net/ipv4/tcp.ctcp_fin(skb,sk,skb->h.th);
sk4297net/ipv4/tcp.csk->ack_backlog = sk->max_ack_backlog;
sk4309net/ipv4/tcp.cif (!sk->delay_acks ||
sk4310net/ipv4/tcp.csk->ack_backlog >= sk->max_ack_backlog || 
sk4311net/ipv4/tcp.csk->bytes_rcv > sk->max_unacked || th->fin) {
sk4316net/ipv4/tcp.csk->ack_backlog++;
sk4317net/ipv4/tcp.cif(sk->debug)
sk4319net/ipv4/tcp.creset_xmit_timer(sk, TIME_WRITE, TCP_ACK_TIME);
sk4339net/ipv4/tcp.cwhile (sock_rspace(sk) < sk->mtu) 
sk4341net/ipv4/tcp.cskb1 = skb_peek(&sk->receive_queue);
sk4360net/ipv4/tcp.ctcp_send_ack(sk->sent_seq, sk->acked_seq, sk, th, saddr);
sk4361net/ipv4/tcp.csk->ack_backlog++;
sk4362net/ipv4/tcp.creset_xmit_timer(sk, TIME_WRITE, TCP_ACK_TIME);
sk4366net/ipv4/tcp.ctcp_send_ack(sk->sent_seq, sk->acked_seq, sk, th, saddr);
sk4373net/ipv4/tcp.cif (!sk->dead) 
sk4375net/ipv4/tcp.cif(sk->debug)
sk4377net/ipv4/tcp.csk->data_ready(sk,0);
sk4391net/ipv4/tcp.cstatic void tcp_check_urg(struct sock * sk, struct tcphdr * th)
sk4400net/ipv4/tcp.cif (after(sk->copied_seq, ptr))
sk4404net/ipv4/tcp.cif (sk->urg_data && !after(ptr, sk->urg_seq))
sk4408net/ipv4/tcp.cif (sk->proc != 0) {
sk4409net/ipv4/tcp.cif (sk->proc > 0) {
sk4410net/ipv4/tcp.ckill_proc(sk->proc, SIGURG, 1);
sk4412net/ipv4/tcp.ckill_pg(-sk->proc, SIGURG, 1);
sk4415net/ipv4/tcp.csk->urg_data = URG_NOTYET;
sk4416net/ipv4/tcp.csk->urg_seq = ptr;
sk4423net/ipv4/tcp.cextern __inline__ int tcp_urg(struct sock *sk, struct tcphdr *th,
sk4433net/ipv4/tcp.ctcp_check_urg(sk,th);
sk4439net/ipv4/tcp.cif (sk->urg_data != URG_NOTYET)
sk4446net/ipv4/tcp.cptr = sk->urg_seq - th->seq + th->doff*4;
sk4454net/ipv4/tcp.csk->urg_data = URG_VALID | *(ptr + (unsigned char *) th);
sk4455net/ipv4/tcp.cif (!sk->dead)
sk4456net/ipv4/tcp.csk->data_ready(sk,0);
sk4464net/ipv4/tcp.cstatic struct sock *tcp_accept(struct sock *sk, int flags)
sk4474net/ipv4/tcp.cif (sk->state != TCP_LISTEN) 
sk4476net/ipv4/tcp.csk->err = EINVAL;
sk4482net/ipv4/tcp.csk->inuse = 1;
sk4484net/ipv4/tcp.cwhile((skb = tcp_dequeue_established(sk)) == NULL) 
sk4489net/ipv4/tcp.crelease_sock(sk);
sk4490net/ipv4/tcp.csk->err = EAGAIN;
sk4494net/ipv4/tcp.crelease_sock(sk);
sk4495net/ipv4/tcp.cinterruptible_sleep_on(sk->sleep);
sk4499net/ipv4/tcp.csk->err = ERESTARTSYS;
sk4502net/ipv4/tcp.csk->inuse = 1;
sk4510net/ipv4/tcp.cnewsk = skb->sk;
sk4513net/ipv4/tcp.csk->ack_backlog--;
sk4514net/ipv4/tcp.crelease_sock(sk);
sk4523net/ipv4/tcp.cstatic int tcp_connect(struct sock *sk, struct sockaddr_in *usin, int addr_len)
sk4533net/ipv4/tcp.cif (sk->state != TCP_CLOSE) 
sk4558net/ipv4/tcp.csk->inuse = 1;
sk4559net/ipv4/tcp.csk->daddr = usin->sin_addr.s_addr;
sk4560net/ipv4/tcp.csk->write_seq = tcp_init_seq();
sk4561net/ipv4/tcp.csk->window_seq = sk->write_seq;
sk4562net/ipv4/tcp.csk->rcv_ack_seq = sk->write_seq -1;
sk4563net/ipv4/tcp.csk->err = 0;
sk4564net/ipv4/tcp.csk->dummy_th.dest = usin->sin_port;
sk4565net/ipv4/tcp.crelease_sock(sk);
sk4567net/ipv4/tcp.cbuff = sock_wmalloc(sk,MAX_SYN_SIZE,0, GFP_KERNEL);
sk4572net/ipv4/tcp.csk->inuse = 1;
sk4573net/ipv4/tcp.cbuff->sk = sk;
sk4575net/ipv4/tcp.cbuff->localroute = sk->localroute;
sk4582net/ipv4/tcp.cif (sk->localroute)
sk4583net/ipv4/tcp.crt=ip_rt_local(sk->daddr, NULL, sk->saddr ? NULL : &sk->saddr);
sk4585net/ipv4/tcp.crt=ip_rt_route(sk->daddr, NULL, sk->saddr ? NULL : &sk->saddr);
sk4591net/ipv4/tcp.csk->rcv_saddr=sk->saddr;
sk4597net/ipv4/tcp.ctmp = sk->prot->build_header(buff, sk->saddr, sk->daddr, &dev,
sk4598net/ipv4/tcp.cIPPROTO_TCP, NULL, MAX_SYN_SIZE,sk->ip_tos,sk->ip_ttl);
sk4601net/ipv4/tcp.csock_wfree(sk, buff);
sk4602net/ipv4/tcp.crelease_sock(sk);
sk4608net/ipv4/tcp.cmemcpy(t1,(void *)&(sk->dummy_th), sizeof(*t1));
sk4609net/ipv4/tcp.ct1->seq = ntohl(sk->write_seq++);
sk4610net/ipv4/tcp.csk->sent_seq = sk->write_seq;
sk4611net/ipv4/tcp.cbuff->h.seq = sk->write_seq;
sk4625net/ipv4/tcp.csk->window_clamp=rt->rt_window;
sk4627net/ipv4/tcp.csk->window_clamp=0;
sk4629net/ipv4/tcp.cif (sk->user_mss)
sk4630net/ipv4/tcp.csk->mtu = sk->user_mss;
sk4632net/ipv4/tcp.csk->mtu = rt->rt_mss;
sk4636net/ipv4/tcp.cif ((sk->saddr ^ sk->daddr) & default_mask(sk->saddr))
sk4638net/ipv4/tcp.cif ((sk->saddr ^ sk->daddr) & dev->pa_mask)
sk4640net/ipv4/tcp.csk->mtu = 576 - sizeof(struct iphdr) - sizeof(struct tcphdr);
sk4642net/ipv4/tcp.csk->mtu = MAX_WINDOW;
sk4648net/ipv4/tcp.cif(sk->mtu <32)
sk4649net/ipv4/tcp.csk->mtu = 32;  /* Sanity limit */
sk4651net/ipv4/tcp.csk->mtu = min(sk->mtu, dev->mtu - sizeof(struct iphdr) - sizeof(struct tcphdr));
sk4660net/ipv4/tcp.cptr[2] = (sk->mtu) >> 8;
sk4661net/ipv4/tcp.cptr[3] = (sk->mtu) & 0xff;
sk4662net/ipv4/tcp.ctcp_send_check(t1, sk->saddr, sk->daddr,
sk4663net/ipv4/tcp.csizeof(struct tcphdr) + 4, sk);
sk4670net/ipv4/tcp.ctcp_set_state(sk,TCP_SYN_SENT);
sk4672net/ipv4/tcp.csk->rto = rt->rt_irtt;
sk4674net/ipv4/tcp.csk->rto = TCP_TIMEOUT_INIT;
sk4675net/ipv4/tcp.csk->retransmit_timer.function=&retransmit_timer;
sk4676net/ipv4/tcp.csk->retransmit_timer.data = (unsigned long)sk;
sk4677net/ipv4/tcp.creset_xmit_timer(sk, TIME_WRITE, sk->rto);  /* Timer for repeating the SYN until an answer */
sk4678net/ipv4/tcp.csk->retransmits = 0;  /* Now works the right way instead of a hacked initial setting */
sk4680net/ipv4/tcp.csk->prot->queue_xmit(sk, dev, buff, 0);  
sk4681net/ipv4/tcp.creset_xmit_timer(sk, TIME_WRITE, sk->rto);
sk4685net/ipv4/tcp.crelease_sock(sk);
sk4691net/ipv4/tcp.cextern __inline__ int tcp_sequence(struct sock *sk, struct tcphdr *th, short len,
sk4700net/ipv4/tcp.cif (next_seq && !sk->window)
sk4712net/ipv4/tcp.cif (!after(next_seq+1, sk->acked_seq))
sk4715net/ipv4/tcp.cif (!before(th->seq, sk->acked_seq + sk->window + 1))
sk4732net/ipv4/tcp.cif (sk->state==TCP_SYN_SENT || sk->state==TCP_SYN_RECV) 
sk4734net/ipv4/tcp.ctcp_reset(sk->saddr,sk->daddr,th,sk->prot,NULL,dev, sk->ip_tos,sk->ip_ttl);
sk4739net/ipv4/tcp.ctcp_send_ack(sk->sent_seq, sk->acked_seq, sk, th, saddr);
sk4747net/ipv4/tcp.cstatic int tcp_std_reset(struct sock *sk, struct sk_buff *skb)
sk4749net/ipv4/tcp.csk->zapped = 1;
sk4750net/ipv4/tcp.csk->err = ECONNRESET;
sk4751net/ipv4/tcp.cif (sk->state == TCP_SYN_SENT)
sk4752net/ipv4/tcp.csk->err = ECONNREFUSED;
sk4753net/ipv4/tcp.cif (sk->state == TCP_CLOSE_WAIT)
sk4754net/ipv4/tcp.csk->err = EPIPE;
sk4759net/ipv4/tcp.cif(sk->state!=TCP_TIME_WAIT)
sk4761net/ipv4/tcp.ctcp_set_state(sk,TCP_CLOSE);
sk4762net/ipv4/tcp.csk->shutdown = SHUTDOWN_MASK;
sk4765net/ipv4/tcp.ctcp_set_state(sk,TCP_CLOSE);
sk4766net/ipv4/tcp.csk->shutdown = SHUTDOWN_MASK;
sk4768net/ipv4/tcp.cif (!sk->dead) 
sk4769net/ipv4/tcp.csk->state_change(sk);
sk4771net/ipv4/tcp.crelease_sock(sk);
sk4785net/ipv4/tcp.cstruct sock *sk;
sk4803net/ipv4/tcp.csk=(struct sock *)th_cache_sk;
sk4807net/ipv4/tcp.cif(sk!=get_sock(&tcp_prot,th->dest, saddr, th->source, daddr))
sk4812net/ipv4/tcp.csk = get_sock(&tcp_prot, th->dest, saddr, th->source, daddr);
sk4817net/ipv4/tcp.cth_cache_sk=sk;
sk4829net/ipv4/tcp.cif (sk!=NULL && (sk->zapped || sk->state==TCP_CLOSE))
sk4830net/ipv4/tcp.csk=NULL;
sk4846net/ipv4/tcp.cskb->sk = NULL;
sk4857net/ipv4/tcp.cif (sk == NULL) 
sk4863net/ipv4/tcp.cskb->sk = NULL;
sk4880net/ipv4/tcp.cif (sk->inuse) 
sk4882net/ipv4/tcp.cskb_queue_tail(&sk->back_log, skb);
sk4886net/ipv4/tcp.csk->inuse = 1;
sk4891net/ipv4/tcp.cif (sk==NULL) 
sk4894net/ipv4/tcp.cskb->sk = NULL;
sk4901net/ipv4/tcp.cif (!sk->prot) 
sk4912net/ipv4/tcp.cif (sk->rmem_alloc + skb->truesize >= sk->rcvbuf) 
sk4915net/ipv4/tcp.crelease_sock(sk);
sk4919net/ipv4/tcp.cskb->sk=sk;
sk4920net/ipv4/tcp.csk->rmem_alloc += skb->truesize;
sk4929net/ipv4/tcp.cif(sk->state!=TCP_ESTABLISHED)    /* Skip this lot for normal flow */
sk4936net/ipv4/tcp.cif(sk->state==TCP_LISTEN)
sk4939net/ipv4/tcp.ctcp_reset(daddr,saddr,th,sk->prot,opt,dev,sk->ip_tos, sk->ip_ttl);
sk4951net/ipv4/tcp.crelease_sock(sk);
sk4959net/ipv4/tcp.ctcp_conn_request(sk, skb, daddr, saddr, opt, dev, tcp_init_seq());
sk4970net/ipv4/tcp.crelease_sock(sk);
sk4975net/ipv4/tcp.cif (sk->state == TCP_SYN_RECV && th->syn && th->seq+1 == sk->acked_seq)
sk4978net/ipv4/tcp.crelease_sock(sk);
sk4987net/ipv4/tcp.cif(sk->state==TCP_SYN_SENT)
sk4993net/ipv4/tcp.cif(!tcp_ack(sk,th,saddr,len))
sk4999net/ipv4/tcp.csk->prot, opt,dev,sk->ip_tos,sk->ip_ttl);
sk5001net/ipv4/tcp.crelease_sock(sk);
sk5005net/ipv4/tcp.creturn tcp_std_reset(sk,skb);
sk5011net/ipv4/tcp.crelease_sock(sk);
sk5019net/ipv4/tcp.csk->acked_seq=th->seq+1;
sk5020net/ipv4/tcp.csk->fin_seq=th->seq;
sk5021net/ipv4/tcp.ctcp_send_ack(sk->sent_seq,sk->acked_seq,sk,th,sk->daddr);
sk5022net/ipv4/tcp.ctcp_set_state(sk, TCP_ESTABLISHED);
sk5023net/ipv4/tcp.ctcp_options(sk,th);
sk5024net/ipv4/tcp.csk->dummy_th.dest=th->source;
sk5025net/ipv4/tcp.csk->copied_seq = sk->acked_seq;
sk5026net/ipv4/tcp.cif(!sk->dead)
sk5028net/ipv4/tcp.csk->state_change(sk);
sk5029net/ipv4/tcp.csock_wake_async(sk->socket, 0);
sk5031net/ipv4/tcp.cif(sk->max_window==0)
sk5033net/ipv4/tcp.csk->max_window = 32;
sk5034net/ipv4/tcp.csk->mss = min(sk->max_window, sk->mtu);
sk5044net/ipv4/tcp.cif(sk->saddr==saddr && sk->daddr==daddr &&
sk5045net/ipv4/tcp.csk->dummy_th.source==th->source &&
sk5046net/ipv4/tcp.csk->dummy_th.dest==th->dest)
sk5049net/ipv4/tcp.creturn tcp_std_reset(sk,skb);
sk5051net/ipv4/tcp.ctcp_set_state(sk,TCP_SYN_RECV);
sk5060net/ipv4/tcp.crelease_sock(sk);
sk5077net/ipv4/tcp.cif (sk->state == TCP_TIME_WAIT && th->syn && sk->dead && 
sk5078net/ipv4/tcp.cafter(th->seq, sk->acked_seq) && !th->rst)
sk5080net/ipv4/tcp.cu32 seq = sk->write_seq;
sk5081net/ipv4/tcp.cif(sk->debug)
sk5084net/ipv4/tcp.csk->rmem_alloc -= skb->truesize;
sk5085net/ipv4/tcp.cskb->sk = NULL;
sk5086net/ipv4/tcp.csk->err=ECONNRESET;
sk5087net/ipv4/tcp.ctcp_set_state(sk, TCP_CLOSE);
sk5088net/ipv4/tcp.csk->shutdown = SHUTDOWN_MASK;
sk5089net/ipv4/tcp.crelease_sock(sk);
sk5090net/ipv4/tcp.csk=get_sock(&tcp_prot, th->dest, saddr, th->source, daddr);
sk5091net/ipv4/tcp.cif (sk && sk->state==TCP_LISTEN)
sk5093net/ipv4/tcp.csk->inuse=1;
sk5094net/ipv4/tcp.cskb->sk = sk;
sk5095net/ipv4/tcp.csk->rmem_alloc += skb->truesize;
sk5096net/ipv4/tcp.ctcp_conn_request(sk, skb, daddr, saddr,opt, dev,seq+128000);
sk5097net/ipv4/tcp.crelease_sock(sk);
sk5112net/ipv4/tcp.cif(!tcp_sequence(sk,th,len,opt,saddr,dev))
sk5115net/ipv4/tcp.crelease_sock(sk);
sk5120net/ipv4/tcp.creturn tcp_std_reset(sk,skb);
sk5129net/ipv4/tcp.creturn tcp_std_reset(sk,skb);  
sk5137net/ipv4/tcp.cif(th->ack && !tcp_ack(sk,th,saddr,len))
sk5143net/ipv4/tcp.cif(sk->state==TCP_SYN_RECV)
sk5145net/ipv4/tcp.ctcp_reset(daddr, saddr, th,sk->prot, opt, dev,sk->ip_tos,sk->ip_ttl);
sk5148net/ipv4/tcp.crelease_sock(sk);
sk5158net/ipv4/tcp.cif(tcp_urg(sk, th, saddr, len))
sk5161net/ipv4/tcp.crelease_sock(sk);
sk5170net/ipv4/tcp.cif(tcp_data(skb,sk, saddr, len))
sk5173net/ipv4/tcp.crelease_sock(sk);
sk5181net/ipv4/tcp.crelease_sock(sk);
sk5190net/ipv4/tcp.cstatic void tcp_write_wakeup(struct sock *sk)
sk5197net/ipv4/tcp.cif (sk->zapped)
sk5206net/ipv4/tcp.cif (sk->state != TCP_ESTABLISHED && 
sk5207net/ipv4/tcp.csk->state != TCP_CLOSE_WAIT &&
sk5208net/ipv4/tcp.csk->state != TCP_FIN_WAIT1 && 
sk5209net/ipv4/tcp.csk->state != TCP_LAST_ACK &&
sk5210net/ipv4/tcp.csk->state != TCP_CLOSING
sk5215net/ipv4/tcp.cif ( before(sk->sent_seq, sk->window_seq) && 
sk5216net/ipv4/tcp.c(skb=skb_peek(&sk->write_queue)))
sk5237net/ipv4/tcp.cwin_size = sk->window_seq - sk->sent_seq;
sk5250net/ipv4/tcp.cbuff = sock_wmalloc(sk, win_size + th->doff * 4 + 
sk5252net/ipv4/tcp.csk->prot->max_header + 15, 
sk5264net/ipv4/tcp.cbuff->sk = sk;
sk5265net/ipv4/tcp.cbuff->localroute = sk->localroute;
sk5271net/ipv4/tcp.ctmp = sk->prot->build_header(buff, sk->saddr, sk->daddr, &dev,
sk5272net/ipv4/tcp.cIPPROTO_TCP, sk->opt, buff->truesize,
sk5273net/ipv4/tcp.csk->ip_tos,sk->ip_ttl);
sk5276net/ipv4/tcp.csock_wfree(sk, buff);
sk5295net/ipv4/tcp.cnth->ack_seq = ntohl(sk->acked_seq);
sk5296net/ipv4/tcp.cnth->window = ntohs(tcp_select_window(sk));
sk5315net/ipv4/tcp.cbuff->h.seq = sk->sent_seq + win_size;
sk5316net/ipv4/tcp.csk->sent_seq = buff->h.seq;    /* Hack */
sk5329net/ipv4/tcp.csk->sent_seq += win_size;
sk5330net/ipv4/tcp.cth->seq = htonl(sk->sent_seq);
sk5354net/ipv4/tcp.ctcp_send_check(nth, sk->saddr, sk->daddr, 
sk5355net/ipv4/tcp.cnth->doff * 4 + win_size , sk);
sk5359net/ipv4/tcp.cbuff = sock_wmalloc(sk,MAX_ACK_SIZE,1, GFP_ATOMIC);
sk5364net/ipv4/tcp.cbuff->sk = sk;
sk5365net/ipv4/tcp.cbuff->localroute = sk->localroute;
sk5371net/ipv4/tcp.ctmp = sk->prot->build_header(buff, sk->saddr, sk->daddr, &dev,
sk5372net/ipv4/tcp.cIPPROTO_TCP, sk->opt, MAX_ACK_SIZE,sk->ip_tos,sk->ip_ttl);
sk5375net/ipv4/tcp.csock_wfree(sk, buff);
sk5380net/ipv4/tcp.cmemcpy(t1,(void *) &sk->dummy_th, sizeof(*t1));
sk5387net/ipv4/tcp.ct1->seq = htonl(sk->sent_seq-1);
sk5396net/ipv4/tcp.ct1->ack_seq = ntohl(sk->acked_seq);
sk5397net/ipv4/tcp.ct1->window = ntohs(tcp_select_window(sk));
sk5399net/ipv4/tcp.ctcp_send_check(t1, sk->saddr, sk->daddr, sizeof(*t1), sk);
sk5407net/ipv4/tcp.csk->prot->queue_xmit(sk, dev, buff, 1);
sk5415net/ipv4/tcp.cvoid tcp_send_probe0(struct sock *sk)
sk5417net/ipv4/tcp.cif (sk->zapped)
sk5420net/ipv4/tcp.ctcp_write_wakeup(sk);
sk5422net/ipv4/tcp.csk->backoff++;
sk5423net/ipv4/tcp.csk->rto = min(sk->rto << 1, 120*HZ);
sk5424net/ipv4/tcp.creset_xmit_timer (sk, TIME_PROBE0, sk->rto);
sk5425net/ipv4/tcp.csk->retransmits++;
sk5426net/ipv4/tcp.csk->prot->retransmits ++;
sk5433net/ipv4/tcp.cint tcp_setsockopt(struct sock *sk, int level, int optname, char *optval, int optlen)
sk5438net/ipv4/tcp.creturn ip_setsockopt(sk,level,optname,optval,optlen);
sk5459net/ipv4/tcp.csk->user_mss=val;
sk5462net/ipv4/tcp.csk->nonagle=(val==0)?0:1;
sk5469net/ipv4/tcp.cint tcp_getsockopt(struct sock *sk, int level, int optname, char *optval, int *optlen)
sk5474net/ipv4/tcp.creturn ip_getsockopt(sk,level,optname,optval,optlen);
sk5479net/ipv4/tcp.cval=sk->user_mss;
sk5482net/ipv4/tcp.cval=sk->nonagle;
sk88net/ipv4/timer.cstruct sock *sk = (struct sock*)data;
sk89net/ipv4/timer.cint why = sk->timeout;
sk96net/ipv4/timer.cif (sk->inuse || in_bh) 
sk98net/ipv4/timer.csk->timer.expires = jiffies+10;
sk99net/ipv4/timer.cadd_timer(&sk->timer);
sk104net/ipv4/timer.csk->inuse = 1;
sk109net/ipv4/timer.cif (sk->ack_backlog && !sk->zapped) 
sk111net/ipv4/timer.csk->prot->read_wakeup (sk);
sk112net/ipv4/timer.cif (! sk->dead)
sk113net/ipv4/timer.csk->data_ready(sk,0);
sk121net/ipv4/timer.cif (! sk->dead || sk->state != TCP_CLOSE) 
sk124net/ipv4/timer.crelease_sock (sk);
sk127net/ipv4/timer.cdestroy_sock (sk);
sk135net/ipv4/timer.cif(sk->wmem_alloc!=0 || sk->rmem_alloc!=0)
sk137net/ipv4/timer.csk->wmem_alloc++;  /* So it DOESN'T go away */
sk138net/ipv4/timer.cdestroy_sock (sk);
sk139net/ipv4/timer.csk->wmem_alloc--;  /* Might now have hit 0 - fall through and do it again if so */
sk140net/ipv4/timer.csk->inuse = 0;  /* This will be ok, the destroy won't totally work */
sk142net/ipv4/timer.cif(sk->wmem_alloc==0 && sk->rmem_alloc==0)
sk143net/ipv4/timer.cdestroy_sock(sk);  /* Socket gone, DON'T update sk->inuse! */
sk147net/ipv4/timer.csk->state = TCP_CLOSE;
sk148net/ipv4/timer.cdelete_timer (sk);
sk150net/ipv4/timer.carp_destroy (sk->daddr, 0);
sk151net/ipv4/timer.cif (!sk->dead)
sk152net/ipv4/timer.csk->state_change(sk);
sk153net/ipv4/timer.csk->shutdown = SHUTDOWN_MASK;
sk154net/ipv4/timer.creset_timer (sk, TIME_DESTROY, TCP_DONE_TIME);
sk155net/ipv4/timer.crelease_sock (sk);
sk159net/ipv4/timer.crelease_sock (sk);
sk138net/ipv4/udp.cstatic int udp_deliver(struct sock *sk, struct udphdr *uh, struct sk_buff *skb, struct device *dev, long saddr, long daddr, int len);
sk158net/ipv4/udp.cstruct sock *sk;
sk166net/ipv4/udp.csk = get_sock(&udp_prot, uh->source, daddr, uh->dest, saddr);
sk168net/ipv4/udp.cif (sk == NULL) 
sk173net/ipv4/udp.cif (sk->cong_window > 1) 
sk174net/ipv4/udp.csk->cong_window = sk->cong_window/2;
sk180net/ipv4/udp.csk->err = EPROTO;
sk181net/ipv4/udp.csk->error_report(sk);
sk199net/ipv4/udp.csk->err = icmp_err_convert[code].errno;
sk200net/ipv4/udp.csk->error_report(sk);
sk294net/ipv4/udp.cstatic int udp_send(struct sock *sk, struct sockaddr_in *sin,
sk305net/ipv4/udp.cufh.uh.source = sk->dummy_th.source;
sk319net/ipv4/udp.cif(sk->no_check)
sk320net/ipv4/udp.ca = ip_build_xmit(sk, udp_getfrag_nosum, &ufh, ulen, 
sk321net/ipv4/udp.csin->sin_addr.s_addr, saddr, sk->opt, rt, IPPROTO_UDP, noblock);
sk323net/ipv4/udp.ca = ip_build_xmit(sk, udp_getfrag, &ufh, ulen, 
sk324net/ipv4/udp.csin->sin_addr.s_addr, saddr, sk->opt, rt, IPPROTO_UDP, noblock);
sk332net/ipv4/udp.cstatic int udp_sendto(struct sock *sk, const unsigned char *from, int len, int noblock,
sk360net/ipv4/udp.cif (sk->state != TCP_ESTABLISHED) 
sk363net/ipv4/udp.csin.sin_port = sk->dummy_th.dest;
sk364net/ipv4/udp.csin.sin_addr.s_addr = sk->daddr;
sk386net/ipv4/udp.cif(!sk->broadcast && ip_chk_addr(usin->sin_addr.s_addr)==IS_BROADCAST)
sk389net/ipv4/udp.csk->inuse = 1;
sk392net/ipv4/udp.ctmp = udp_send(sk, usin, from, len, flags, saddr, noblock);
sk395net/ipv4/udp.crelease_sock(sk);
sk403net/ipv4/udp.cstatic int udp_write(struct sock *sk, const unsigned char *buff, int len, int noblock,
sk406net/ipv4/udp.creturn(udp_sendto(sk, buff, len, noblock, flags, NULL, 0));
sk414net/ipv4/udp.cint udp_ioctl(struct sock *sk, int cmd, unsigned long arg)
sk423net/ipv4/udp.cif (sk->state == TCP_LISTEN) return(-EINVAL);
sk424net/ipv4/udp.camount = sock_wspace(sk);
sk438net/ipv4/udp.cif (sk->state == TCP_LISTEN) return(-EINVAL);
sk440net/ipv4/udp.cskb = skb_peek(&sk->receive_queue);
sk469net/ipv4/udp.cint udp_recvmsg(struct sock *sk, struct msghdr *msg, int len,
sk490net/ipv4/udp.cskb=skb_recv_datagram(sk,flags,noblock,&er);
sk502net/ipv4/udp.csk->stamp=skb->stamp;
sk513net/ipv4/udp.crelease_sock(sk);
sk517net/ipv4/udp.cint udp_recvfrom(struct sock *sk, unsigned char *ubuf, int size, int noblock, unsigned flags,
sk534net/ipv4/udp.creturn udp_recvmsg(sk, &msg, size, noblock, flags, addr_len);
sk542net/ipv4/udp.cint udp_read(struct sock *sk, unsigned char *buff, int len, int noblock,
sk545net/ipv4/udp.creturn(udp_recvfrom(sk, buff, len, noblock, flags, NULL, NULL));
sk549net/ipv4/udp.cint udp_connect(struct sock *sk, struct sockaddr_in *usin, int addr_len)
sk561net/ipv4/udp.cif(!sk->broadcast && ip_chk_addr(usin->sin_addr.s_addr)==IS_BROADCAST)
sk564net/ipv4/udp.crt=(sk->localroute?ip_rt_local:ip_rt_route)((__u32)usin->sin_addr.s_addr, NULL, &sa);
sk567net/ipv4/udp.cif(!sk->saddr)
sk568net/ipv4/udp.csk->saddr = sa;    /* Update source address */
sk569net/ipv4/udp.cif(!sk->rcv_saddr)
sk570net/ipv4/udp.csk->rcv_saddr = sa;
sk571net/ipv4/udp.csk->daddr = usin->sin_addr.s_addr;
sk572net/ipv4/udp.csk->dummy_th.dest = usin->sin_port;
sk573net/ipv4/udp.csk->state = TCP_ESTABLISHED;
sk575net/ipv4/udp.csk->ip_route_cache = rt;
sk576net/ipv4/udp.csk->ip_route_stamp = rt_stamp;
sk581net/ipv4/udp.cstatic void udp_close(struct sock *sk, int timeout)
sk583net/ipv4/udp.csk->inuse = 1;
sk584net/ipv4/udp.csk->state = TCP_CLOSE;
sk585net/ipv4/udp.cif(uh_cache_sk==sk)
sk587net/ipv4/udp.cif (sk->dead) 
sk588net/ipv4/udp.cdestroy_sock(sk);
sk590net/ipv4/udp.crelease_sock(sk);
sk602net/ipv4/udp.cstruct sock *sk;
sk670net/ipv4/udp.csk=get_sock_mcast(udp_prot.sock_array[ntohs(uh->dest)&(SOCK_ARRAY_SIZE-1)], uh->dest,
sk672net/ipv4/udp.cif(sk)
sk678net/ipv4/udp.csknext=get_sock_mcast(sk->next, uh->dest, saddr, uh->source, daddr);
sk684net/ipv4/udp.cudp_deliver(sk, uh, skb1, dev,saddr,daddr,len);
sk685net/ipv4/udp.csk=sknext;
sk695net/ipv4/udp.csk=(struct sock *)uh_cache_sk;
sk698net/ipv4/udp.csk = get_sock(&udp_prot, uh->dest, saddr, uh->source, daddr);
sk703net/ipv4/udp.cuh_cache_sk=sk;
sk706net/ipv4/udp.cif (sk == NULL) 
sk717net/ipv4/udp.cskb->sk = NULL;
sk721net/ipv4/udp.creturn udp_deliver(sk,uh,skb,dev, saddr, daddr, len);
sk724net/ipv4/udp.cstatic int udp_deliver(struct sock *sk, struct udphdr *uh, struct sk_buff *skb, struct device *dev, long saddr, long daddr, int len)
sk726net/ipv4/udp.cskb->sk = sk;
sk745net/ipv4/udp.cif (sock_queue_rcv_skb(sk,skb)<0) 
sk750net/ipv4/udp.cskb->sk = NULL;
sk752net/ipv4/udp.crelease_sock(sk);
sk756net/ipv4/udp.crelease_sock(sk);
sk136net/ipx/af_ipx.cipx_remove_socket(ipx_socket *sk)
sk146net/ipx/af_ipx.cintrfc = sk->ipx_intrfc;
sk153net/ipx/af_ipx.cif(s==sk) {
sk160net/ipx/af_ipx.cif(s->next==sk) {
sk161net/ipx/af_ipx.cs->next=sk->next;
sk178net/ipx/af_ipx.cipx_destroy_socket(ipx_socket *sk)
sk182net/ipx/af_ipx.cipx_remove_socket(sk);
sk183net/ipx/af_ipx.cwhile((skb=skb_dequeue(&sk->receive_queue))!=NULL) {
sk187net/ipx/af_ipx.ckfree_s(sk,sizeof(*sk));
sk233net/ipx/af_ipx.cipxitf_insert_socket(ipx_interface *intrfc, ipx_socket *sk)
sk237net/ipx/af_ipx.csk->ipx_intrfc = intrfc;
sk238net/ipx/af_ipx.csk->next = NULL;
sk240net/ipx/af_ipx.cintrfc->if_sklist = sk;
sk244net/ipx/af_ipx.cs->next = sk;
sk533net/ipx/af_ipx.cif (skb->sk != NULL) {
sk537net/ipx/af_ipx.cskb->sk->wmem_alloc += skb->truesize;
sk1024net/ipx/af_ipx.cstatic int ipxrtr_route_packet(ipx_socket *sk, struct sockaddr_ipx *usipx, struct iovec *iov, int len)
sk1053net/ipx/af_ipx.cskb=sock_alloc_send_skb(sk, size, 0, 0, &err);
sk1069net/ipx/af_ipx.cipx->ipx_source.net = sk->ipx_intrfc->if_netnum;
sk1070net/ipx/af_ipx.cmemcpy(ipx->ipx_source.node, sk->ipx_intrfc->if_node, IPX_NODE_LEN);
sk1071net/ipx/af_ipx.cipx->ipx_source.sock = sk->ipx_port;
sk1328net/ipx/af_ipx.cipx_socket *sk;
sk1331net/ipx/af_ipx.csk=(ipx_socket *)sock->data;
sk1347net/ipx/af_ipx.csk->ipx_type=opt;
sk1355net/ipx/af_ipx.creturn sock_setsockopt(sk,level,optname,optval,optlen);
sk1365net/ipx/af_ipx.cipx_socket *sk;
sk1369net/ipx/af_ipx.csk=(ipx_socket *)sock->data;
sk1378net/ipx/af_ipx.cval=sk->ipx_type;
sk1386net/ipx/af_ipx.creturn sock_getsockopt(sk,level,optname,optval,optlen);
sk1405net/ipx/af_ipx.cstatic void def_callback1(struct sock *sk)
sk1407net/ipx/af_ipx.cif(!sk->dead)
sk1408net/ipx/af_ipx.cwake_up_interruptible(sk->sleep);
sk1411net/ipx/af_ipx.cstatic void def_callback2(struct sock *sk, int len)
sk1413net/ipx/af_ipx.cif(!sk->dead)
sk1415net/ipx/af_ipx.cwake_up_interruptible(sk->sleep);
sk1416net/ipx/af_ipx.csock_wake_async(sk->socket, 1);
sk1423net/ipx/af_ipx.cipx_socket *sk;
sk1424net/ipx/af_ipx.csk=(ipx_socket *)kmalloc(sizeof(*sk),GFP_KERNEL);
sk1425net/ipx/af_ipx.cif(sk==NULL)
sk1432net/ipx/af_ipx.ckfree_s((void *)sk,sizeof(*sk));
sk1435net/ipx/af_ipx.csk->dead=0;
sk1436net/ipx/af_ipx.csk->next=NULL;
sk1437net/ipx/af_ipx.csk->broadcast=0;
sk1438net/ipx/af_ipx.csk->rcvbuf=SK_RMEM_MAX;
sk1439net/ipx/af_ipx.csk->sndbuf=SK_WMEM_MAX;
sk1440net/ipx/af_ipx.csk->wmem_alloc=0;
sk1441net/ipx/af_ipx.csk->rmem_alloc=0;
sk1442net/ipx/af_ipx.csk->inuse=0;
sk1443net/ipx/af_ipx.csk->shutdown=0;
sk1444net/ipx/af_ipx.csk->prot=NULL;  /* So we use default free mechanisms */
sk1445net/ipx/af_ipx.csk->err=0;
sk1446net/ipx/af_ipx.cskb_queue_head_init(&sk->receive_queue);
sk1447net/ipx/af_ipx.cskb_queue_head_init(&sk->write_queue);
sk1448net/ipx/af_ipx.csk->send_head=NULL;
sk1449net/ipx/af_ipx.cskb_queue_head_init(&sk->back_log);
sk1450net/ipx/af_ipx.csk->state=TCP_CLOSE;
sk1451net/ipx/af_ipx.csk->socket=sock;
sk1452net/ipx/af_ipx.csk->type=sock->type;
sk1453net/ipx/af_ipx.csk->ipx_type=0;    /* General user level IPX */
sk1454net/ipx/af_ipx.csk->debug=0;
sk1455net/ipx/af_ipx.csk->ipx_intrfc = NULL;
sk1456net/ipx/af_ipx.cmemset(&sk->ipx_dest_addr,'\0',sizeof(sk->ipx_dest_addr));
sk1457net/ipx/af_ipx.csk->ipx_port = 0;
sk1458net/ipx/af_ipx.csk->mtu=IPX_MTU;
sk1462net/ipx/af_ipx.csock->data=(void *)sk;
sk1463net/ipx/af_ipx.csk->sleep=sock->wait;
sk1466net/ipx/af_ipx.csk->state_change=def_callback1;
sk1467net/ipx/af_ipx.csk->data_ready=def_callback2;
sk1468net/ipx/af_ipx.csk->write_space=def_callback1;
sk1469net/ipx/af_ipx.csk->error_report=def_callback1;
sk1471net/ipx/af_ipx.csk->zapped=1;
sk1477net/ipx/af_ipx.cipx_socket *sk=(ipx_socket *)sock->data;
sk1478net/ipx/af_ipx.cif(sk==NULL)
sk1480net/ipx/af_ipx.cif(!sk->dead)
sk1481net/ipx/af_ipx.csk->state_change(sk);
sk1482net/ipx/af_ipx.csk->dead=1;
sk1484net/ipx/af_ipx.cipx_destroy_socket(sk);
sk1513net/ipx/af_ipx.cipx_socket *sk;
sk1517net/ipx/af_ipx.csk=(ipx_socket *)sock->data;
sk1519net/ipx/af_ipx.cif(sk->zapped==0)
sk1542net/ipx/af_ipx.cif(sk->debug)
sk1548net/ipx/af_ipx.csk->ipx_port=addr->sipx_port;
sk1549net/ipx/af_ipx.cipxitf_insert_socket(intrfc, sk);
sk1550net/ipx/af_ipx.csk->zapped=0;
sk1551net/ipx/af_ipx.cif(sk->debug)
sk1559net/ipx/af_ipx.cipx_socket *sk=(ipx_socket *)sock->data;
sk1562net/ipx/af_ipx.csk->state = TCP_CLOSE;  
sk1569net/ipx/af_ipx.cif(sk->ipx_port==0)
sk1583net/ipx/af_ipx.csk->ipx_dest_addr.net=addr->sipx_network;
sk1584net/ipx/af_ipx.csk->ipx_dest_addr.sock=addr->sipx_port;
sk1585net/ipx/af_ipx.cmemcpy(sk->ipx_dest_addr.node,addr->sipx_node,IPX_NODE_LEN);
sk1586net/ipx/af_ipx.csk->ipx_type=addr->sipx_type;
sk1588net/ipx/af_ipx.csk->state=TCP_ESTABLISHED;
sk1609net/ipx/af_ipx.cipx_socket *sk;
sk1611net/ipx/af_ipx.csk=(ipx_socket *)sock->data;
sk1616net/ipx/af_ipx.cif(sk->state!=TCP_ESTABLISHED)
sk1618net/ipx/af_ipx.caddr=&sk->ipx_dest_addr;
sk1623net/ipx/af_ipx.cif (sk->ipx_intrfc != NULL) {
sk1624net/ipx/af_ipx.csipx.sipx_network = sk->ipx_intrfc->if_netnum;
sk1625net/ipx/af_ipx.cmemcpy(sipx.sipx_node, sk->ipx_intrfc->if_node,
sk1631net/ipx/af_ipx.csipx.sipx_port = sk->ipx_port;
sk1635net/ipx/af_ipx.csipx.sipx_type = sk->ipx_type;
sk1740net/ipx/af_ipx.cipx_socket *sk=(ipx_socket *)sock->data;
sk1745net/ipx/af_ipx.cif (sk->zapped) return -EIO; /* Socket not bound */
sk1749net/ipx/af_ipx.cif(sk->ipx_port == 0) {
sk1764net/ipx/af_ipx.cif(sk->state!=TCP_ESTABLISHED)
sk1768net/ipx/af_ipx.cusipx->sipx_type=sk->ipx_type;
sk1769net/ipx/af_ipx.cusipx->sipx_port=sk->ipx_dest_addr.sock;
sk1770net/ipx/af_ipx.cusipx->sipx_network=sk->ipx_dest_addr.net;
sk1771net/ipx/af_ipx.cmemcpy(usipx->sipx_node,sk->ipx_dest_addr.node,IPX_NODE_LEN);
sk1774net/ipx/af_ipx.cretval = ipxrtr_route_packet(sk, usipx, msg->msg_iov, len);
sk1806net/ipx/af_ipx.cipx_socket *sk=(ipx_socket *)sock->data;
sk1814net/ipx/af_ipx.cif(sk->err)
sk1816net/ipx/af_ipx.cer= -sk->err;
sk1817net/ipx/af_ipx.csk->err=0;
sk1821net/ipx/af_ipx.cif (sk->zapped)
sk1825net/ipx/af_ipx.cskb=skb_recv_datagram(sk,flags,noblock,&er);
sk1877net/ipx/af_ipx.cipx_socket *sk=(ipx_socket *)sock->data;
sk1878net/ipx/af_ipx.cif(sk->zapped)
sk1889net/ipx/af_ipx.cstatic int ipx_shutdown(struct socket *sk,int how)
sk1896net/ipx/af_ipx.cipx_socket *sk=(ipx_socket *)sock->data;
sk1898net/ipx/af_ipx.creturn datagram_select(sk,sel_type,wait);
sk1905net/ipx/af_ipx.cipx_socket *sk=(ipx_socket *)sock->data;
sk1913net/ipx/af_ipx.camount=sk->sndbuf-sk->wmem_alloc;
sk1922net/ipx/af_ipx.cif((skb=skb_peek(&sk->receive_queue))!=NULL)
sk1950net/ipx/af_ipx.cif (sk)
sk1952net/ipx/af_ipx.cif(sk->stamp.tv_sec==0)
sk1957net/ipx/af_ipx.cmemcpy_tofs((void *)arg,&sk->stamp,sizeof(struct timeval));
sk76net/netrom/af_netrom.cstatic void nr_remove_socket(struct sock *sk)
sk84net/netrom/af_netrom.cif ((s = nr_list) == sk) {
sk91net/netrom/af_netrom.cif (s->next == sk) {
sk92net/netrom/af_netrom.cs->next = sk->next;
sk141net/netrom/af_netrom.cstatic void nr_insert_socket(struct sock *sk)
sk148net/netrom/af_netrom.csk->next = nr_list;
sk149net/netrom/af_netrom.cnr_list  = sk;
sk242net/netrom/af_netrom.cvoid nr_destroy_socket(struct sock *sk)  /* Not static as its used by the timer */
sk250net/netrom/af_netrom.cdel_timer(&sk->timer);
sk252net/netrom/af_netrom.cnr_remove_socket(sk);
sk253net/netrom/af_netrom.cnr_clear_queues(sk);    /* Flush the queues */
sk255net/netrom/af_netrom.cwhile ((skb = skb_dequeue(&sk->receive_queue)) != NULL) {
sk256net/netrom/af_netrom.cif (skb->sk != sk) {      /* A pending connection */
sk257net/netrom/af_netrom.cskb->sk->dead = 1;  /* Queue the unaccepted socket for death */
sk258net/netrom/af_netrom.cnr_set_timer(skb->sk);
sk259net/netrom/af_netrom.cskb->sk->nr->state = NR_STATE_0;
sk265net/netrom/af_netrom.cif (sk->wmem_alloc || sk->rmem_alloc) { /* Defer: outstanding buffers */
sk266net/netrom/af_netrom.cinit_timer(&sk->timer);
sk267net/netrom/af_netrom.csk->timer.expires  = jiffies + 10 * HZ;
sk268net/netrom/af_netrom.csk->timer.function = nr_destroy_timer;
sk269net/netrom/af_netrom.csk->timer.data     = (unsigned long)sk;
sk270net/netrom/af_netrom.cadd_timer(&sk->timer);
sk272net/netrom/af_netrom.ckfree_s(sk->nr, sizeof(*sk->nr));
sk273net/netrom/af_netrom.ckfree_s(sk, sizeof(*sk));
sk297net/netrom/af_netrom.cstruct sock *sk;
sk300net/netrom/af_netrom.csk = (struct sock *)sock->data;
sk303net/netrom/af_netrom.creturn sock_setsockopt(sk, level, optname, optval, optlen);
sk320net/netrom/af_netrom.csk->nr->rtt = (opt * PR_SLOWHZ) / 2;
sk326net/netrom/af_netrom.csk->nr->t2 = opt * PR_SLOWHZ;
sk332net/netrom/af_netrom.csk->nr->n2 = opt;
sk336net/netrom/af_netrom.csk->nr->hdrincl = opt ? 1 : 0;
sk347net/netrom/af_netrom.cstruct sock *sk;
sk351net/netrom/af_netrom.csk = (struct sock *)sock->data;
sk354net/netrom/af_netrom.creturn sock_getsockopt(sk, level, optname, optval, optlen);
sk361net/netrom/af_netrom.cval = (sk->nr->t1 * 2) / PR_SLOWHZ;
sk365net/netrom/af_netrom.cval = sk->nr->t2 / PR_SLOWHZ;
sk369net/netrom/af_netrom.cval = sk->nr->n2;
sk373net/netrom/af_netrom.cval = sk->nr->hdrincl;
sk395net/netrom/af_netrom.cstruct sock *sk = (struct sock *)sock->data;
sk397net/netrom/af_netrom.cif (sk->type == SOCK_SEQPACKET && sk->state != TCP_LISTEN) {
sk398net/netrom/af_netrom.cmemset(&sk->nr->user_addr, '\0', sizeof(ax25_address));
sk399net/netrom/af_netrom.csk->max_ack_backlog = backlog;
sk400net/netrom/af_netrom.csk->state           = TCP_LISTEN;
sk407net/netrom/af_netrom.cstatic void def_callback1(struct sock *sk)
sk409net/netrom/af_netrom.cif (!sk->dead)
sk410net/netrom/af_netrom.cwake_up_interruptible(sk->sleep);
sk413net/netrom/af_netrom.cstatic void def_callback2(struct sock *sk, int len)
sk415net/netrom/af_netrom.cif (!sk->dead)
sk416net/netrom/af_netrom.cwake_up_interruptible(sk->sleep);
sk421net/netrom/af_netrom.cstruct sock *sk;
sk427net/netrom/af_netrom.cif ((sk = (struct sock *)kmalloc(sizeof(*sk), GFP_ATOMIC)) == NULL)
sk431net/netrom/af_netrom.ckfree_s(sk, sizeof(*sk));
sk435net/netrom/af_netrom.cskb_queue_head_init(&sk->receive_queue);
sk436net/netrom/af_netrom.cskb_queue_head_init(&sk->write_queue);
sk437net/netrom/af_netrom.cskb_queue_head_init(&sk->back_log);
sk439net/netrom/af_netrom.cinit_timer(&sk->timer);
sk441net/netrom/af_netrom.csk->socket        = sock;
sk442net/netrom/af_netrom.csk->type          = sock->type;
sk443net/netrom/af_netrom.csk->protocol      = protocol;
sk444net/netrom/af_netrom.csk->dead          = 0;
sk445net/netrom/af_netrom.csk->next          = NULL;
sk446net/netrom/af_netrom.csk->broadcast     = 0;
sk447net/netrom/af_netrom.csk->allocation    = GFP_KERNEL;
sk448net/netrom/af_netrom.csk->rcvbuf        = SK_RMEM_MAX;
sk449net/netrom/af_netrom.csk->sndbuf        = SK_WMEM_MAX;
sk450net/netrom/af_netrom.csk->wmem_alloc    = 0;
sk451net/netrom/af_netrom.csk->rmem_alloc    = 0;
sk452net/netrom/af_netrom.csk->inuse         = 0;
sk453net/netrom/af_netrom.csk->debug         = 0;
sk454net/netrom/af_netrom.csk->destroy       = 0;
sk455net/netrom/af_netrom.csk->prot          = NULL;  /* So we use default free mechanisms */
sk456net/netrom/af_netrom.csk->err           = 0;
sk457net/netrom/af_netrom.csk->localroute    = 0;
sk458net/netrom/af_netrom.csk->send_head     = NULL;
sk459net/netrom/af_netrom.csk->state         = TCP_CLOSE;
sk460net/netrom/af_netrom.csk->shutdown      = 0;
sk461net/netrom/af_netrom.csk->priority      = SOPRI_NORMAL;
sk462net/netrom/af_netrom.csk->ack_backlog   = 0;
sk463net/netrom/af_netrom.csk->mtu           = NETROM_MTU;  /* 236 */
sk464net/netrom/af_netrom.csk->zapped        = 1;
sk465net/netrom/af_netrom.csk->window    = nr_default.window;
sk467net/netrom/af_netrom.csk->state_change = def_callback1;
sk468net/netrom/af_netrom.csk->data_ready   = def_callback2;
sk469net/netrom/af_netrom.csk->write_space  = def_callback1;
sk470net/netrom/af_netrom.csk->error_report = def_callback1;
sk473net/netrom/af_netrom.csock->data = (void *)sk;
sk474net/netrom/af_netrom.csk->sleep  = sock->wait;
sk514net/netrom/af_netrom.cnr->sk = sk;
sk515net/netrom/af_netrom.csk->nr = nr;
sk522net/netrom/af_netrom.cstruct sock *sk;
sk528net/netrom/af_netrom.cif ((sk = (struct sock *)kmalloc(sizeof(*sk), GFP_ATOMIC)) == NULL)
sk532net/netrom/af_netrom.ckfree_s(sk, sizeof(*sk));
sk536net/netrom/af_netrom.cskb_queue_head_init(&sk->receive_queue);
sk537net/netrom/af_netrom.cskb_queue_head_init(&sk->write_queue);
sk538net/netrom/af_netrom.cskb_queue_head_init(&sk->back_log);
sk540net/netrom/af_netrom.cinit_timer(&sk->timer);
sk542net/netrom/af_netrom.csk->type        = osk->type;
sk543net/netrom/af_netrom.csk->socket      = osk->socket;
sk544net/netrom/af_netrom.csk->dead        = 0;
sk545net/netrom/af_netrom.csk->next        = NULL;
sk546net/netrom/af_netrom.csk->priority    = osk->priority;
sk547net/netrom/af_netrom.csk->broadcast   = 0;
sk548net/netrom/af_netrom.csk->protocol    = osk->protocol;
sk549net/netrom/af_netrom.csk->rcvbuf      = osk->rcvbuf;
sk550net/netrom/af_netrom.csk->sndbuf      = osk->sndbuf;
sk551net/netrom/af_netrom.csk->wmem_alloc  = 0;
sk552net/netrom/af_netrom.csk->rmem_alloc  = 0;
sk553net/netrom/af_netrom.csk->inuse       = 0;
sk554net/netrom/af_netrom.csk->ack_backlog = 0;
sk555net/netrom/af_netrom.csk->destroy     = 0;
sk556net/netrom/af_netrom.csk->prot        = NULL;  /* So we use default free mechanisms */
sk557net/netrom/af_netrom.csk->err         = 0;
sk558net/netrom/af_netrom.csk->localroute  = 0;
sk559net/netrom/af_netrom.csk->send_head   = NULL;
sk560net/netrom/af_netrom.csk->debug       = osk->debug;
sk561net/netrom/af_netrom.csk->state       = TCP_ESTABLISHED;
sk562net/netrom/af_netrom.csk->window      = osk->window;
sk563net/netrom/af_netrom.csk->shutdown    = 0;
sk564net/netrom/af_netrom.csk->mtu         = osk->mtu;
sk565net/netrom/af_netrom.csk->sleep       = osk->sleep;
sk566net/netrom/af_netrom.csk->zapped      = osk->zapped;
sk568net/netrom/af_netrom.csk->state_change = def_callback1;
sk569net/netrom/af_netrom.csk->data_ready   = def_callback2;
sk570net/netrom/af_netrom.csk->write_space  = def_callback1;
sk571net/netrom/af_netrom.csk->error_report = def_callback1;
sk597net/netrom/af_netrom.csk->nr = nr;
sk598net/netrom/af_netrom.cnr->sk = sk;
sk600net/netrom/af_netrom.creturn sk;
sk605net/netrom/af_netrom.cstruct sock *sk = (struct sock *)oldsock->data;
sk607net/netrom/af_netrom.creturn nr_create(newsock, sk->protocol);
sk612net/netrom/af_netrom.cstruct sock *sk = (struct sock *)sock->data;
sk614net/netrom/af_netrom.cif (sk == NULL) return 0;
sk616net/netrom/af_netrom.cif (sk->type == SOCK_SEQPACKET) {
sk617net/netrom/af_netrom.cswitch (sk->nr->state) {
sk619net/netrom/af_netrom.csk->state     = TCP_CLOSE;
sk620net/netrom/af_netrom.csk->state_change(sk);
sk621net/netrom/af_netrom.csk->dead      = 1;
sk622net/netrom/af_netrom.cnr_destroy_socket(sk);
sk626net/netrom/af_netrom.csk->nr->state = NR_STATE_0;
sk627net/netrom/af_netrom.csk->state     = TCP_CLOSE;
sk628net/netrom/af_netrom.csk->state_change(sk);
sk629net/netrom/af_netrom.csk->dead      = 1;
sk630net/netrom/af_netrom.cnr_destroy_socket(sk);
sk634net/netrom/af_netrom.cnr_write_internal(sk, NR_DISCACK);
sk635net/netrom/af_netrom.csk->nr->state = NR_STATE_0;
sk636net/netrom/af_netrom.csk->state     = TCP_CLOSE;
sk637net/netrom/af_netrom.csk->state_change(sk);
sk638net/netrom/af_netrom.csk->dead      = 1;
sk639net/netrom/af_netrom.cnr_destroy_socket(sk);
sk643net/netrom/af_netrom.cnr_clear_queues(sk);
sk644net/netrom/af_netrom.csk->nr->n2count = 0;
sk645net/netrom/af_netrom.cnr_write_internal(sk, NR_DISCREQ);
sk646net/netrom/af_netrom.csk->nr->t1timer = sk->nr->t1 = nr_calculate_t1(sk);
sk647net/netrom/af_netrom.csk->nr->t2timer = 0;
sk648net/netrom/af_netrom.csk->nr->t4timer = 0;
sk649net/netrom/af_netrom.csk->nr->state   = NR_STATE_2;
sk650net/netrom/af_netrom.csk->state       = TCP_CLOSE;
sk651net/netrom/af_netrom.csk->state_change(sk);
sk652net/netrom/af_netrom.csk->dead        = 1;
sk653net/netrom/af_netrom.csk->destroy     = 1;
sk660net/netrom/af_netrom.csk->state = TCP_CLOSE;
sk661net/netrom/af_netrom.csk->state_change(sk);
sk662net/netrom/af_netrom.csk->dead = 1;
sk663net/netrom/af_netrom.cnr_destroy_socket(sk);
sk667net/netrom/af_netrom.csk->socket = NULL;  /* Not used, but we should do this. **/
sk674net/netrom/af_netrom.cstruct sock *sk;
sk679net/netrom/af_netrom.csk = (struct sock *)sock->data;
sk681net/netrom/af_netrom.cif (sk->zapped == 0)
sk688net/netrom/af_netrom.cif (nr_find_listener(&addr->fsa_ax25.sax25_call, sk->type) != NULL) {
sk689net/netrom/af_netrom.cif (sk->debug)
sk696net/netrom/af_netrom.cif (sk->debug)
sk707net/netrom/af_netrom.cmemcpy(&sk->nr->user_addr,   &addr->fsa_digipeater[0],   sizeof(ax25_address));
sk708net/netrom/af_netrom.cmemcpy(&sk->nr->source_addr, &addr->fsa_ax25.sax25_call, sizeof(ax25_address));
sk718net/netrom/af_netrom.cmemcpy(&sk->nr->user_addr,   user,   sizeof(ax25_address));
sk719net/netrom/af_netrom.cmemcpy(&sk->nr->source_addr, source, sizeof(ax25_address));
sk722net/netrom/af_netrom.csk->nr->device = dev;
sk723net/netrom/af_netrom.cnr_insert_socket(sk);
sk725net/netrom/af_netrom.csk->zapped = 0;
sk727net/netrom/af_netrom.cif (sk->debug)
sk736net/netrom/af_netrom.cstruct sock *sk = (struct sock *)sock->data;
sk741net/netrom/af_netrom.cif (sk->state == TCP_ESTABLISHED && sock->state == SS_CONNECTING) {
sk746net/netrom/af_netrom.cif (sk->state == TCP_CLOSE && sock->state == SS_CONNECTING) {
sk751net/netrom/af_netrom.cif (sk->state == TCP_ESTABLISHED && sk->type == SOCK_SEQPACKET)
sk754net/netrom/af_netrom.csk->state   = TCP_CLOSE;  
sk763net/netrom/af_netrom.cif (sk->zapped) {  /* Must bind first - autobinding in this may or may not work */
sk764net/netrom/af_netrom.csk->zapped = 0;
sk774net/netrom/af_netrom.cmemcpy(&sk->nr->user_addr,   user,   sizeof(ax25_address));
sk775net/netrom/af_netrom.cmemcpy(&sk->nr->source_addr, source, sizeof(ax25_address));
sk777net/netrom/af_netrom.csk->nr->device = dev;
sk779net/netrom/af_netrom.cnr_insert_socket(sk);    /* Finish the bind */
sk782net/netrom/af_netrom.cmemcpy(&sk->nr->dest_addr, &addr->sax25_call, sizeof(ax25_address));
sk787net/netrom/af_netrom.csk->nr->my_index = circuit / 256;
sk788net/netrom/af_netrom.csk->nr->my_id    = circuit % 256;
sk794net/netrom/af_netrom.csk->state     = TCP_SYN_SENT;
sk795net/netrom/af_netrom.cnr_establish_data_link(sk);
sk796net/netrom/af_netrom.csk->nr->state = NR_STATE_1;
sk797net/netrom/af_netrom.cnr_set_timer(sk);
sk800net/netrom/af_netrom.cif (sk->state != TCP_ESTABLISHED && (flags & O_NONBLOCK))
sk808net/netrom/af_netrom.cwhile (sk->state == TCP_SYN_SENT) {
sk809net/netrom/af_netrom.cinterruptible_sleep_on(sk->sleep);
sk816net/netrom/af_netrom.cif (sk->state != TCP_ESTABLISHED) {
sk819net/netrom/af_netrom.creturn -sk->err;  /* Always set at this point */
sk836net/netrom/af_netrom.cstruct sock *sk;
sk845net/netrom/af_netrom.csk = (struct sock *)sock->data;
sk847net/netrom/af_netrom.cif (sk->type != SOCK_SEQPACKET)
sk850net/netrom/af_netrom.cif (sk->state != TCP_LISTEN)
sk857net/netrom/af_netrom.cif ((skb = skb_dequeue(&sk->receive_queue)) == NULL) {
sk862net/netrom/af_netrom.cinterruptible_sleep_on(sk->sleep);
sk870net/netrom/af_netrom.cnewsk = skb->sk;
sk875net/netrom/af_netrom.cskb->sk = NULL;
sk877net/netrom/af_netrom.csk->ack_backlog--;
sk887net/netrom/af_netrom.cstruct sock *sk;
sk889net/netrom/af_netrom.csk = (struct sock *)sock->data;
sk892net/netrom/af_netrom.cif (sk->state != TCP_ESTABLISHED)
sk896net/netrom/af_netrom.cmemcpy(&sax->fsa_ax25.sax25_call, &sk->nr->user_addr, sizeof(ax25_address));
sk897net/netrom/af_netrom.cmemcpy(&sax->fsa_digipeater[0],   &sk->nr->dest_addr, sizeof(ax25_address));
sk902net/netrom/af_netrom.cmemcpy(&sax->fsa_ax25.sax25_call, &sk->nr->source_addr, sizeof(ax25_address));
sk911net/netrom/af_netrom.cstruct sock *sk;
sk918net/netrom/af_netrom.cskb->sk = NULL;    /* Initially we don't know who its for */
sk947net/netrom/af_netrom.cif (((frametype & 0x0F) != NR_CONNREQ && (sk = nr_find_socket(circuit_index, circuit_id, SOCK_SEQPACKET)) != NULL) ||
sk948net/netrom/af_netrom.c((frametype & 0x0F) == NR_CONNREQ && (sk = nr_find_peer(circuit_index, circuit_id, SOCK_SEQPACKET)) != NULL)) {
sk952net/netrom/af_netrom.csk->nr->bpqext = 1;
sk954net/netrom/af_netrom.csk->nr->bpqext = 0;
sk956net/netrom/af_netrom.creturn nr_process_rx_frame(sk, skb);
sk962net/netrom/af_netrom.csk = nr_find_listener(dest, SOCK_SEQPACKET);
sk966net/netrom/af_netrom.cif (sk == NULL || sk->ack_backlog == sk->max_ack_backlog || (make = nr_make_new(sk)) == NULL) {
sk973net/netrom/af_netrom.cskb->sk             = make;
sk1011net/netrom/af_netrom.csk->ack_backlog++;
sk1012net/netrom/af_netrom.cmake->pair = sk;
sk1016net/netrom/af_netrom.cskb_queue_head(&sk->receive_queue, skb);
sk1020net/netrom/af_netrom.cif (!sk->dead)
sk1021net/netrom/af_netrom.csk->data_ready(sk, skb->len);
sk1028net/netrom/af_netrom.cstruct sock *sk = (struct sock *)sock->data;
sk1036net/netrom/af_netrom.cif (sk->err) {
sk1037net/netrom/af_netrom.cerr     = sk->err;
sk1038net/netrom/af_netrom.csk->err = 0;
sk1045net/netrom/af_netrom.cif (sk->zapped)
sk1048net/netrom/af_netrom.cif (sk->nr->device == NULL)
sk1055net/netrom/af_netrom.cif (sk->type == SOCK_SEQPACKET && memcmp(&sk->nr->dest_addr, &sax.sax25_call, sizeof(ax25_address)) != 0)
sk1060net/netrom/af_netrom.cif (sk->state != TCP_ESTABLISHED)
sk1063net/netrom/af_netrom.cmemcpy(&sax.sax25_call, &sk->nr->dest_addr, sizeof(ax25_address));
sk1066net/netrom/af_netrom.cif (sk->debug)
sk1070net/netrom/af_netrom.cif (sk->debug)
sk1075net/netrom/af_netrom.cif ((skb = sock_alloc_send_skb(sk, size, 0, 0, &err)) == NULL)
sk1078net/netrom/af_netrom.cskb->sk   = sk;
sk1090net/netrom/af_netrom.cif (sk->debug)
sk1095net/netrom/af_netrom.c*asmptr++ = sk->nr->your_index;
sk1096net/netrom/af_netrom.c*asmptr++ = sk->nr->your_id;
sk1101net/netrom/af_netrom.cif (sk->debug)
sk1112net/netrom/af_netrom.cif (sk->debug)
sk1118net/netrom/af_netrom.cif (sk->debug)
sk1121net/netrom/af_netrom.cif (sk->state != TCP_ESTABLISHED) {
sk1126net/netrom/af_netrom.cnr_output(sk, skb);  /* Shove it onto the queue */
sk1161net/netrom/af_netrom.cstruct sock *sk = (struct sock *)sock->data;
sk1167net/netrom/af_netrom.cif (sk->err) {
sk1169net/netrom/af_netrom.cer      = -sk->err;
sk1170net/netrom/af_netrom.csk->err = 0;
sk1182net/netrom/af_netrom.cif (sk->type == SOCK_SEQPACKET && sk->state != TCP_ESTABLISHED)
sk1186net/netrom/af_netrom.cif ((skb = skb_recv_datagram(sk, flags, noblock, &er)) == NULL)
sk1189net/netrom/af_netrom.cif (!sk->nr->hdrincl) {
sk1237net/netrom/af_netrom.cstruct sock *sk = (struct sock *)sock->data;
sk1239net/netrom/af_netrom.cif (sk->zapped)
sk1250net/netrom/af_netrom.cstatic int nr_shutdown(struct socket *sk, int how)
sk1257net/netrom/af_netrom.cstruct sock *sk = (struct sock *)sock->data;
sk1259net/netrom/af_netrom.creturn datagram_select(sk, sel_type, wait);
sk1264net/netrom/af_netrom.cstruct sock *sk = (struct sock *)sock->data;
sk1272net/netrom/af_netrom.camount = sk->sndbuf - sk->wmem_alloc;
sk1282net/netrom/af_netrom.cif ((skb = skb_peek(&sk->receive_queue)) != NULL)
sk1291net/netrom/af_netrom.cif (sk != NULL) {
sk1292net/netrom/af_netrom.cif (sk->stamp.tv_sec==0)
sk1296net/netrom/af_netrom.cmemcpy_tofs((void *)arg, &sk->stamp, sizeof(struct timeval));
sk53net/netrom/nr_in.cstatic int nr_queue_rx_frame(struct sock *sk, struct sk_buff *skb, int more)
sk58net/netrom/nr_in.csk->nr->fraglen += skb->len;
sk59net/netrom/nr_in.cskb_queue_tail(&sk->nr->frag_queue, skb);
sk63net/netrom/nr_in.cif (!more && sk->nr->fraglen > 0) {  /* End of fragment */
sk64net/netrom/nr_in.csk->nr->fraglen += skb->len;
sk65net/netrom/nr_in.cskb_queue_tail(&sk->nr->frag_queue, skb);
sk67net/netrom/nr_in.cif ((skbn = alloc_skb(sk->nr->fraglen, GFP_ATOMIC)) == NULL)
sk72net/netrom/nr_in.cskbn->sk   = sk;
sk73net/netrom/nr_in.csk->rmem_alloc += skbn->truesize;
sk76net/netrom/nr_in.cskbo = skb_dequeue(&sk->nr->frag_queue);
sk80net/netrom/nr_in.cwhile ((skbo = skb_dequeue(&sk->nr->frag_queue)) != NULL) {
sk86net/netrom/nr_in.csk->nr->fraglen = 0;    
sk89net/netrom/nr_in.creturn sock_queue_rcv_skb(sk, skbn);
sk97net/netrom/nr_in.cstatic int nr_state1_machine(struct sock *sk, struct sk_buff *skb, int frametype)
sk102net/netrom/nr_in.cnr_calculate_rtt(sk);
sk103net/netrom/nr_in.csk->window         = skb->data[20];
sk104net/netrom/nr_in.csk->nr->your_index = skb->data[17];
sk105net/netrom/nr_in.csk->nr->your_id    = skb->data[18];
sk106net/netrom/nr_in.csk->nr->t1timer    = 0;
sk107net/netrom/nr_in.csk->nr->t2timer    = 0;
sk108net/netrom/nr_in.csk->nr->t4timer    = 0;
sk109net/netrom/nr_in.csk->nr->vs         = 0;
sk110net/netrom/nr_in.csk->nr->va         = 0;
sk111net/netrom/nr_in.csk->nr->vr         = 0;
sk112net/netrom/nr_in.csk->nr->vl     = 0;
sk113net/netrom/nr_in.csk->nr->state      = NR_STATE_3;
sk114net/netrom/nr_in.csk->state          = TCP_ESTABLISHED;
sk115net/netrom/nr_in.csk->nr->n2count    = 0;
sk117net/netrom/nr_in.cif (!sk->dead)
sk118net/netrom/nr_in.csk->state_change(sk);
sk122net/netrom/nr_in.cnr_clear_queues(sk);
sk123net/netrom/nr_in.csk->nr->state = NR_STATE_0;
sk124net/netrom/nr_in.csk->state     = TCP_CLOSE;
sk125net/netrom/nr_in.csk->err       = ECONNREFUSED;
sk126net/netrom/nr_in.cif (!sk->dead)
sk127net/netrom/nr_in.csk->state_change(sk);
sk128net/netrom/nr_in.csk->dead      = 1;
sk143net/netrom/nr_in.cstatic int nr_state2_machine(struct sock *sk, struct sk_buff *skb, int frametype)
sk148net/netrom/nr_in.cnr_write_internal(sk, NR_DISCACK);
sk151net/netrom/nr_in.csk->nr->state = NR_STATE_0;
sk152net/netrom/nr_in.csk->state     = TCP_CLOSE;
sk153net/netrom/nr_in.csk->err       = 0;
sk154net/netrom/nr_in.cif (!sk->dead)
sk155net/netrom/nr_in.csk->state_change(sk);
sk156net/netrom/nr_in.csk->dead      = 1;
sk171net/netrom/nr_in.cstatic int nr_state3_machine(struct sock *sk, struct sk_buff *skb, int frametype)
sk185net/netrom/nr_in.cnr_write_internal(sk, NR_CONNACK);
sk189net/netrom/nr_in.cnr_clear_queues(sk);
sk190net/netrom/nr_in.cnr_write_internal(sk, NR_DISCACK);
sk191net/netrom/nr_in.csk->nr->state = NR_STATE_0;
sk192net/netrom/nr_in.csk->state     = TCP_CLOSE;
sk193net/netrom/nr_in.csk->err       = 0;
sk194net/netrom/nr_in.cif (!sk->dead)
sk195net/netrom/nr_in.csk->state_change(sk);
sk196net/netrom/nr_in.csk->dead      = 1;
sk200net/netrom/nr_in.cnr_clear_queues(sk);
sk201net/netrom/nr_in.csk->nr->state = NR_STATE_0;
sk202net/netrom/nr_in.csk->state     = TCP_CLOSE;
sk203net/netrom/nr_in.csk->err       = ECONNRESET;
sk204net/netrom/nr_in.cif (!sk->dead)
sk205net/netrom/nr_in.csk->state_change(sk);
sk206net/netrom/nr_in.csk->dead      = 1;
sk214net/netrom/nr_in.csk->nr->condition |= PEER_RX_BUSY_CONDITION;
sk215net/netrom/nr_in.csk->nr->t4timer = nr_default.busy_delay;
sk217net/netrom/nr_in.csk->nr->condition &= ~PEER_RX_BUSY_CONDITION;
sk218net/netrom/nr_in.csk->nr->t4timer = 0;
sk220net/netrom/nr_in.cif (!nr_validate_nr(sk, nr)) {
sk224net/netrom/nr_in.cnr_frames_acked(sk, nr);
sk225net/netrom/nr_in.cnr_send_nak_frame(sk);
sk227net/netrom/nr_in.cif (sk->nr->condition & PEER_RX_BUSY_CONDITION) {
sk228net/netrom/nr_in.cnr_frames_acked(sk, nr);
sk230net/netrom/nr_in.cnr_check_iframes_acked(sk, nr);
sk244net/netrom/nr_in.csk->nr->condition |= PEER_RX_BUSY_CONDITION;
sk245net/netrom/nr_in.csk->nr->t4timer = nr_default.busy_delay;
sk247net/netrom/nr_in.csk->nr->condition &= ~PEER_RX_BUSY_CONDITION;
sk248net/netrom/nr_in.csk->nr->t4timer = 0;
sk250net/netrom/nr_in.cif (nr_validate_nr(sk, nr)) {
sk252net/netrom/nr_in.cnr_frames_acked(sk, nr);
sk253net/netrom/nr_in.cnr_send_nak_frame(sk);
sk255net/netrom/nr_in.cif (sk->nr->condition & PEER_RX_BUSY_CONDITION) {
sk256net/netrom/nr_in.cnr_frames_acked(sk, nr);
sk258net/netrom/nr_in.cnr_check_iframes_acked(sk, nr);
sk263net/netrom/nr_in.cskb_queue_head(&sk->nr->reseq_queue, skb);
sk264net/netrom/nr_in.cif (sk->nr->condition & OWN_RX_BUSY_CONDITION)
sk268net/netrom/nr_in.csave_vr = sk->nr->vr;
sk269net/netrom/nr_in.cwhile ((skbn = skb_dequeue(&sk->nr->reseq_queue)) != NULL) {
sk271net/netrom/nr_in.cif (ns == sk->nr->vr) {
sk272net/netrom/nr_in.cif (nr_queue_rx_frame(sk, skbn, frametype & NR_MORE_FLAG) == 0) {
sk273net/netrom/nr_in.csk->nr->vr = (sk->nr->vr + 1) % NR_MODULUS;
sk275net/netrom/nr_in.csk->nr->condition |= OWN_RX_BUSY_CONDITION;
sk278net/netrom/nr_in.c} else if (nr_in_rx_window(sk, ns)) {
sk286net/netrom/nr_in.cskb_queue_tail(&sk->nr->reseq_queue, skbn);
sk288net/netrom/nr_in.c} while (save_vr != sk->nr->vr);
sk292net/netrom/nr_in.cif (((sk->nr->vl + sk->window) % NR_MODULUS) == sk->nr->vr) {
sk293net/netrom/nr_in.cnr_enquiry_response(sk);
sk295net/netrom/nr_in.cif (!(sk->nr->condition & ACK_PENDING_CONDITION)) {
sk296net/netrom/nr_in.csk->nr->t2timer = sk->nr->t2;
sk297net/netrom/nr_in.csk->nr->condition |= ACK_PENDING_CONDITION;
sk310net/netrom/nr_in.cint nr_process_rx_frame(struct sock *sk, struct sk_buff *skb)
sk314net/netrom/nr_in.cif (sk->nr->state == NR_STATE_0 && sk->dead)
sk317net/netrom/nr_in.cif (sk->nr->state != NR_STATE_1 && sk->nr->state != NR_STATE_2 &&
sk318net/netrom/nr_in.csk->nr->state != NR_STATE_3) {
sk319net/netrom/nr_in.cprintk("nr_process_rx_frame: frame received - state: %d\n", sk->nr->state);
sk323net/netrom/nr_in.cdel_timer(&sk->timer);
sk327net/netrom/nr_in.cswitch (sk->nr->state)
sk330net/netrom/nr_in.cqueued = nr_state1_machine(sk, skb, frametype);
sk333net/netrom/nr_in.cqueued = nr_state2_machine(sk, skb, frametype);
sk336net/netrom/nr_in.cqueued = nr_state3_machine(sk, skb, frametype);
sk340net/netrom/nr_in.cnr_set_timer(sk);
sk49net/netrom/nr_out.cvoid nr_output(struct sock *sk, struct sk_buff *skb)
sk55net/netrom/nr_out.cmtu = sk->nr->device->mtu;
sk65net/netrom/nr_out.cif ((skbn = sock_alloc_send_skb(sk, frontlen + mtu, 0, 0, &err)) == NULL)
sk68net/netrom/nr_out.cskbn->sk   = sk;
sk87net/netrom/nr_out.cskb_queue_tail(&sk->write_queue, skbn); /* Throw it on the queue */
sk93net/netrom/nr_out.cskb_queue_tail(&sk->write_queue, skb);    /* Throw it on the queue */
sk96net/netrom/nr_out.cif (sk->nr->state == NR_STATE_3)
sk97net/netrom/nr_out.cnr_kick(sk);
sk104net/netrom/nr_out.cstatic void nr_send_iframe(struct sock *sk, struct sk_buff *skb)
sk109net/netrom/nr_out.cskb->data[2] = sk->nr->vs;
sk110net/netrom/nr_out.cskb->data[3] = sk->nr->vr;
sk112net/netrom/nr_out.cif (sk->nr->condition & OWN_RX_BUSY_CONDITION)
sk115net/netrom/nr_out.cnr_transmit_buffer(sk, skb);  
sk118net/netrom/nr_out.cvoid nr_send_nak_frame(struct sock *sk)
sk122net/netrom/nr_out.cif ((skb = skb_peek(&sk->nr->ack_queue)) == NULL)
sk128net/netrom/nr_out.cskbn->data[2] = sk->nr->va;
sk129net/netrom/nr_out.cskbn->data[3] = sk->nr->vr;
sk131net/netrom/nr_out.cif (sk->nr->condition & OWN_RX_BUSY_CONDITION)
sk134net/netrom/nr_out.cnr_transmit_buffer(sk, skbn);
sk136net/netrom/nr_out.csk->nr->condition &= ~ACK_PENDING_CONDITION;
sk137net/netrom/nr_out.csk->nr->vl      = sk->nr->vr;
sk138net/netrom/nr_out.csk->nr->t1timer = 0;
sk141net/netrom/nr_out.cvoid nr_kick(struct sock *sk)
sk147net/netrom/nr_out.cdel_timer(&sk->timer);
sk149net/netrom/nr_out.cstart = (skb_peek(&sk->nr->ack_queue) == NULL) ? sk->nr->va : sk->nr->vs;
sk150net/netrom/nr_out.cend   = (sk->nr->va + sk->window) % NR_MODULUS;
sk152net/netrom/nr_out.cif (!(sk->nr->condition & PEER_RX_BUSY_CONDITION) &&
sk154net/netrom/nr_out.cskb_peek(&sk->write_queue) != NULL) {
sk156net/netrom/nr_out.csk->nr->vs = start;
sk166net/netrom/nr_out.cskb  = skb_dequeue(&sk->write_queue);
sk170net/netrom/nr_out.cskb_queue_head(&sk->write_queue, skb);
sk174net/netrom/nr_out.cnext = (sk->nr->vs + 1) % NR_MODULUS;
sk180net/netrom/nr_out.cnr_send_iframe(sk, skbn);
sk182net/netrom/nr_out.csk->nr->vs = next;
sk187net/netrom/nr_out.cskb_queue_tail(&sk->nr->ack_queue, skb);
sk189net/netrom/nr_out.c} while (!last && (skb = skb_dequeue(&sk->write_queue)) != NULL);
sk191net/netrom/nr_out.csk->nr->vl = sk->nr->vr;
sk192net/netrom/nr_out.csk->nr->condition &= ~ACK_PENDING_CONDITION;
sk194net/netrom/nr_out.cif (sk->nr->t1timer == 0) {
sk195net/netrom/nr_out.csk->nr->t1timer = sk->nr->t1 = nr_calculate_t1(sk);
sk199net/netrom/nr_out.cnr_set_timer(sk);
sk202net/netrom/nr_out.cvoid nr_transmit_buffer(struct sock *sk, struct sk_buff *skb)
sk211net/netrom/nr_out.cmemcpy(dptr, &sk->nr->source_addr, sizeof(ax25_address));
sk217net/netrom/nr_out.cmemcpy(dptr, &sk->nr->dest_addr,   sizeof(ax25_address));
sk230net/netrom/nr_out.csk->state = TCP_CLOSE;
sk231net/netrom/nr_out.csk->err   = ENETUNREACH;
sk232net/netrom/nr_out.cif (!sk->dead)
sk233net/netrom/nr_out.csk->state_change(sk);
sk234net/netrom/nr_out.csk->dead  = 1;
sk243net/netrom/nr_out.cvoid nr_establish_data_link(struct sock *sk)
sk245net/netrom/nr_out.csk->nr->condition = 0x00;
sk246net/netrom/nr_out.csk->nr->n2count   = 0;
sk248net/netrom/nr_out.cnr_write_internal(sk, NR_CONNREQ);
sk250net/netrom/nr_out.csk->nr->t2timer = 0;
sk251net/netrom/nr_out.csk->nr->t1timer = sk->nr->t1 = nr_calculate_t1(sk);
sk257net/netrom/nr_out.cvoid nr_enquiry_response(struct sock *sk)
sk261net/netrom/nr_out.cif (sk->nr->condition & OWN_RX_BUSY_CONDITION) {
sk264net/netrom/nr_out.cif (skb_peek(&sk->nr->reseq_queue) != NULL) {
sk269net/netrom/nr_out.cnr_write_internal(sk, frametype);
sk271net/netrom/nr_out.csk->nr->vl = sk->nr->vr;
sk272net/netrom/nr_out.csk->nr->condition &= ~ACK_PENDING_CONDITION;
sk275net/netrom/nr_out.cvoid nr_check_iframes_acked(struct sock *sk, unsigned short nr)
sk277net/netrom/nr_out.cif (sk->nr->vs == nr) {
sk278net/netrom/nr_out.cnr_frames_acked(sk, nr);
sk279net/netrom/nr_out.cnr_calculate_rtt(sk);
sk280net/netrom/nr_out.csk->nr->t1timer = 0;
sk281net/netrom/nr_out.csk->nr->n2count = 0;
sk283net/netrom/nr_out.cif (sk->nr->va != nr) {
sk284net/netrom/nr_out.cnr_frames_acked(sk, nr);
sk285net/netrom/nr_out.csk->nr->t1timer = sk->nr->t1 = nr_calculate_t1(sk);
sk47net/netrom/nr_subr.cvoid nr_clear_queues(struct sock *sk)
sk51net/netrom/nr_subr.cwhile ((skb = skb_dequeue(&sk->write_queue)) != NULL) {
sk52net/netrom/nr_subr.cskb->sk   = sk;
sk57net/netrom/nr_subr.cwhile ((skb = skb_dequeue(&sk->nr->ack_queue)) != NULL) {
sk58net/netrom/nr_subr.cskb->sk   = sk;
sk63net/netrom/nr_subr.cwhile ((skb = skb_dequeue(&sk->nr->reseq_queue)) != NULL) {
sk67net/netrom/nr_subr.cwhile ((skb = skb_dequeue(&sk->nr->frag_queue)) != NULL) {
sk77net/netrom/nr_subr.cvoid nr_frames_acked(struct sock *sk, unsigned short nr)
sk84net/netrom/nr_subr.cif (sk->nr->va != nr) {
sk85net/netrom/nr_subr.cwhile (skb_peek(&sk->nr->ack_queue) != NULL && sk->nr->va != nr) {
sk86net/netrom/nr_subr.cskb = skb_dequeue(&sk->nr->ack_queue);
sk87net/netrom/nr_subr.cskb->sk   = sk;
sk90net/netrom/nr_subr.csk->nr->va = (sk->nr->va + 1) % NR_MODULUS;
sk100net/netrom/nr_subr.cvoid nr_requeue_frames(struct sock *sk)
sk104net/netrom/nr_subr.cwhile ((skb = skb_dequeue(&sk->nr->ack_queue)) != NULL) {
sk106net/netrom/nr_subr.cskb_queue_head(&sk->write_queue, skb);
sk117net/netrom/nr_subr.cint nr_validate_nr(struct sock *sk, unsigned short nr)
sk119net/netrom/nr_subr.cunsigned short vc = sk->nr->va;
sk121net/netrom/nr_subr.cwhile (vc != sk->nr->vs) {
sk126net/netrom/nr_subr.cif (nr == sk->nr->vs) return 1;
sk134net/netrom/nr_subr.cint nr_in_rx_window(struct sock *sk, unsigned short ns)
sk136net/netrom/nr_subr.cunsigned short vc = sk->nr->vr;
sk137net/netrom/nr_subr.cunsigned short vt = (sk->nr->vl + sk->window) % NR_MODULUS;
sk151net/netrom/nr_subr.cvoid nr_write_internal(struct sock *sk, int frametype)
sk164net/netrom/nr_subr.clen += (sk->nr->bpqext) ? 2 : 1;
sk188net/netrom/nr_subr.ctimeout  = (sk->nr->rtt / PR_SLOWHZ) * 2;
sk189net/netrom/nr_subr.c*dptr++  = sk->nr->my_index;
sk190net/netrom/nr_subr.c*dptr++  = sk->nr->my_id;
sk194net/netrom/nr_subr.c*dptr++  = sk->window;
sk195net/netrom/nr_subr.cmemcpy(dptr, &sk->nr->user_addr, sizeof(ax25_address));
sk200net/netrom/nr_subr.cmemcpy(dptr, &sk->nr->source_addr, sizeof(ax25_address));
sk210net/netrom/nr_subr.c*dptr++ = sk->nr->your_index;
sk211net/netrom/nr_subr.c*dptr++ = sk->nr->your_id;
sk212net/netrom/nr_subr.c*dptr++ = sk->nr->my_index;
sk213net/netrom/nr_subr.c*dptr++ = sk->nr->my_id;
sk215net/netrom/nr_subr.c*dptr++ = sk->window;
sk216net/netrom/nr_subr.cif (sk->nr->bpqext) *dptr++ = nr_default.ttl;
sk221net/netrom/nr_subr.c*dptr++ = sk->nr->your_index;
sk222net/netrom/nr_subr.c*dptr++ = sk->nr->your_id;
sk229net/netrom/nr_subr.c*dptr++ = sk->nr->your_index;
sk230net/netrom/nr_subr.c*dptr++ = sk->nr->your_id;
sk232net/netrom/nr_subr.c*dptr++ = sk->nr->vr;
sk239net/netrom/nr_subr.cnr_transmit_buffer(sk, skb);
sk283net/netrom/nr_subr.cskbn->sk   = NULL;
sk292net/netrom/nr_subr.cunsigned short nr_calculate_t1(struct sock *sk)
sk296net/netrom/nr_subr.cfor (t = 2, n = 0; n < sk->nr->n2count; n++)
sk301net/netrom/nr_subr.creturn t * sk->nr->rtt;
sk307net/netrom/nr_subr.cvoid nr_calculate_rtt(struct sock *sk)
sk309net/netrom/nr_subr.cif (sk->nr->t1timer > 0 && sk->nr->n2count == 0)
sk310net/netrom/nr_subr.csk->nr->rtt = (9 * sk->nr->rtt + sk->nr->t1 - sk->nr->t1timer) / 10;
sk314net/netrom/nr_subr.cif (sk->nr->rtt < (NR_T1CLAMPLO))
sk315net/netrom/nr_subr.csk->nr->rtt = (NR_T1CLAMPLO);
sk317net/netrom/nr_subr.cif (sk->nr->rtt == 0)
sk318net/netrom/nr_subr.csk->nr->rtt = PR_SLOWHZ;
sk322net/netrom/nr_subr.cif (sk->nr->rtt > (NR_T1CLAMPHI))
sk323net/netrom/nr_subr.csk->nr->rtt = (NR_T1CLAMPHI);
sk48net/netrom/nr_timer.cvoid nr_set_timer(struct sock *sk)
sk54net/netrom/nr_timer.cdel_timer(&sk->timer);
sk57net/netrom/nr_timer.csk->timer.next     = sk->timer.prev = NULL;  
sk58net/netrom/nr_timer.csk->timer.data     = (unsigned long)sk;
sk59net/netrom/nr_timer.csk->timer.function = &nr_timer;
sk61net/netrom/nr_timer.csk->timer.expires = jiffies+10;
sk62net/netrom/nr_timer.cadd_timer(&sk->timer);
sk65net/netrom/nr_timer.cstatic void nr_reset_timer(struct sock *sk)
sk71net/netrom/nr_timer.cdel_timer(&sk->timer);
sk74net/netrom/nr_timer.csk->timer.data     = (unsigned long)sk;
sk75net/netrom/nr_timer.csk->timer.function = &nr_timer;
sk76net/netrom/nr_timer.csk->timer.expires  = jiffies+10;
sk77net/netrom/nr_timer.cadd_timer(&sk->timer);
sk88net/netrom/nr_timer.cstruct sock *sk = (struct sock *)param;
sk90net/netrom/nr_timer.cswitch (sk->nr->state) {
sk94net/netrom/nr_timer.cif (sk->destroy || (sk->state == TCP_LISTEN && sk->dead)) {
sk95net/netrom/nr_timer.cdel_timer(&sk->timer);
sk96net/netrom/nr_timer.cnr_destroy_socket(sk);
sk105net/netrom/nr_timer.cif (sk->rmem_alloc < (sk->rcvbuf / 2) && (sk->nr->condition & OWN_RX_BUSY_CONDITION)) {
sk106net/netrom/nr_timer.csk->nr->condition &= ~OWN_RX_BUSY_CONDITION;
sk107net/netrom/nr_timer.cnr_write_internal(sk, NR_INFOACK);
sk108net/netrom/nr_timer.csk->nr->condition &= ~ACK_PENDING_CONDITION;
sk109net/netrom/nr_timer.csk->nr->vl = sk->nr->vr;
sk115net/netrom/nr_timer.cnr_kick(sk);
sk122net/netrom/nr_timer.cif (sk->nr->t2timer > 0 && --sk->nr->t2timer == 0) {
sk123net/netrom/nr_timer.cif (sk->nr->state == NR_STATE_3) {
sk124net/netrom/nr_timer.cif (sk->nr->condition & ACK_PENDING_CONDITION) {
sk125net/netrom/nr_timer.csk->nr->condition &= ~ACK_PENDING_CONDITION;
sk126net/netrom/nr_timer.cnr_enquiry_response(sk);
sk131net/netrom/nr_timer.cif (sk->nr->t4timer > 0 && --sk->nr->t4timer == 0) {
sk132net/netrom/nr_timer.csk->nr->condition &= ~PEER_RX_BUSY_CONDITION;
sk135net/netrom/nr_timer.cif (sk->nr->t1timer == 0 || --sk->nr->t1timer > 0) {
sk136net/netrom/nr_timer.cnr_reset_timer(sk);
sk140net/netrom/nr_timer.cswitch (sk->nr->state) {
sk142net/netrom/nr_timer.cif (sk->nr->n2count == sk->nr->n2) {
sk143net/netrom/nr_timer.cnr_clear_queues(sk);
sk144net/netrom/nr_timer.csk->nr->state = NR_STATE_0;
sk145net/netrom/nr_timer.csk->state     = TCP_CLOSE;
sk146net/netrom/nr_timer.csk->err       = ETIMEDOUT;
sk147net/netrom/nr_timer.cif (!sk->dead)
sk148net/netrom/nr_timer.csk->state_change(sk);
sk149net/netrom/nr_timer.csk->dead      = 1;
sk151net/netrom/nr_timer.csk->nr->n2count++;
sk152net/netrom/nr_timer.cnr_write_internal(sk, NR_CONNREQ);
sk157net/netrom/nr_timer.cif (sk->nr->n2count == sk->nr->n2) {
sk158net/netrom/nr_timer.cnr_clear_queues(sk);
sk159net/netrom/nr_timer.csk->nr->state = NR_STATE_0;
sk160net/netrom/nr_timer.csk->state     = TCP_CLOSE;
sk161net/netrom/nr_timer.csk->err       = ETIMEDOUT;
sk162net/netrom/nr_timer.cif (!sk->dead)
sk163net/netrom/nr_timer.csk->state_change(sk);
sk164net/netrom/nr_timer.csk->dead      = 1;
sk166net/netrom/nr_timer.csk->nr->n2count++;
sk167net/netrom/nr_timer.cnr_write_internal(sk, NR_DISCREQ);
sk172net/netrom/nr_timer.cif (sk->nr->n2count == sk->nr->n2) {
sk173net/netrom/nr_timer.cnr_clear_queues(sk);
sk174net/netrom/nr_timer.csk->nr->state = NR_STATE_0;
sk175net/netrom/nr_timer.csk->state     = TCP_CLOSE;
sk176net/netrom/nr_timer.csk->err       = ETIMEDOUT;
sk177net/netrom/nr_timer.cif (!sk->dead)
sk178net/netrom/nr_timer.csk->state_change(sk);
sk179net/netrom/nr_timer.csk->dead      = 1;
sk181net/netrom/nr_timer.csk->nr->n2count++;
sk182net/netrom/nr_timer.cnr_requeue_frames(sk);
sk187net/netrom/nr_timer.csk->nr->t1timer = sk->nr->t1 = nr_calculate_t1(sk);
sk189net/netrom/nr_timer.cnr_set_timer(sk);
sk70net/unix/af_unix.cstatic void unix_remove_socket(unix_socket *sk)
sk79net/unix/af_unix.cif(*s==sk)
sk81net/unix/af_unix.c*s=sk->next;
sk89net/unix/af_unix.cstatic void unix_insert_socket(unix_socket *sk)
sk92net/unix/af_unix.csk->next=unix_socket_list;
sk93net/unix/af_unix.cunix_socket_list=sk;
sk121net/unix/af_unix.cunix_socket *sk=(unix_socket *)data;
sk122net/unix/af_unix.cif(sk->protinfo.af_unix.locks==0 && sk->wmem_alloc==0)
sk124net/unix/af_unix.cif(sk->protinfo.af_unix.name)
sk125net/unix/af_unix.ckfree(sk->protinfo.af_unix.name);
sk126net/unix/af_unix.ckfree_s(sk,sizeof(*sk));
sk134net/unix/af_unix.csk->timer.expires=jiffies+10*HZ;  /* No real hurry try it every 10 seconds or so */
sk135net/unix/af_unix.cadd_timer(&sk->timer);
sk139net/unix/af_unix.cstatic void unix_delayed_delete(unix_socket *sk)
sk141net/unix/af_unix.csk->timer.data=(unsigned long)sk;
sk142net/unix/af_unix.csk->timer.expires=jiffies+HZ;    /* Normally 1 second after will clean up. After that we try every 10 */
sk143net/unix/af_unix.csk->timer.function=unix_destroy_timer;
sk144net/unix/af_unix.cadd_timer(&sk->timer);
sk147net/unix/af_unix.cstatic void unix_destroy_socket(unix_socket *sk)
sk150net/unix/af_unix.cunix_remove_socket(sk);
sk152net/unix/af_unix.cwhile((skb=skb_dequeue(&sk->receive_queue))!=NULL)
sk154net/unix/af_unix.cif(sk->state==TCP_LISTEN)
sk156net/unix/af_unix.cunix_socket *osk=skb->sk;
sk169net/unix/af_unix.cif(sk->protinfo.af_unix.inode!=NULL)
sk171net/unix/af_unix.ciput(sk->protinfo.af_unix.inode);
sk172net/unix/af_unix.csk->protinfo.af_unix.inode=NULL;
sk175net/unix/af_unix.cif(--sk->protinfo.af_unix.locks==0 && sk->wmem_alloc==0)
sk177net/unix/af_unix.cif(sk->protinfo.af_unix.name)
sk178net/unix/af_unix.ckfree(sk->protinfo.af_unix.name);
sk179net/unix/af_unix.ckfree_s(sk,sizeof(*sk));
sk183net/unix/af_unix.csk->dead=1;
sk184net/unix/af_unix.cunix_delayed_delete(sk);  /* Try every so often until buffers are all freed */
sk203net/unix/af_unix.cunix_socket *sk=sock->data;
sk206net/unix/af_unix.creturn sock_setsockopt(sk,level,optname,optval,optlen);  
sk211net/unix/af_unix.cunix_socket *sk=sock->data;
sk214net/unix/af_unix.creturn sock_getsockopt(sk,level,optname,optval,optlen);
sk219net/unix/af_unix.cunix_socket *sk=sock->data;
sk220net/unix/af_unix.cif(sk->type!=SOCK_STREAM)
sk222net/unix/af_unix.csk->max_ack_backlog=backlog;
sk223net/unix/af_unix.csk->state=TCP_LISTEN;
sk227net/unix/af_unix.cstatic void def_callback1(struct sock *sk)
sk229net/unix/af_unix.cif(!sk->dead)
sk230net/unix/af_unix.cwake_up_interruptible(sk->sleep);
sk233net/unix/af_unix.cstatic void def_callback2(struct sock *sk, int len)
sk235net/unix/af_unix.cif(!sk->dead)
sk237net/unix/af_unix.cwake_up_interruptible(sk->sleep);
sk238net/unix/af_unix.csock_wake_async(sk->socket, 1);
sk242net/unix/af_unix.cstatic void def_callback3(struct sock *sk)
sk244net/unix/af_unix.cif(!sk->dead)
sk246net/unix/af_unix.cwake_up_interruptible(sk->sleep);
sk247net/unix/af_unix.csock_wake_async(sk->socket, 2);
sk253net/unix/af_unix.cunix_socket *sk;
sk257net/unix/af_unix.csk=(unix_socket *)kmalloc(sizeof(*sk),GFP_KERNEL);
sk258net/unix/af_unix.cif(sk==NULL)
sk260net/unix/af_unix.csk->type=sock->type;
sk268net/unix/af_unix.ckfree_s(sk,sizeof(*sk));
sk271net/unix/af_unix.cinit_timer(&sk->timer);
sk272net/unix/af_unix.cskb_queue_head_init(&sk->write_queue);
sk273net/unix/af_unix.cskb_queue_head_init(&sk->receive_queue);
sk274net/unix/af_unix.cskb_queue_head_init(&sk->back_log);
sk275net/unix/af_unix.csk->protinfo.af_unix.family=AF_UNIX;
sk276net/unix/af_unix.csk->protinfo.af_unix.inode=NULL;
sk277net/unix/af_unix.csk->protinfo.af_unix.locks=1;    /* Us */
sk278net/unix/af_unix.csk->protinfo.af_unix.readsem=MUTEX;  /* single task reading lock */
sk279net/unix/af_unix.csk->protinfo.af_unix.name=NULL;
sk280net/unix/af_unix.csk->protinfo.af_unix.other=NULL;
sk281net/unix/af_unix.csk->protocol=0;
sk282net/unix/af_unix.csk->rmem_alloc=0;
sk283net/unix/af_unix.csk->wmem_alloc=0;
sk284net/unix/af_unix.csk->dead=0;
sk285net/unix/af_unix.csk->next=NULL;
sk286net/unix/af_unix.csk->broadcast=0;
sk287net/unix/af_unix.csk->rcvbuf=SK_RMEM_MAX;
sk288net/unix/af_unix.csk->sndbuf=SK_WMEM_MAX;
sk289net/unix/af_unix.csk->allocation=GFP_KERNEL;
sk290net/unix/af_unix.csk->inuse=0;
sk291net/unix/af_unix.csk->debug=0;
sk292net/unix/af_unix.csk->prot=NULL;
sk293net/unix/af_unix.csk->err=0;
sk294net/unix/af_unix.csk->localroute=0;
sk295net/unix/af_unix.csk->send_head=NULL;
sk296net/unix/af_unix.csk->state=TCP_CLOSE;
sk297net/unix/af_unix.csk->priority=SOPRI_NORMAL;
sk298net/unix/af_unix.csk->ack_backlog=0;
sk299net/unix/af_unix.csk->shutdown=0;
sk300net/unix/af_unix.csk->state_change=def_callback1;
sk301net/unix/af_unix.csk->data_ready=def_callback2;
sk302net/unix/af_unix.csk->write_space=def_callback3;
sk303net/unix/af_unix.csk->error_report=def_callback1;
sk304net/unix/af_unix.csk->mtu=4096;
sk305net/unix/af_unix.csk->socket=sock;
sk306net/unix/af_unix.csock->data=(void *)sk;
sk307net/unix/af_unix.csk->sleep=sock->wait;
sk308net/unix/af_unix.csk->zapped=0;
sk309net/unix/af_unix.cunix_insert_socket(sk);
sk320net/unix/af_unix.cunix_socket *sk=sock->data;
sk325net/unix/af_unix.cif(sk==NULL)
sk328net/unix/af_unix.csk->state_change(sk);
sk329net/unix/af_unix.csk->dead=1;
sk330net/unix/af_unix.cskpair=(unix_socket *)sk->protinfo.af_unix.other;  /* Person we send to (default) */
sk331net/unix/af_unix.cif(sk->type==SOCK_STREAM && skpair!=NULL && skpair->state!=TCP_LISTEN)
sk338net/unix/af_unix.csk->protinfo.af_unix.other=NULL;      /* No pair */
sk339net/unix/af_unix.cunix_destroy_socket(sk);      /* Try and flush out this socket. Throw our buffers at least */
sk374net/unix/af_unix.cunix_socket *sk=sock->data;
sk384net/unix/af_unix.cif(sk->protinfo.af_unix.inode!=NULL)
sk387net/unix/af_unix.csk->protinfo.af_unix.name=kmalloc(addr_len+1, GFP_KERNEL);
sk388net/unix/af_unix.cif(sk->protinfo.af_unix.name==NULL)
sk390net/unix/af_unix.cmemcpy(sk->protinfo.af_unix.name, sun->sun_path, addr_len+1);
sk395net/unix/af_unix.cerr=do_mknod(sk->protinfo.af_unix.name,S_IFSOCK|S_IRWXUGO,0);
sk397net/unix/af_unix.cerr=open_namei(sk->protinfo.af_unix.name, 2, S_IFSOCK, &sk->protinfo.af_unix.inode, NULL);
sk403net/unix/af_unix.ckfree_s(sk->protinfo.af_unix.name,addr_len+1);
sk404net/unix/af_unix.csk->protinfo.af_unix.name=NULL;
sk417net/unix/af_unix.cunix_socket *sk=sock->data;
sk423net/unix/af_unix.cif(sk->type==SOCK_STREAM && sk->protinfo.af_unix.other)
sk425net/unix/af_unix.cif(sock->state==SS_CONNECTING && sk->state==TCP_ESTABLISHED)
sk430net/unix/af_unix.cif(sock->state==SS_CONNECTING && sk->state == TCP_CLOSE)
sk445net/unix/af_unix.cif(sk->type==SOCK_DGRAM && sk->protinfo.af_unix.other)
sk447net/unix/af_unix.csk->protinfo.af_unix.other->protinfo.af_unix.locks--;
sk448net/unix/af_unix.csk->protinfo.af_unix.other=NULL;
sk458net/unix/af_unix.csk->protinfo.af_unix.other=other;
sk460net/unix/af_unix.csk->state=TCP_ESTABLISHED;
sk471net/unix/af_unix.cskb=sock_alloc_send_skb(sk, 0, 0, 0, &err); /* Marker object */
sk474net/unix/af_unix.cskb->sk=sk;        /* So they know it is us */
sk476net/unix/af_unix.csk->state=TCP_CLOSE;
sk486net/unix/af_unix.csk->protinfo.af_unix.other=other;
sk488net/unix/af_unix.csk->state=TCP_SYN_SENT;
sk498net/unix/af_unix.cwhile(sk->state==TCP_SYN_SENT)
sk505net/unix/af_unix.cinterruptible_sleep_on(sk->sleep);
sk517net/unix/af_unix.cif(sk->state==TCP_CLOSE)
sk519net/unix/af_unix.csk->protinfo.af_unix.other->protinfo.af_unix.locks--;
sk520net/unix/af_unix.csk->protinfo.af_unix.other=NULL;
sk555net/unix/af_unix.cunix_socket *sk=sock->data;
sk559net/unix/af_unix.cif(sk->type!=SOCK_STREAM)
sk563net/unix/af_unix.cif(sk->state!=TCP_LISTEN)
sk569net/unix/af_unix.cif(sk->protinfo.af_unix.name!=NULL)
sk571net/unix/af_unix.cnewsk->protinfo.af_unix.name=kmalloc(strlen(sk->protinfo.af_unix.name)+1, GFP_KERNEL);
sk574net/unix/af_unix.cstrcpy(newsk->protinfo.af_unix.name, sk->protinfo.af_unix.name);
sk580net/unix/af_unix.cskb=skb_dequeue(&sk->receive_queue);
sk588net/unix/af_unix.cinterruptible_sleep_on(sk->sleep);
sk598net/unix/af_unix.ctsk=skb->sk;
sk600net/unix/af_unix.csk->ack_backlog--;
sk606net/unix/af_unix.csk->protinfo.af_unix.locks--;  /* Locked to child socket not master */
sk616net/unix/af_unix.cunix_socket *sk=sock->data;
sk621net/unix/af_unix.cif(sk->protinfo.af_unix.other==NULL)
sk623net/unix/af_unix.csk=sk->protinfo.af_unix.other;
sk626net/unix/af_unix.cif(sk->protinfo.af_unix.name==NULL)
sk632net/unix/af_unix.c*uaddr_len=sizeof(sun->sun_family)+strlen(sk->protinfo.af_unix.name)+1;
sk633net/unix/af_unix.cstrcpy(sun->sun_path,sk->protinfo.af_unix.name);    /* 108 byte limited */
sk639net/unix/af_unix.cunix_socket *sk=sock->data;
sk647net/unix/af_unix.cif(sk->err)
sk650net/unix/af_unix.cerr=sk->err;
sk651net/unix/af_unix.csk->err=0;
sk663net/unix/af_unix.cif(sk->state==TCP_ESTABLISHED)
sk671net/unix/af_unix.cif(sk->protinfo.af_unix.other==NULL)
sk685net/unix/af_unix.cif(size>(sk->sndbuf-sizeof(struct sk_buff))/2)  /* Keep two messages in the pipe so it schedules better */
sk689net/unix/af_unix.csize=(sk->sndbuf-sizeof(struct sk_buff))/2;
sk706net/unix/af_unix.cskb=sock_alloc_send_skb(sk,size,limit,nonblock, &err);
sk712net/unix/af_unix.csk->err=-err;
sk719net/unix/af_unix.cskb->sk=sk;
sk727net/unix/af_unix.cother=sk->protinfo.af_unix.other;
sk731net/unix/af_unix.csk->protinfo.af_unix.other=NULL;
sk764net/unix/af_unix.cunix_socket *sk=sock->data;
sk778net/unix/af_unix.cif(sk->err)
sk781net/unix/af_unix.cerr=sk->err;
sk782net/unix/af_unix.csk->err=0;
sk788net/unix/af_unix.cdown(&sk->protinfo.af_unix.readsem);    /* Lock the socket */
sk802net/unix/af_unix.cup(&sk->protinfo.af_unix.readsem);
sk806net/unix/af_unix.cskb=skb_peek(&sk->receive_queue);
sk809net/unix/af_unix.cup(&sk->protinfo.af_unix.readsem);
sk810net/unix/af_unix.cif(sk->shutdown & RCV_SHUTDOWN)
sk825net/unix/af_unix.csk->socket->flags |= SO_WAITDATA;
sk826net/unix/af_unix.cinterruptible_sleep_on(sk->sleep);
sk827net/unix/af_unix.csk->socket->flags &= ~SO_WAITDATA;
sk836net/unix/af_unix.cdown(&sk->protinfo.af_unix.readsem);
sk842net/unix/af_unix.cif(skb->sk->protinfo.af_unix.name)
sk844net/unix/af_unix.cmemcpy(sun->sun_path, skb->sk->protinfo.af_unix.name, 108);
sk876net/unix/af_unix.cup(&sk->protinfo.af_unix.readsem);
sk882net/unix/af_unix.cunix_socket *sk=(unix_socket *)sock->data;
sk883net/unix/af_unix.cunix_socket *other=sk->protinfo.af_unix.other;
sk886net/unix/af_unix.csk->shutdown|=SEND_SHUTDOWN;
sk887net/unix/af_unix.csk->state_change(sk);
sk894net/unix/af_unix.cother=sk->protinfo.af_unix.other;
sk897net/unix/af_unix.csk->shutdown|=RCV_SHUTDOWN;
sk898net/unix/af_unix.csk->state_change(sk);
sk916net/unix/af_unix.cunix_socket *sk=sock->data;
sk927net/unix/af_unix.camount=sk->sndbuf-sk->wmem_alloc;
sk935net/unix/af_unix.cif(sk->state==TCP_LISTEN)
sk938net/unix/af_unix.cif((skb=skb_peek(&sk->receive_queue))!=NULL)