Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

staging: vt6656: struct vnt_private rename cdTD to num_tx_context

number of tx_context

Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Malcolm Priestley and committed by
Greg Kroah-Hartman
03b7e354 6da4738f

+8 -8
+1 -1
drivers/staging/vt6656/device.h
··· 293 293 294 294 /* Variables to track resources for the BULK Out Pipe */ 295 295 struct vnt_usb_send_context *tx_context[CB_MAX_TX_DESC]; 296 - u32 cbTD; 296 + u32 num_tx_context; 297 297 298 298 /* Variables to track resources for the Interrupt In Pipe */ 299 299 struct vnt_interrupt_buffer int_buf;
+1 -1
drivers/staging/vt6656/int.c
··· 75 75 u8 tx_retry = (tsr & 0xf0) >> 4; 76 76 s8 idx; 77 77 78 - if (pkt_no >= priv->cbTD) 78 + if (pkt_no >= priv->num_tx_context) 79 79 return -EINVAL; 80 80 81 81 context = priv->tx_context[pkt_no];
+4 -4
drivers/staging/vt6656/main_usb.c
··· 108 108 { 109 109 /* Set number of TX buffers */ 110 110 if (vnt_tx_buffers < CB_MIN_TX_DESC || vnt_tx_buffers > CB_MAX_TX_DESC) 111 - priv->cbTD = TX_DESC_DEF0; 111 + priv->num_tx_context = TX_DESC_DEF0; 112 112 else 113 - priv->cbTD = vnt_tx_buffers; 113 + priv->num_tx_context = vnt_tx_buffers; 114 114 115 115 /* Set number of RX buffers */ 116 116 if (vnt_rx_buffers < CB_MIN_RX_DESC || vnt_rx_buffers > CB_MAX_RX_DESC) ··· 388 388 struct vnt_usb_send_context *tx_context; 389 389 int ii; 390 390 391 - for (ii = 0; ii < priv->cbTD; ii++) { 391 + for (ii = 0; ii < priv->num_tx_context; ii++) { 392 392 tx_context = priv->tx_context[ii]; 393 393 /* deallocate URBs */ 394 394 if (tx_context->urb) { ··· 452 452 struct vnt_rcb *rcb; 453 453 int ii; 454 454 455 - for (ii = 0; ii < priv->cbTD; ii++) { 455 + for (ii = 0; ii < priv->num_tx_context; ii++) { 456 456 tx_context = kmalloc(sizeof(struct vnt_usb_send_context), 457 457 GFP_KERNEL); 458 458 if (tx_context == NULL) {
+2 -2
drivers/staging/vt6656/rxtx.c
··· 81 81 82 82 dev_dbg(&priv->usb->dev, "%s\n", __func__); 83 83 84 - for (ii = 0; ii < priv->cbTD; ii++) { 84 + for (ii = 0; ii < priv->num_tx_context; ii++) { 85 85 if (!priv->tx_context[ii]) 86 86 return NULL; 87 87 ··· 97 97 } 98 98 } 99 99 100 - if (ii == priv->cbTD) 100 + if (ii == priv->num_tx_context) 101 101 dev_dbg(&priv->usb->dev, "%s No Free Tx Context\n", __func__); 102 102 103 103 return NULL;