wifi: fix gts WifiHostTest#testWifiRttCapability test fail issue
authorRongjun Chen <rongjun.chen@amlogic.com>
Tue, 9 Jan 2018 02:04:16 +0000 (10:04 +0800)
committerRongjun Chen <rongjun.chen@amlogic.com>
Tue, 9 Jan 2018 02:04:16 +0000 (10:04 +0800)
PD# 158061

update bcm driver to fix gts test fail

Change-Id: Ie92552284b8c0aa6abbd9160ceeee7947aa6427d

bcmdhd.1.579.77.41.1.cn/dhd.h
bcmdhd.1.579.77.41.1.cn/dhd_config.c
bcmdhd.1.579.77.41.1.cn/dhd_linux.c
bcmdhd.1.579.77.41.1.cn/dhd_rtt.c

index bccc5bf76dea2e3daf0e3f03a7943b74bb3356ab..96d774aea839722c4c7c0214639e219ea15d9afd 100644 (file)
@@ -815,6 +815,7 @@ typedef struct dhd_pub {
 #endif
 #ifdef RTT_SUPPORT
        void *rtt_state;
+       bool rtt_supported;
 #endif
        bool    dongle_isolation;
        bool    is_pcie_watchdog_reset;
index 5fddc377e60fb27283af7615fc0e4b44dc88f018..e06201679136bebd9826b1c560c7f8197487b999 100644 (file)
@@ -65,7 +65,7 @@ uint config_msg_level = CONFIG_ERROR_LEVEL;
 #define CONFIG_BCM4354A1 "config_4354a1.txt"\r
 #endif\r
 #define CONFIG_BCM4356A2 "config_4356a2.txt"\r
-#define CONFIG_BCM4358A3 "config_4358.txt"\r
+#define CONFIG_BCM4358A3 "config_4358a3.txt"\r
 #define CONFIG_BCM4359B1 "config_4359b1.txt"\r
 #define CONFIG_BCM4359C0 "config_4359c0.txt"\r
 #endif\r
@@ -89,7 +89,7 @@ uint config_msg_level = CONFIG_ERROR_LEVEL;
 #define FW_BCM43456C5 "fw_bcm43456c5_ag"\r
 #define FW_BCM4354A1 "fw_bcm4354a1_ag"\r
 #define FW_BCM4356A2 "fw_bcm4356a2_ag"\r
-#define FW_BCM4358A3 "fw_bcm4358_ag"\r
+#define FW_BCM4358A3 "fw_bcm4358a3_ag"\r
 #define FW_BCM4359B1 "fw_bcm4359b1_ag"\r
 #define FW_BCM4359C0 "fw_bcm4359c0_ag"\r
 \r
index 70944f592abd79fbdc404fe23e41f2a2371f6d29..66c81e0d760370a7d986efeeedf3d405891c573c 100644 (file)
@@ -14130,8 +14130,10 @@ dhd_dev_get_feature_set(struct net_device *dev)
                        feature_set |= WIFI_FEATURE_D2D_RTT;
        }
 #ifdef RTT_SUPPORT
-       feature_set |= WIFI_FEATURE_D2D_RTT;
-       feature_set |= WIFI_FEATURE_D2AP_RTT;
+       if (dhd->rtt_supported) {
+               feature_set |= WIFI_FEATURE_D2D_RTT;
+               feature_set |= WIFI_FEATURE_D2AP_RTT;
+       }
 #endif /* RTT_SUPPORT */
 #ifdef LINKSTAT_SUPPORT
        feature_set |= WIFI_FEATURE_LINKSTAT;
index c58ca93fc435e07d146b66ee069c8aa4ac7ce793..cd35624974deb882145265cf2da74a82043bcddc 100644 (file)
@@ -2305,6 +2305,7 @@ dhd_rtt_init(dhd_pub_t *dhd)
        int32 version;
        rtt_status_info_t *rtt_status;
        NULL_CHECK(dhd, "dhd is NULL", err);
+       dhd->rtt_supported = FALSE;
        if (dhd->rtt_state) {
                return err;
        }
@@ -2331,6 +2332,7 @@ dhd_rtt_init(dhd_pub_t *dhd)
        ret = dhd_rtt_get_version(dhd, &version);
        if (ret == BCME_OK && (version == WL_PROXD_API_VERSION)) {
                DHD_ERROR(("%s : FTM is supported\n", __FUNCTION__));
+               dhd->rtt_supported = TRUE;
                /* rtt_status->rtt_capa.proto |= RTT_CAP_ONE_WAY; */
                rtt_status->rtt_capa.proto |= RTT_CAP_FTM_WAY;