speedtch usbatm.c,1.21,1.22 usbatm.h,1.14,1.15
Duncan Sands
duncan at infradead.org
Tue May 3 04:06:46 EDT 2005
Update of /home/cvs/speedtch
In directory phoenix.infradead.org:/tmp/cvs-serv31336
Modified Files:
usbatm.c usbatm.h
Log Message:
Trivial changes.
Index: usbatm.c
===================================================================
RCS file: /home/cvs/speedtch/usbatm.c,v
retrieving revision 1.21
retrieving revision 1.22
diff -u -r1.21 -r1.22
--- usbatm.c 26 Apr 2005 21:28:03 -0000 1.21
+++ usbatm.c 3 May 2005 08:06:43 -0000 1.22
@@ -109,31 +109,6 @@
#define THROTTLE_MSECS 5 /* delay to recover processing after urb submission fails */
-/* receive */
-
-struct usbatm_vcc_data {
- /* vpi/vci lookup */
- struct list_head list;
- short vpi;
- int vci;
- struct atm_vcc *vcc;
-
- /* raw cell reassembly */
- struct sk_buff *sarb;
-};
-
-
-/* send */
-
-struct usbatm_control {
- struct atm_vcc *vcc;
- u32 len;
- u32 crc;
-};
-
-#define UDSL_SKB(x) ((struct usbatm_control *)(x)->cb)
-
-
static unsigned int num_rcv_urbs = UDSL_DEFAULT_RCV_URBS;
static unsigned int num_snd_urbs = UDSL_DEFAULT_SND_URBS;
static unsigned int rcv_buf_size = UDSL_DEFAULT_RCV_BUF_SIZE;
@@ -163,6 +138,32 @@
__MODULE_STRING(UDSL_MAX_SND_BUF_SIZE) ", default: "
__MODULE_STRING(UDSL_DEFAULT_SND_BUF_SIZE) ")");
+
+/* receive */
+
+struct usbatm_vcc_data {
+ /* vpi/vci lookup */
+ struct list_head list;
+ short vpi;
+ int vci;
+ struct atm_vcc *vcc;
+
+ /* raw cell reassembly */
+ struct sk_buff *sarb;
+};
+
+
+/* send */
+
+struct usbatm_control {
+ struct atm_vcc *vcc;
+ u32 len;
+ u32 crc;
+};
+
+#define UDSL_SKB(x) ((struct usbatm_control *)(x)->cb)
+
+
/* ATM */
static void usbatm_atm_dev_close(struct atm_dev *dev);
@@ -186,6 +187,7 @@
/***********
** misc **
***********/
+
static inline unsigned int usbatm_pdu_length(unsigned int length)
{
length += ATM_CELL_PAYLOAD - 1 + ATM_AAL5_TRAILER;
@@ -200,7 +202,11 @@
dev_kfree_skb(skb);
}
-/* buffer management */
+
+/*******************
+** transceivers **
+*******************/
+
static inline struct usbatm_transceiver *usbatm_pop_transceiver(struct usbatm_channel *channel)
{
struct usbatm_transceiver *trx;
@@ -267,6 +273,7 @@
tasklet_schedule(&channel->tasklet);
}
+
/*************
** decode **
*************/
@@ -397,6 +404,7 @@
}
}
+
/*************
** encode **
*************/
@@ -460,6 +468,7 @@
return num_written;
}
+
/**************
** receive **
**************/
@@ -492,6 +501,7 @@
}
}
+
/***********
** send **
***********/
@@ -1116,7 +1126,7 @@
struct usbatm_data *instance = usb_get_intfdata(intf);
int i;
- dev_dbg(dev, "%s: disconnect entered\n", __func__);
+ dev_dbg(dev, "%s entered\n", __func__);
if (!instance) {
dev_dbg(dev, "%s: NULL instance!\n", __func__);
Index: usbatm.h
===================================================================
RCS file: /home/cvs/speedtch/usbatm.h,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -r1.14 -r1.15
--- usbatm.h 26 Apr 2005 21:28:03 -0000 1.14
+++ usbatm.h 3 May 2005 08:06:43 -0000 1.15
@@ -74,7 +74,7 @@
atm_printk(KERN_DEBUG, instance , format , ## arg)
#else
#define atm_dbg(instance, format, arg...) \
- do { } while (0)
+ do {} while (0)
#endif
@@ -83,9 +83,9 @@
struct usbatm_data;
/*
-* Assuming all methods exist and succeed, they are called like this:
+* Assuming all methods exist and succeed, they are called in this order:
*
-* bind, heavy_init, atm_start, atm_stop, unbind
+* bind, heavy_init, atm_start, ..., atm_stop, unbind
*/
struct usbatm_driver {
@@ -95,7 +95,7 @@
/*
* init device ... can sleep, or cause probe() failure. Drivers with a heavy_init
- * method can avoid the call to heavy_init by setting need_heavy_init to zero.
+ * method can avoid having it called by setting need_heavy_init to zero.
*/
int (*bind) (struct usbatm_data *, struct usb_interface *,
const struct usb_device_id *id, int *need_heavy_init);
@@ -137,8 +137,8 @@
};
struct usbatm_transceiver {
- struct urb *urb;
struct list_head list;
+ struct urb *urb;
struct usbatm_channel *channel;
};
More information about the Usbatm-commits
mailing list