ipc: Fix to handle remote GateMP not available 3.42.00.01_eng
authorSam Nelson <sam.nelson@ti.com>
Mon, 15 Feb 2016 21:04:51 +0000 (16:04 -0500)
committerSam Nelson <sam.nelson@ti.com>
Tue, 16 Feb 2016 04:44:50 +0000 (23:44 -0500)
There is an issue when GateMP in the remote processor is not available,
resulting in error. This fix handles the case gracefully by
ignoring remote gateMP availability.

Signed-off-by: Sam Nelson <sam.nelson@ti.com>
linux/src/api/Ipc.c

index 509d9a89e70090ec2f51f5bebc3729894d11a877..1b9d25f1e9bd401682acf12661bffd3656385d56 100644 (file)
@@ -272,10 +272,16 @@ Int Ipc_start(Void)
 
         status = GateMP_start();
         if (status < 0) {
-            fprintf(stderr, "Ipc_start: GateMP_start failed: %d\n", status);
-            status = Ipc_E_FAIL;
-            GateHWSpinlock_stop();
-            goto exit;
+            if (status == GateMP_E_NOTFOUND) {
+                fprintf(stderr, "Ipc_start: GateMP_start failed: not found %d\n",
+                    status);
+                status = 0;
+            } else {
+                fprintf(stderr, "Ipc_start: GateMP_start failed: %d\n", status);
+                status = Ipc_E_FAIL;
+                GateHWSpinlock_stop();
+                goto exit;
+            }
         }
     }
 #endif