mirror of
https://github.com/torvalds/linux.git
synced 2026-10-07 05:31:08 -04:00
staging: r8188eu: remove _InitNormalChipOneOutEpPriority
When _InitNormalChipOneOutEpPriority is called, pdvobjpriv->RtNumOutPipes and haldata->OutEpQueueSel have already been initialized. _InitNormalChipOneOutEpPriority is called only if pdvobjpriv->RtNumOutPipes == 1. In this case, haldata->OutEpQueueSel is always TX_SELE_HQ. We can then simplify _InitNormalChipOneOutEpPriority to a single _InitNormalChipRegPriority call, i.e. we can remove _InitNormalChipOneOutEpPriority and call _InitNormalChipRegPriority directly. Tested-by: Philipp Hortmann <[email protected]> # Edimax N150 Signed-off-by: Martin Kaiser <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Greg Kroah-Hartman <[email protected]>
This commit is contained in:
1 parent
68c72bcf61
commit
36a1cd9dac
1 file changed
+2
-23
@@ -225,28 +225,6 @@ static void _InitNormalChipRegPriority(struct adapter *Adapter, u16 beQ,
|
||||
rtw_write16(Adapter, REG_TRXDMA_CTRL, value16);
|
||||
}
|
||||
|
||||
static void _InitNormalChipOneOutEpPriority(struct adapter *Adapter)
|
||||
{
|
||||
struct hal_data_8188e *haldata = &Adapter->haldata;
|
||||
|
||||
u16 value = 0;
|
||||
switch (haldata->OutEpQueueSel) {
|
||||
case TX_SELE_HQ:
|
||||
value = QUEUE_HIGH;
|
||||
break;
|
||||
case TX_SELE_LQ:
|
||||
value = QUEUE_LOW;
|
||||
break;
|
||||
case TX_SELE_NQ:
|
||||
value = QUEUE_NORMAL;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
_InitNormalChipRegPriority(Adapter, value, value, value, value,
|
||||
value, value);
|
||||
}
|
||||
|
||||
static void _InitNormalChipTwoOutEpPriority(struct adapter *Adapter)
|
||||
{
|
||||
struct hal_data_8188e *haldata = &Adapter->haldata;
|
||||
@@ -319,7 +297,8 @@ static void _InitQueuePriority(struct adapter *Adapter)
|
||||
|
||||
switch (pdvobjpriv->RtNumOutPipes) {
|
||||
case 1:
|
||||
_InitNormalChipOneOutEpPriority(Adapter);
|
||||
_InitNormalChipRegPriority(Adapter, QUEUE_HIGH, QUEUE_HIGH, QUEUE_HIGH,
|
||||
QUEUE_HIGH, QUEUE_HIGH, QUEUE_HIGH);
|
||||
break;
|
||||
case 2:
|
||||
_InitNormalChipTwoOutEpPriority(Adapter);
|
||||
|
||||
Reference in new issue
Block a user