diff options
Diffstat (limited to 'package/ramips/drivers/mt7628sta/patches')
3 files changed, 81 insertions, 0 deletions
diff --git a/package/ramips/drivers/mt7628sta/patches/001-openwrt-build.patch b/package/ramips/drivers/mt7628sta/patches/001-openwrt-build.patch new file mode 100644 index 0000000..3429f57 --- /dev/null +++ b/package/ramips/drivers/mt7628sta/patches/001-openwrt-build.patch @@ -0,0 +1,20 @@ +Index: mt7628sta-4.0.1.4/mt_wifi_sta/Makefile +=================================================================== +--- mt7628sta-4.0.1.4.orig/mt_wifi_sta/Makefile ++++ mt7628sta-4.0.1.4/mt_wifi_sta/Makefile +@@ -1,10 +1,10 @@ +-EXTRA_CFLAGS = -Idrivers/net/wireless/mt_wifi/include \ +- -Idrivers/net/wireless/mt_wifi/embedded/include \ +- -Idrivers/net/wireless/mt_wifi/ate/include ++EXTRA_CFLAGS = -I$(src)/../mt_wifi/include \ ++ -I$(src)/../mt_wifi/embedded/include \ ++ -I$(src)/../mt_wifi/ate/include + +-DRV_NAME = mt_wifi ++DRV_NAME = mt7628sta + SRC_DIR = ../mt_wifi/embedded +-obj-$(CONFIG_MT_STA_SUPPORT) += $(DRV_NAME).o ++obj-m += $(DRV_NAME).o + + ######################################################## + # Common files diff --git a/package/ramips/drivers/mt7628sta/patches/002-path.patch b/package/ramips/drivers/mt7628sta/patches/002-path.patch new file mode 100644 index 0000000..c23ed27 --- /dev/null +++ b/package/ramips/drivers/mt7628sta/patches/002-path.patch @@ -0,0 +1,31 @@ +Index: mt7628sta-4.0.1.4/mt_wifi/embedded/include/os/rt_linux.h +=================================================================== +--- mt7628sta-4.0.1.4.orig/mt_wifi/embedded/include/os/rt_linux.h ++++ mt7628sta-4.0.1.4/mt_wifi/embedded/include/os/rt_linux.h +@@ -174,7 +174,7 @@ typedef struct usb_ctrlrequest devctrlre + + #ifdef CONFIG_STA_SUPPORT + #ifdef RTMP_MAC_PCI +-#define STA_PROFILE_PATH "/etc/Wireless/RT2860STA/RT2860STA.dat" ++#define STA_PROFILE_PATH "/etc/wireless/mt7628sta/mt7628sta.dat" + #define STA_DRIVER_VERSION "4.0.1.4" + #ifdef MULTIPLE_CARD_SUPPORT + #define CARD_INFO_PATH "/etc/Wireless/RT2860STA/RT2860STACard.dat" +@@ -194,7 +194,7 @@ typedef struct usb_ctrlrequest devctrlre + #ifdef RTMP_RBUS_SUPPORT + #define RTMP_FIRMWARE_FILE_NAME "/etc_ro/Wireless/RT2860STA/RT2860STA.bin" + #define PROFILE_PATH "/etc/Wireless/RT2860i.dat" +-#define STA_PROFILE_PATH_RBUS "/etc/Wireless/RT2860/RT2860.dat" ++#define STA_PROFILE_PATH_RBUS "/etc/wireless/mt7628sta/mt7628sta.dat" + #define RT2880_STA_DRIVER_VERSION "4.0.1.4" + #endif /* RTMP_RBUS_SUPPORT */ + +@@ -1689,7 +1689,7 @@ extern int rausb_control_msg(VOID *dev, + #ifdef CONFIG_AP_SUPPORT + #ifndef CONFIG_STA_SUPPORT /* avoid wrong usage when enabling P2P_SUPPORT */ + #if defined(CONFIG_SUPPORT_OPENWRT) +-#define EEPROM_BIN_FILE_NAME "/etc/wireless/mt7628/mt7628.eeprom.bin" ++#define EEPROM_BIN_FILE_NAME "/etc/wireless/mt7628/mt7628sta.eeprom.bin" + #else + #define EEPROM_BIN_FILE_NAME "/etc/Wireless/RT2860AP/e2p.bin" + #endif /* CONFIG_SUPPORT_OPENWRT */ diff --git a/package/ramips/drivers/mt7628sta/patches/003-log.patch b/package/ramips/drivers/mt7628sta/patches/003-log.patch new file mode 100644 index 0000000..945003e --- /dev/null +++ b/package/ramips/drivers/mt7628sta/patches/003-log.patch @@ -0,0 +1,30 @@ +Index: mt7628sta-4.0.1.4/mt_wifi/embedded/mcu/andes_mt.c +=================================================================== +--- mt7628sta-4.0.1.4.orig/mt_wifi/embedded/mcu/andes_mt.c ++++ mt7628sta-4.0.1.4/mt_wifi/embedded/mcu/andes_mt.c +@@ -4346,7 +4346,11 @@ error: + ret = AndesSendCmdMsg(pAd, msg); + + error: +- MTWF_LOG(DBG_CAT_ALL, DBG_SUBCAT_ALL, DBG_LVL_ERROR, ("%s:(ret = %d)\n", __FUNCTION__, ret)); ++ if (ret) ++ MTWF_LOG(DBG_CAT_ALL, DBG_SUBCAT_ALL, DBG_LVL_ERROR, ("%s:(ret = %d)\n", __FUNCTION__, ret)); ++ else ++ MTWF_LOG(DBG_CAT_ALL, DBG_SUBCAT_ALL, DBG_LVL_LOUD, ("%s:(ret = %d)\n", __FUNCTION__, ret)); ++ + return ret; + } + +Index: mt7628sta-4.0.1.4/mt_wifi/hw_ctrl/cmm_asic_mt.c +=================================================================== +--- mt7628sta-4.0.1.4.orig/mt_wifi/hw_ctrl/cmm_asic_mt.c ++++ mt7628sta-4.0.1.4/mt_wifi/hw_ctrl/cmm_asic_mt.c +@@ -1225,7 +1225,7 @@ UINT32 MtAsicGetRetryLimit(RTMP_ADAPTER + VOID MtAsicSetSlotTime(RTMP_ADAPTER *pAd, UINT32 SlotTime, UINT32 SifsTime) + { + CmdSlotTimeSet(pAd,(UINT8)SlotTime,(UINT8)SifsTime,(UINT8)RIFS_TIME, EIFS_TIME); +- MTWF_LOG(DBG_CAT_ALL, DBG_SUBCAT_ALL, DBG_LVL_TRACE, ("%s(%d): SetSlotTime!\n",__FUNCTION__, __LINE__)); ++ MTWF_LOG(DBG_CAT_ALL, DBG_SUBCAT_ALL, DBG_LVL_LOUD, ("%s(%d): SetSlotTime!\n",__FUNCTION__, __LINE__)); + } + + #define MAX_RX_PKT_LENGTH 0x400 /* WORD(4 Bytes) unit */ |