enum {
USB_MAX_TRANSFER_SIZE = 4096, /* bytes */ /* FIXME: The original driver uses this value. We have to check, * whether the MAX_TRANSFER_SIZE is sufficient and this needs only be * used if one combined frame is split over two USB transactions.
*/
USB_MAX_RX_SIZE = 4800, /* bytes */
USB_MAX_IOWRITE16_COUNT = 15,
USB_MAX_IOWRITE32_COUNT = USB_MAX_IOWRITE16_COUNT/2,
USB_MAX_IOREAD16_COUNT = 15,
USB_MAX_IOREAD32_COUNT = USB_MAX_IOREAD16_COUNT/2,
USB_MIN_RFWRITE_BIT_COUNT = 16,
USB_MAX_RFWRITE_BIT_COUNT = 28,
USB_MAX_EP_INT_BUFFER = 64,
USB_ZD1211B_BCD_DEVICE = 0x4810,
};
struct read_regs_int { struct completion completion; struct usb_req_read_regs *req; unsignedint req_count; /* Stores the USB int structure and contains the USB address of the * first requested register before request.
*/
u8 buffer[USB_MAX_EP_INT_BUFFER]; int length;
__le16 cr_int_addr;
};
/** * struct zd_usb_tx - structure used for transmitting frames * @enabled: atomic enabled flag, indicates whether tx is enabled * @lock: lock for transmission * @submitted: anchor for URBs sent to device * @submitted_urbs: atomic integer that counts the URBs having sent to the * device, which haven't been completed * @stopped: indicates whether higher level tx queues are stopped
*/ struct zd_usb_tx {
atomic_t enabled;
spinlock_t lock; struct delayed_work watchdog_work; struct sk_buff_head submitted_skbs; struct usb_anchor submitted; int submitted_urbs;
u8 stopped:1, watchdog_enabled:1;
};
/* Contains the usb parts. The structure doesn't require a lock because intf * will not be changed after initialization.
*/ struct zd_usb { struct zd_usb_interrupt intr; struct zd_usb_rx rx; struct zd_usb_tx tx; struct usb_interface *intf; struct usb_anchor submitted_cmds; struct urb *urb_async_waiting; int cmd_error;
u8 req_buf[64]; /* zd_usb_iowrite16v needs 62 bytes */
u8 is_zd1211b:1, initialized:1, was_running:1, in_async:1;
};
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.