mirror of
https://github.com/aircrack-ng/rtl8812au.git
synced 2025-01-03 21:04:05 +00:00
Added DEBUG to USB - CONFIG_USB_DEBUG in Makefile
This commit is contained in:
parent
ab77d23e50
commit
a0bb0e1d42
15
Makefile
15
Makefile
@ -44,25 +44,11 @@ EXTRA_CFLAGS += -I$(src)/include
|
||||
CONFIG_AUTOCFG_CP = n
|
||||
|
||||
########################## WIFI IC ############################
|
||||
CONFIG_RTL8188E = n
|
||||
CONFIG_RTL8812A = y
|
||||
CONFIG_RTL8821A = y
|
||||
CONFIG_RTL8192E = n
|
||||
CONFIG_RTL8723B = n
|
||||
CONFIG_RTL8814A = y
|
||||
CONFIG_RTL8723C = n
|
||||
CONFIG_RTL8188F = n
|
||||
CONFIG_RTL8188GTV = n
|
||||
CONFIG_RTL8822B = n
|
||||
CONFIG_RTL8723D = n
|
||||
CONFIG_RTL8821C = n
|
||||
CONFIG_RTL8710B = n
|
||||
CONFIG_RTL8192F = n
|
||||
######################### Interface ###########################
|
||||
CONFIG_USB_HCI = y
|
||||
CONFIG_PCI_HCI = n
|
||||
CONFIG_SDIO_HCI = n
|
||||
CONFIG_GSPI_HCI = n
|
||||
########################## Features ###########################
|
||||
CONFIG_MP_INCLUDED = y
|
||||
CONFIG_POWER_SAVING = n
|
||||
@ -109,6 +95,7 @@ CONFIG_RTW_DEBUG = y
|
||||
# default log level is _DRV_INFO_ = 4,
|
||||
# please refer to "How_to_set_driver_debug_log_level.doc" to set the available level.
|
||||
CONFIG_RTW_LOG_LEVEL = 4
|
||||
CONFIG_USB_DEBUG = n
|
||||
#DEBUG=1
|
||||
######################## Wake On Lan ##########################
|
||||
CONFIG_WOWLAN = n
|
||||
|
@ -5405,6 +5405,10 @@ u8 rtw_halmac_switch_usb_mode(struct dvobj_priv *d, enum RTW_USB_SPEED usb_mode)
|
||||
mac = dvobj_to_halmac(d);
|
||||
api = HALMAC_GET_API(mac);
|
||||
halmac_usb_mode = _usb_mode_drv2halmac(usb_mode);
|
||||
#ifdef CONFIG_USB_DEBUG
|
||||
dev_info(&d->pusbdev->dev,
|
||||
DRV_NAME " call api->halmac_set_hw_value()\n");
|
||||
#endif
|
||||
status = api->halmac_set_hw_value(mac, HALMAC_HW_USB_MODE, (void *)&halmac_usb_mode);
|
||||
|
||||
if (HALMAC_RET_SUCCESS != status)
|
||||
|
@ -102,7 +102,7 @@ void rtw_sw_led_blink_uc_trx_only(LED_DATA *led)
|
||||
led->BlinkingLedState = RTW_LED_OFF;
|
||||
else
|
||||
led->BlinkingLedState = RTW_LED_ON;
|
||||
|
||||
|
||||
if (bStopBlinking) {
|
||||
led->CurrLedState = RTW_LED_OFF;
|
||||
led->bLedBlinkInProgress = _FALSE;
|
||||
@ -225,7 +225,7 @@ void rtw_led_set_iface_en_mask(_adapter *adapter, u8 mask)
|
||||
void rtw_led_set_ctl_en_mask(_adapter *adapter, u32 ctl_mask)
|
||||
{
|
||||
struct led_priv *ledpriv = adapter_to_led(adapter);
|
||||
|
||||
|
||||
#if CONFIG_RTW_SW_LED_TRX_DA_CLASSIFY
|
||||
if (ctl_mask & BIT(LED_CTL_TX))
|
||||
ctl_mask |= BIT(LED_CTL_UC_TX) | BIT(LED_CTL_BMC_TX);
|
||||
|
@ -2458,6 +2458,10 @@ u8 SetHwReg8812AU(PADAPTER Adapter, u8 variable, u8 *val)
|
||||
break;
|
||||
|
||||
case HW_VAR_USB_MODE:
|
||||
#ifdef CONFIG_USB_DEBUG
|
||||
dev_info(&pdvobjpriv->pusbdev->dev,
|
||||
DRV_NAME " switch sethwreg HW_VAR_USB_MODE\n");
|
||||
#endif
|
||||
/* U2 to U3 */
|
||||
if (registry_par->switch_usb_mode == 1) {
|
||||
if (IS_HIGH_SPEED_USB(Adapter)) {
|
||||
|
@ -1,7 +1,7 @@
|
||||
/******************************************************************************
|
||||
*
|
||||
* Copyright(c) 2007 - 2011 Realtek Corporation. All rights reserved.
|
||||
*
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify it
|
||||
* under the terms of version 2 of the GNU General Public License as
|
||||
* published by the Free Software Foundation.
|
||||
@ -2179,6 +2179,10 @@ u8 SetHwReg8814AU(PADAPTER Adapter, u8 variable, u8* val)
|
||||
break;
|
||||
|
||||
case HW_VAR_USB_MODE:
|
||||
#ifdef CONFIG_USB_DEBUG
|
||||
dev_info(&pdvobjpriv->pusbdev->dev,
|
||||
DRV_NAME " switch sethwreg HW_VAR_USB_MODE\n");
|
||||
#endif
|
||||
/* U2 to U3 */
|
||||
if (registry_par->switch_usb_mode == 1) {
|
||||
if (IS_HIGH_SPEED_USB(Adapter)) {
|
||||
|
@ -344,7 +344,7 @@ static u8 rtw_chbw_to_cfg80211_chan_def(struct wiphy *wiphy, struct cfg80211_cha
|
||||
if (!chan)
|
||||
goto exit;
|
||||
|
||||
if (bw == CHANNEL_WIDTH_20)
|
||||
if (bw == CHANNEL_WIDTH_20)
|
||||
chdef->width = ht ? NL80211_CHAN_WIDTH_20 : NL80211_CHAN_WIDTH_20_NOHT;
|
||||
else if (bw == CHANNEL_WIDTH_40)
|
||||
chdef->width = NL80211_CHAN_WIDTH_40;
|
||||
|
@ -716,17 +716,34 @@ static void usb_dvobj_deinit(struct usb_interface *usb_intf)
|
||||
static int usb_reprobe_switch_usb_mode(PADAPTER Adapter)
|
||||
{
|
||||
struct registry_priv *registry_par = &Adapter->registrypriv;
|
||||
#ifdef CONFIG_USB_DEBUG
|
||||
struct dvobj_priv *d = adapter_to_dvobj(Adapter);
|
||||
#endif
|
||||
HAL_DATA_TYPE *pHalData = GET_HAL_DATA(Adapter);
|
||||
u8 ret = _FALSE;
|
||||
|
||||
#ifdef CONFIG_USB_DEBUG
|
||||
dev_info(&d->pusbdev->dev, DRV_NAME " %s \n", __func__);
|
||||
#endif
|
||||
/* efuse not allow driver to switch usb mode */
|
||||
if (pHalData->EEPROMUsbSwitch == _FALSE)
|
||||
if (pHalData->EEPROMUsbSwitch == _FALSE) {
|
||||
goto exit;
|
||||
#ifdef CONFIG_USB_DEBUG
|
||||
dev_info(&d->pusbdev->dev, DRV_NAME " no eeprom switch\n");
|
||||
#endif
|
||||
}
|
||||
|
||||
/* registry not allow driver to switch usb mode */
|
||||
if (registry_par->switch_usb_mode == 0)
|
||||
if (registry_par->switch_usb_mode == 0) {
|
||||
goto exit;
|
||||
#ifdef CONFIG_USB_DEBUG
|
||||
dev_info(&d->pusbdev->dev, DRV_NAME " no module param\n");
|
||||
#endif
|
||||
}
|
||||
|
||||
#ifdef CONFIG_USB_DEBUG
|
||||
dev_info(&d->pusbdev->dev, DRV_NAME " try hw reg HW_VAR_USB_MODE\n");
|
||||
#endif
|
||||
rtw_hal_set_hwreg(Adapter, HW_VAR_USB_MODE, &ret);
|
||||
|
||||
exit:
|
||||
|
Loading…
Reference in New Issue
Block a user