patch-2.4.21 linux-2.4.21/include/linux/atmdev.h
Next file: linux-2.4.21/include/linux/auto_fs.h
Previous file: linux-2.4.21/include/linux/arcdevice.h
Back to the patch index
Back to the overall index
- Lines: 57
- Date:
2003-06-13 07:51:38.000000000 -0700
- Orig file:
linux-2.4.20/include/linux/atmdev.h
- Orig date:
2002-08-02 17:39:45.000000000 -0700
diff -urN linux-2.4.20/include/linux/atmdev.h linux-2.4.21/include/linux/atmdev.h
@@ -282,7 +282,6 @@
struct atm_vcc {
atm_vcc_flags_t flags; /* VCC flags (ATM_VF_*) */
- unsigned char family; /* address family; 0 if unused */
short vpi; /* VPI and VCI (types must be equal */
/* with sockaddr) */
int vci;
@@ -291,7 +290,6 @@
struct atm_dev *dev; /* device back pointer */
struct atm_qos qos; /* QOS */
struct atm_sap sap; /* SAP */
- atomic_t tx_inuse,rx_inuse; /* buffer space in use */
void (*push)(struct atm_vcc *vcc,struct sk_buff *skb);
void (*pop)(struct atm_vcc *vcc,struct sk_buff *skb); /* optional */
struct sk_buff *(*alloc_tx)(struct atm_vcc *vcc,unsigned int size);
@@ -302,8 +300,6 @@
int (*send)(struct atm_vcc *vcc,struct sk_buff *skb);
void *dev_data; /* per-device data */
void *proto_data; /* per-protocol data */
- struct timeval timestamp; /* AAL timestamps */
- struct sk_buff_head recvq; /* receive queue */
struct k_atm_aal_stats *stats; /* pointer to AAL stats group */
wait_queue_head_t sleep; /* if socket is busy */
struct sock *sk; /* socket backpointer */
@@ -356,7 +352,7 @@
struct proc_dir_entry *proc_entry; /* proc entry */
char *proc_name; /* proc entry name */
#endif
- struct atm_dev *prev,*next; /* linkage */
+ struct list_head dev_list; /* linkage */
};
@@ -435,19 +431,19 @@
static __inline__ void atm_force_charge(struct atm_vcc *vcc,int truesize)
{
- atomic_add(truesize+ATM_PDU_OVHD,&vcc->rx_inuse);
+ atomic_add(truesize+ATM_PDU_OVHD,&vcc->sk->rmem_alloc);
}
static __inline__ void atm_return(struct atm_vcc *vcc,int truesize)
{
- atomic_sub(truesize+ATM_PDU_OVHD,&vcc->rx_inuse);
+ atomic_sub(truesize+ATM_PDU_OVHD,&vcc->sk->rmem_alloc);
}
static __inline__ int atm_may_send(struct atm_vcc *vcc,unsigned int size)
{
- return size+atomic_read(&vcc->tx_inuse)+ATM_PDU_OVHD < vcc->sk->sndbuf;
+ return size+atomic_read(&vcc->sk->wmem_alloc)+ATM_PDU_OVHD < vcc->sk->sndbuf;
}
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)