Commit 71dd092f authored by Kevin McKinney's avatar Kevin McKinney Committed by Greg Kroah-Hartman

Staging: bcm: Remove typedef for _USB_RCB and call directly.

This patch removes typedef for
_USB_RCB, changes the name of the
struct to bcm_usb_rcb. In addition,
any calls to typedefs USB_RCB, or
*PUSB_RCB are changed to call the
struct directly.
Signed-off-by: default avatarKevin McKinney <klmckinney1@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent d6861cfe
...@@ -40,11 +40,11 @@ typedef struct _USB_TCB { ...@@ -40,11 +40,11 @@ typedef struct _USB_TCB {
bool bUsed; bool bUsed;
} USB_TCB, *PUSB_TCB; } USB_TCB, *PUSB_TCB;
typedef struct _USB_RCB { struct bcm_usb_rcb {
struct urb *urb; struct urb *urb;
void *psIntfAdapter; void *psIntfAdapter;
bool bUsed; bool bUsed;
} USB_RCB, *PUSB_RCB; };
/* /*
* This is the interface specific Sub-Adapter * This is the interface specific Sub-Adapter
...@@ -64,7 +64,7 @@ struct bcm_interface_adapter { ...@@ -64,7 +64,7 @@ struct bcm_interface_adapter {
ULONG ulInterruptData[2]; ULONG ulInterruptData[2];
struct urb *psInterruptUrb; struct urb *psInterruptUrb;
USB_TCB asUsbTcb[MAXIMUM_USB_TCB]; USB_TCB asUsbTcb[MAXIMUM_USB_TCB];
USB_RCB asUsbRcb[MAXIMUM_USB_RCB]; struct bcm_usb_rcb asUsbRcb[MAXIMUM_USB_RCB];
atomic_t uNumTcbUsed; atomic_t uNumTcbUsed;
atomic_t uCurrTcb; atomic_t uCurrTcb;
atomic_t uNumRcbUsed; atomic_t uNumRcbUsed;
......
...@@ -12,10 +12,10 @@ static int SearchVcid(struct bcm_mini_adapter *Adapter,unsigned short usVcid) ...@@ -12,10 +12,10 @@ static int SearchVcid(struct bcm_mini_adapter *Adapter,unsigned short usVcid)
} }
static PUSB_RCB static struct bcm_usb_rcb *
GetBulkInRcb(struct bcm_interface_adapter *psIntfAdapter) GetBulkInRcb(struct bcm_interface_adapter *psIntfAdapter)
{ {
PUSB_RCB pRcb = NULL; struct bcm_usb_rcb *pRcb = NULL;
UINT index = 0; UINT index = 0;
if((atomic_read(&psIntfAdapter->uNumRcbUsed) < MAXIMUM_USB_RCB) && if((atomic_read(&psIntfAdapter->uNumRcbUsed) < MAXIMUM_USB_RCB) &&
...@@ -43,7 +43,7 @@ static void read_bulk_callback(struct urb *urb) ...@@ -43,7 +43,7 @@ static void read_bulk_callback(struct urb *urb)
UINT uiIndex=0; UINT uiIndex=0;
int process_done = 1; int process_done = 1;
//int idleflag = 0 ; //int idleflag = 0 ;
PUSB_RCB pRcb = (PUSB_RCB)urb->context; struct bcm_usb_rcb *pRcb = (struct bcm_usb_rcb *)urb->context;
struct bcm_interface_adapter *psIntfAdapter = pRcb->psIntfAdapter; struct bcm_interface_adapter *psIntfAdapter = pRcb->psIntfAdapter;
struct bcm_mini_adapter *Adapter = psIntfAdapter->psAdapter; struct bcm_mini_adapter *Adapter = psIntfAdapter->psAdapter;
struct bcm_leader *pLeader = urb->transfer_buffer; struct bcm_leader *pLeader = urb->transfer_buffer;
...@@ -196,7 +196,7 @@ static void read_bulk_callback(struct urb *urb) ...@@ -196,7 +196,7 @@ static void read_bulk_callback(struct urb *urb)
atomic_dec(&psIntfAdapter->uNumRcbUsed); atomic_dec(&psIntfAdapter->uNumRcbUsed);
} }
static int ReceiveRcb(struct bcm_interface_adapter *psIntfAdapter, PUSB_RCB pRcb) static int ReceiveRcb(struct bcm_interface_adapter *psIntfAdapter, struct bcm_usb_rcb *pRcb)
{ {
struct urb *urb = pRcb->urb; struct urb *urb = pRcb->urb;
int retval = 0; int retval = 0;
...@@ -243,7 +243,7 @@ Return: TRUE - If Rx was successful. ...@@ -243,7 +243,7 @@ Return: TRUE - If Rx was successful.
BOOLEAN InterfaceRx (struct bcm_interface_adapter *psIntfAdapter) BOOLEAN InterfaceRx (struct bcm_interface_adapter *psIntfAdapter)
{ {
USHORT RxDescCount = NUM_RX_DESC - atomic_read(&psIntfAdapter->uNumRcbUsed); USHORT RxDescCount = NUM_RX_DESC - atomic_read(&psIntfAdapter->uNumRcbUsed);
PUSB_RCB pRcb = NULL; struct bcm_usb_rcb *pRcb = NULL;
// RxDescCount = psIntfAdapter->psAdapter->CurrNumRecvDescs - // RxDescCount = psIntfAdapter->psAdapter->CurrNumRecvDescs -
// psIntfAdapter->psAdapter->PrevNumRecvDescs; // psIntfAdapter->psAdapter->PrevNumRecvDescs;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment