]> Gitweb @ Texas Instruments - Open Source Git Repositories - git.TI.com/gitweb - processor-sdk/pdk.git/commitdiff
PRSDK-7156: Test update for pruss driver pg2.0 verification
authorTinku Mannan <tmannan@ti.com>
Mon, 30 Mar 2020 19:00:44 +0000 (15:00 -0400)
committerTinku Mannan <tmannan@ti.com>
Mon, 30 Mar 2020 19:00:44 +0000 (15:00 -0400)
packages/ti/drv/emac/test/EmacLoopbackTest/test_utils_k3.c

index b0076112e5d3a8a9ba77b1839d31b2d253ccbd42..574fa0e9d30719c0c9b8b09255d4c69a9a5f1dbb 100644 (file)
@@ -1582,7 +1582,8 @@ void test_EMAC_verify_ut_dual_mac_icssg(void)
     /* @description:Unit test for ICSSG dual mac use case
 
        @requirements: PRSDK-3771, PRSDK-3767, PRSDK-3768, PRSDK-3774, PRSDK-3776,
-                      PRSDK-3780, PRSDK-3782, PRSDK-3813, PRSDK-3815, PRSDK-4029
+                      PRSDK-3780, PRSDK-3782, PRSDK-3813, PRSDK-3815, PRSDK-4029,
+                      PRSDK-7156
 
        @cores: mpu1_0, mcu1_0 */
     Board_STATUS boardInitStatus =0;
@@ -1656,33 +1657,41 @@ void test_EMAC_verify_ut_dual_mac_icssg(void)
 #endif
     app_test_interrrupt_mode();
 
-    /* test close -re open sequence */
-    if(app_test_emac_close() == -1)
-    {
-        UART_printf("emac unit test app_test_emac_close failed\n");
-        while(1);
-    }
-    /* re-init the app */
-    app_init();
-
-    /* re-open in polling mode */
-    if (app_test_emac_open(EMAC_MODE_POLL) != 0)
+    if (gPgVersion == APP_TEST_AM65XX_PG1_0_VERSION)
     {
-        while(1);
-    }
-
-    app_test_poll_mode();
+        /* test close -re open sequence */
+        if(app_test_emac_close() == -1)
+        {
+            UART_printf("emac unit test app_test_emac_close failed\n");
+            while(1);
+        }
+        /* re-init the app */
+        app_init();
 
+        /* re-open in polling mode */
+        if (app_test_emac_open(EMAC_MODE_POLL) != 0)
+        {
+            while(1);
+        }
 
+        app_test_poll_mode();
 #ifndef BUILD_MCU1_0
-        app_test_multi_flows();
+            app_test_multi_flows();
 #endif
-
-    app_test_config_promiscous_mode(1);
-    app_test_promiscous_mode();
-
-    emac_test_get_icssg_stats();
-
+        app_test_config_promiscous_mode(1);
+        app_test_promiscous_mode();
+        emac_test_get_icssg_stats();
+    }
+    else
+    {
+        emac_test_get_icssg_stats();
+        /* test close -re open sequence */
+        if(app_test_emac_close() == -1)
+        {
+            UART_printf("emac unit test app_test_emac_close failed\n");
+            while(1);
+        }
+    }
     UART_printf("All tests have passed\n");
 #ifdef UNITY_INCLUDE_CONFIG_H
     TEST_PASS();