staging: rtl8723au: Fold rtl8723au_set_queue_pipe_mapping into rtl8723au_chip_configure()

Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Jes Sorensen 2014-11-30 16:05:00 -05:00 committed by Greg Kroah-Hartman
parent ec28fb8948
commit 4a293154a9
3 changed files with 11 additions and 21 deletions

View File

@ -60,33 +60,22 @@ _ConfigChipOutEP(struct rtw_adapter *pAdapter, u8 NumOutPipe)
(u32)NumOutPipe, (u32)pHalData->OutEpNumber)); */
}
static bool rtl8723au_set_queue_pipe_mapping(struct rtw_adapter *pAdapter,
u8 NumInPipe, u8 NumOutPipe)
bool rtl8723au_chip_configure(struct rtw_adapter *padapter)
{
struct hal_data_8723a *pHalData = GET_HAL_DATA(pAdapter);
bool result = false;
struct hal_data_8723a *pHalData = GET_HAL_DATA(padapter);
struct dvobj_priv *pdvobjpriv = adapter_to_dvobj(padapter);
u8 NumInPipe = pdvobjpriv->RtNumInPipes;
u8 NumOutPipe = pdvobjpriv->RtNumOutPipes;
_ConfigChipOutEP(pAdapter, NumOutPipe);
_ConfigChipOutEP(padapter, NumOutPipe);
/* Normal chip with one IN and one OUT doesn't have interrupt IN EP. */
if (pHalData->OutEpNumber == 1) {
if (NumInPipe != 1)
return result;
return false;
}
result = Hal_MappingOutPipe23a(pAdapter, NumOutPipe);
return result;
}
void rtl8723au_chip_configure(struct rtw_adapter *padapter)
{
struct hal_data_8723a *pHalData = GET_HAL_DATA(padapter);
struct dvobj_priv *pdvobjpriv = adapter_to_dvobj(padapter);
rtl8723au_set_queue_pipe_mapping(padapter,
pdvobjpriv->RtNumInPipes,
pdvobjpriv->RtNumOutPipes);
return Hal_MappingOutPipe23a(padapter, NumOutPipe);
}
static int _InitPowerOn(struct rtw_adapter *padapter)

View File

@ -63,6 +63,6 @@ static inline void rtw_reset_continual_urb_error(struct dvobj_priv *dvobj)
atomic_set(&dvobj->continual_urb_error, 0);
}
void rtl8723au_chip_configure(struct rtw_adapter *padapter);
bool rtl8723au_chip_configure(struct rtw_adapter *padapter);
#endif /* __USB_OPS_H_ */

View File

@ -530,7 +530,8 @@ static struct rtw_adapter *rtw_usb_if1_init(struct dvobj_priv *dvobj,
rtl8723a_read_chip_version(padapter);
/* step usb endpoint mapping */
rtl8723au_chip_configure(padapter);
if (!rtl8723au_chip_configure(padapter))
goto free_hal_data;
/* step read efuse/eeprom data and get mac_addr */
rtl8723a_read_adapter_info(padapter);